This commit is contained in:
Rendo 2025-10-17 18:22:49 +05:00
commit 074bb21ffd
18 changed files with 99 additions and 51 deletions

View file

@ -5,4 +5,6 @@ extends Node
var sync_time : float
func _process(delta: float) -> void:
sync_time = fposmod(sync_time+delta,1)
sync_time += delta
if sync_time > 1:
sync_time -= 1

View file

@ -0,0 +1,16 @@
extends Timer
const tics_per_second :float = 32.0
signal tick(current_tick: int)
var current_tick: int
func _ready() -> void:
start(1.0/tics_per_second)
timeout.connect(make_tick)
func make_tick():
current_tick += 1
if current_tick >= tics_per_second:
current_tick -= int(tics_per_second)
tick.emit(current_tick)

View file

@ -0,0 +1 @@
uid://cl3bqbr52mwfl