ok, here is the first question with a question, sorry if this is stupid.
I'm just wondering, for playing with a battleship, would it be a waste of memory to create a set of objects for each cell (10X10 = 100), with position (x, y) and state (empty, hit, missed)?
I was wondering if it would be better to create a Grid object and use methods to calculate cell positions when necessary (when processing cell selection using strokes or drawings, for example).
source
share