This sets the update loop in the canvas.
The update loop is run once per frame, so it depends on the fps set for the number of times this loop is run.
There should only be one update_loop called.
All game logic should be handled within your update_function.
You cannot create GameObjects inside the update_loop.
game_state is an array that can be modified to store anything.
Parameters
update_function: UpdateFunction
A user-defined update_function, that takes in an array as a parameter.
This sets the update loop in the canvas. The update loop is run once per frame, so it depends on the fps set for the number of times this loop is run. There should only be one update_loop called. All game logic should be handled within your update_function. You cannot create GameObjects inside the update_loop. game_state is an array that can be modified to store anything.