Press "1" to go into build mode Press "2" to exit build mode Use mouse to build Press "E" to erase Press "Q" to go back to normal Click to shoot!
This project was intended to be some tests for my game Extinction, but ended up being a quite smooth game itself! Anyway, the players direction is calculated by the closest enemy and turning to the left by a variable containing the amount you should turn to get to the enemy. Then, turn to the right by: (The variable - (Your current direction / any number)) and repeat that forever. you can see inside the player sprite and see the "Turn towards..." block.