Variables! (Game Dev Day 6)
Jul 17, 2021
In Unity, a variable is just a method of storing important game information in code. This could be someone’s speed, an object’s size, the time of day, etc.
In my current work, variables are setting the player’s movement speed, as well as the movement speed of the lasers the player fires. Variables also limit the player’s fire rate.
So what does this mean in our prototype?
We can now shoot laser that will travel up the screen!
Next we will need to make some enemies so we have something to shoot at.