Automatically triggering standard spaceship controls to stop its motion
- by Garan
I have been working on a 2D top-down space strategy/shooting game. Right now it is only in the prototyping stage (I have gotten basic movement) but now I am trying to write a function that will stop the ship based on it's velocity. This is being written in Lua, using the Love2D engine.
My code is as follows (note- object.dx is the x-velocity,…