Java: How do I do position (x,y) based indexing with extremely high performance?

I have a game board that's a square 2 dimensional space of up to 64 by 64 tiles. Every tile can, but does not always contain a game piece. As part of an AI algorithm that generates possible future states to analyze I need to be able to:

Insert and remove game pieces at coordinates x,y (1m+ times a second )

Check whether a game piece is present using coordinates x,y (1m+ times a second)

Access these game pieces (1m+ times a second)

Clone a board (100k+ times a second)

The obvious solution is...

Read More »

By: StackOverFlow - Wednesday, 7 November

Related Posts