couple more improvements, im pretty happy with how this is shaping up

This commit is contained in:
JHDev2006
2025-10-26 16:35:41 +00:00
parent 3466e7c4c2
commit 53f3bce94c
11 changed files with 33 additions and 16 deletions

View File

@@ -14,6 +14,9 @@ signal modifier_applied
func _ready() -> void:
name = "EditorPropertyExposer"
get_entity_map()
func get_entity_map() -> void:
if entity_map.is_empty():
entity_map = JSON.parse_string(FileAccess.open(EntityIDMapper.MAP_PATH, FileAccess.READ).get_as_text())
@@ -45,6 +48,7 @@ func get_string() -> String:
return string
func apply_string(entity_string := "") -> void:
get_entity_map()
var idx := 2
var slice = entity_string.split(",")
for i in properties:
@@ -62,6 +66,10 @@ func apply_string(entity_string := "") -> void:
var scene = entity_map.get(value)
if scene != null:
owner.set(i, load(entity_map.get(value)[0]))
elif value != "!!":
print([value, entity_map.get(value)])
print(entity_map)
Global.log_error("error getting item! : " + i + str(value))
elif owner.get(i) is int:
var num = value
if value.length() > 1:

View File

@@ -7,7 +7,8 @@ func _ready() -> void:
func do_cycle() -> void:
if BooRaceHandler.countdown_active == false:
AudioManager.play_sfx("burner", global_position)
if $OnScreen.is_on_screen():
AudioManager.play_sfx("burner", global_position)
do_animation()
await get_tree().create_timer(0.25, false).timeout
%Shape.set_deferred("disabled", false)

View File

@@ -112,7 +112,12 @@ func player_enter(player: Player) -> void:
LevelEditor.play_door_transition = true
AudioManager.play_sfx("door_open", global_position)
await get_tree().create_timer(0.5, false).timeout
if Global.current_level.sublevel_id == sublevel_id:
var level_id = -1
if Global.current_level is CustomLevel:
level_id = Global.current_level.sublevel_id
elif Global.level_editor != null:
level_id = Global.level_editor.sub_level_id
if level_id == sublevel_id:
Global.do_fake_transition()
if Global.fade_transition:
await get_tree().create_timer(0.25, false).timeout

View File

@@ -334,6 +334,7 @@ func reset_values() -> void:
Checkpoint.sublevel_id = 0
Global.total_deaths = 0
Door.unlocked_doors = []
Door.exiting_door_id = -1
Checkpoint.unlocked_doors = []
KeyItem.total_collected = 0
Checkpoint.keys_collected = 0