diff --git a/public/break_escape/js/systems/npc-behavior.js b/public/break_escape/js/systems/npc-behavior.js index 7df4f76..b042d72 100644 --- a/public/break_escape/js/systems/npc-behavior.js +++ b/public/break_escape/js/systems/npc-behavior.js @@ -153,7 +153,7 @@ class NPCBehavior { // State this.currentState = 'idle'; this.direction = 'down'; // Current facing direction - this.hostile = false; // Will be set via setHostile() if defaultState is true + this.hostile = false; // Will be set via setHostile() if startHostile is true this.influence = 0; // Patrol state @@ -195,7 +195,7 @@ class NPCBehavior { this.escapeWallBox = null; // Reference to the wall we're escaping from // Apply initial hostile state if configured - if (this.config.hostile.defaultState) { + if (this.config.hostile.startHostile) { this.setHostile(true); } @@ -227,7 +227,7 @@ class NPCBehavior { backAwayDistance: config.personalSpace?.backAwayDistance || 5 }, hostile: { - defaultState: config.hostile?.defaultState || false, + startHostile: config.hostile?.startHostile || false, influenceThreshold: config.hostile?.influenceThreshold || -50, chaseSpeed: config.hostile?.chaseSpeed || 145, fleeSpeed: config.hostile?.fleeSpeed || 180, diff --git a/public/break_escape/js/ui/game-over-screen.js b/public/break_escape/js/ui/game-over-screen.js index 57520bd..2ae5f71 100644 --- a/public/break_escape/js/ui/game-over-screen.js +++ b/public/break_escape/js/ui/game-over-screen.js @@ -129,7 +129,10 @@ export class GameOverScreen { // Listen for player KO window.eventDispatcher.on(CombatEvents.PLAYER_KO, () => { - this.show(); + // Add 1 second delay before showing game over screen + setTimeout(() => { + this.show(); + }, 1000); }); } diff --git a/scenarios/m01_first_contact/scenario.json.erb b/scenarios/m01_first_contact/scenario.json.erb index 732d2fa..54eeb51 100644 --- a/scenarios/m01_first_contact/scenario.json.erb +++ b/scenarios/m01_first_contact/scenario.json.erb @@ -293,6 +293,14 @@ password_hints = "Common passwords: Marketing123, Campaign2024, Viral_Dynamics_A }, "storyPath": "scenarios/m01_first_contact/ink/m01_npc_sarah.json", "currentKnot": "start", + "behavior": { + "hostile": { + "startHostile": true, + "chaseSpeed": 100, + "attackDamage": 10, + "pauseToAttack": true + } + }, "itemsHeld": [ { "type": "id_badge",