diff --git a/Scripts/Levels/arena_level.gd b/Scripts/Levels/arena_level.gd index 3327f86..f95fccc 100644 --- a/Scripts/Levels/arena_level.gd +++ b/Scripts/Levels/arena_level.gd @@ -27,7 +27,8 @@ func _ready(): func _on_player_defeated(by_what: Util.AttackType): if stage == 1: - cutscene_manager.load_cutscene(load("res://Cutscenes/prototype_clone_defeated.tres")) + var outcome = "defeated" if hiro_ai.health > 0 else "draw" + cutscene_manager.load_cutscene(load("res://Cutscenes/prototype_clone_{0}.tres".format([outcome]))) elif stage == 2: if Globals.nsfw == true: sound_manager.play_sound("effect_smoke") @@ -144,7 +145,8 @@ func _on_cutscene_loaded(_cutscene_name: String, auto_start: bool): func _on_shadow_clone_defeated(): barrier.process_mode = Node.PROCESS_MODE_DISABLED - cutscene_manager.load_cutscene(load("res://Cutscenes/prototype_clone_victory.tres")) + if player.health > 0: + cutscene_manager.load_cutscene(load("res://Cutscenes/prototype_clone_victory.tres")) func _on_reed_ai_defeated(): if player.health > 0: diff --git a/world/world.tscn b/world/world.tscn index 00f7a1c..daec98e 100644 --- a/world/world.tscn +++ b/world/world.tscn @@ -472,7 +472,7 @@ polygon = PackedVector2Array(-84, -31, -76, -57, -43, -71, -84, -71) [connection signal="interacted_with_object" from="HiroPlayer" to="." method="_on_player_interacted_with_object"] [connection signal="attack_did_hit" from="ShadowClone" to="HiroPlayer" method="_on_enemy_attack_did_hit"] [connection signal="attacked" from="ShadowClone" to="SoundManager" method="_on_humanoid_character_attacked"] -[connection signal="defeated" from="ShadowClone" to="." method="_on_shadow_clone_defeated"] +[connection signal="defeated" from="ShadowClone" to="." method="_on_shadow_clone_defeated" flags=3] [connection signal="got_hurt" from="ShadowClone" to="SoundManager" method="_on_character_got_hurt"] [connection signal="got_hurt" from="ShadowClone" to="CanvasLayer/BattleUI" method="_on_enemy_got_hurt"] [connection signal="attack_did_hit" from="ReedAI" to="HiroPlayer" method="_on_enemy_attack_did_hit"]