added the game

This commit is contained in:
JHDev2006
2025-09-13 16:30:32 +01:00
parent 5ef689109b
commit 3773bdaf64
3616 changed files with 263702 additions and 0 deletions

View File

@@ -0,0 +1,29 @@
class_name LevelPersistance
extends Node
static var active_nodes := [[], []]
var active := false
@onready var path := get_path_string()
signal enabled
signal enabled_2
static func reset_states() -> void:
active_nodes = [[], []]
Checkpoint.old_state = [[], []]
func _ready() -> void:
return
func set_as_active() -> void:
if owner.has_meta("no_persist"): return
active_nodes[0].append(path)
func set_as_active_2() -> void:
if owner.has_meta("no_persist"): return
active_nodes[1].append(path)
func get_path_string() -> String:
return Global.current_level.scene_file_path + str(Vector2i(owner.global_position / 8))