bird/data/scripts/game.lua
2025-02-05 02:36:57 +03:00

15 lines
358 B
Lua

local Vector2 = require "types.vector2"
local player = require "player"
-- called every frame, with constant delta time
function game_tick()
-- ctx.initialization_needed is true first frame and every time dynamic reload is performed
if ctx.initialization_needed then
player:init()
ctx.udata = {}
end
draw_camera_2d{}
player:tick(ctx)
end