itch.io is community of indie game creators and players

Devlogs

Figuring out y-axis bounds

tankies
A browser game made in HTML5

Current challenge:

I'm trying to understand the movement constraints. The original tutorial game code  enforces a limit on x axis: you can not move a unit past the right limit of the board. However it does not do so for the y axis: you CAN move a unit past the bottom limit of the board. I hacked it to enforce a y axis boundary: https://github.com/greenmoss/tankies/blob/main/GameBoard/Cursor/Cursor.gd#L49-L50 However I would like to figure out the underlying cause and do this "correctly".

Note you can move units down to the bottom right. The unit movement preview box correctly stops on the right, but NOT on the bottom. I'm guessing this is related.

Files

  • tankies-html5.zip 14 MB
    Version 3
Leave a comment