| @@ -460,6 +460,7 @@ function digestPlayerStomach(predator,damage=20) { | |||||
| return [predator.description("The") + "'s stomach grinds over your body, swiftly digesting you."]; | return [predator.description("The") + "'s stomach grinds over your body, swiftly digesting you."]; | ||||
| }, | }, | ||||
| priority: 1, | priority: 1, | ||||
| gameover: function() { return "Digested by " + predator.description("a"); } | |||||
| }; | }; | ||||
| } | } | ||||
| @@ -471,5 +472,6 @@ function instakillPlayerStomach(pedator) { | |||||
| }, | }, | ||||
| priority: 1, | priority: 1, | ||||
| weight: function(attacker, defender) { return 1/3; }, | weight: function(attacker, defender) { return 1/3; }, | ||||
| gameover: function() { return "Digested by " + predator.description("a"); } | |||||
| }; | }; | ||||
| } | } | ||||
| @@ -305,7 +305,8 @@ function tranceStomp(attacker) { | |||||
| function(attacker, defender) { return defender.prefs.gore; } | function(attacker, defender) { return defender.prefs.gore; } | ||||
| ], | ], | ||||
| priority: 1, | priority: 1, | ||||
| weight: function(attacker, defender) { return attacker.health / attacker.maxHealth > 0.5 ? 0 : 3; } | |||||
| weight: function(attacker, defender) { return attacker.health / attacker.maxHealth > 0.5 ? 0 : 3; }, | |||||
| gameover: function() { return "Crushed under Trance's paw"; } | |||||
| }; | }; | ||||
| } | } | ||||
| @@ -352,7 +353,8 @@ function tranceGrappleMaul(attacker) { | |||||
| } | } | ||||
| ], | ], | ||||
| priority: 1, | priority: 1, | ||||
| weight: function(attacker, defender) { return defender.health / defender.maxHealth; } | |||||
| weight: function(attacker, defender) { return defender.health / defender.maxHealth; }, | |||||
| gameover: function() { return "Mauled by Trance"; } | |||||
| }; | }; | ||||
| } | } | ||||
| @@ -380,7 +382,8 @@ function tranceGrappleThroat(attacker) { | |||||
| } | } | ||||
| ], | ], | ||||
| priority: 1, | priority: 1, | ||||
| weight: function(attacker, defender) { return defender.health / defender.maxHealth > attacker.health / attacker.maxHealth ? 2 : 0; } | |||||
| weight: function(attacker, defender) { return defender.health / defender.maxHealth > attacker.health / attacker.maxHealth ? 2 : 0; }, | |||||
| gameover: function() { return "Throat ripped out by Trance"; } | |||||
| }; | }; | ||||
| } | } | ||||
| @@ -395,6 +395,8 @@ function respawn(respawnRoom) { | |||||
| } else { | } else { | ||||
| deaths.push("Defeated by " + currentFoe.description("a") + " at " + renderTime(time) + " on day " + date); | deaths.push("Defeated by " + currentFoe.description("a") + " at " + renderTime(time) + " on day " + date); | ||||
| } | } | ||||
| } else { | |||||
| deaths.push(killingBlow.gameover() + " at " + renderTime(time) + " on day " + date); | |||||
| } | } | ||||
| @@ -5,17 +5,6 @@ function GameObject(name="Potato") { | |||||
| this.actions = []; | this.actions = []; | ||||
| } | } | ||||
| function Burger() { | |||||
| GameObject.call(this, "Burger"); | |||||
| this.actions.push({ | |||||
| "name": "Punch Burger", | |||||
| "action": function() { | |||||
| player.health += 10; | |||||
| update(["You punch the hamburger."]); | |||||
| } | |||||
| }); | |||||
| } | |||||
| function Nerd() { | function Nerd() { | ||||
| GameObject.call(this, "Nerd"); | GameObject.call(this, "Nerd"); | ||||
| this.actions.push({ | this.actions.push({ | ||||