| @@ -81,7 +81,20 @@ stories.push({ | |||
| startTimer({ | |||
| id: "stamina-regen", | |||
| func: state => { | |||
| state.player.stats.stamina.value += 1; | |||
| const location = state.player.location; | |||
| let bonus = state.player.flags.submission ? -3 : 0; | |||
| if (location.startsWith("stomach")) { | |||
| state.player.stats.stamina.value += 1 + bonus; | |||
| } | |||
| if (location.startsWith("intestines")) { | |||
| state.player.stats.stamina.value += 0.5 + bonus; | |||
| } | |||
| if (location.startsWith("bowels")) { | |||
| state.player.stats.stamina.value += -0.5 + bonus; | |||
| } | |||
| if (state.player.stats.stamina.value > 100) { | |||
| state.player.stats.stamina.value = 100; | |||
| @@ -300,7 +313,7 @@ stories.push({ | |||
| desc: "Let Fen digest you", | |||
| execute: (room, state) => { | |||
| state.player.flags.submission = true; | |||
| print(["You slump back in the crux's intestines, letting the winding, worryingly-tight guts take you in..."]); | |||
| print(["You go limp in the crux's intestines, letting the winding, worryingly-tight guts take you in..."]); | |||
| }, | |||
| show: [ | |||
| (room, state) => { | |||
| @@ -316,7 +329,7 @@ stories.push({ | |||
| name: "Bowels", | |||
| desc: "Cavernous bowels, rippling and squeezing over your bare skin", | |||
| move: (room, state) => { | |||
| print(["You enter the beast's humid bowels, taking shallow, stifled breaths of the musky air."]); | |||
| print(["You enter the beast's humid bowels, taking shallow, stifled breaths of the musky air. The sauna-like atmosphere sucks the strength from your tired limbs."]); | |||
| }, | |||
| enter: (room, state) => { | |||
| playLoop("loop/fen-bowels.ogg"); | |||
| @@ -324,17 +337,31 @@ stories.push({ | |||
| startTimer({ | |||
| id: "bowels-churns", | |||
| func: state => { | |||
| if (Math.random() > 0.6) { | |||
| if (state.player.stats.stamina.value > 50) { | |||
| state.player.stats.stamina.value -= 25; | |||
| state.player.stats.stamina.value = Math.max(0, state.player.stats.stamina.value); | |||
| print(["Fen's bowels clench and churn, grinding you into their musky walls."]); | |||
| playSfx("sfx/bowels-churn-safe.ogg"); | |||
| } else { | |||
| state.player.stats.health.value /= 4; | |||
| print(["Drained of stamina, you can do little to resist as Fen's bowels grind you away."]); | |||
| playSfx("sfx/bowels-churn-danger.ogg"); | |||
| } | |||
| if (state.player.stats.stamina.value > 50) { | |||
| state.player.stats.stamina.value -= 25; | |||
| state.player.stats.stamina.value = Math.max(0, state.player.stats.stamina.value); | |||
| print(["Fen's bowels clench and churn, grinding you into their musky walls."]); | |||
| playSfx("sfx/bowels-churn-safe.ogg"); | |||
| } else { | |||
| startTimer({ | |||
| id: "digestion", | |||
| func: state => { | |||
| let bonus = state.player.flags.submission ? 10 : 1; | |||
| state.player.stats.health.value -= 1; | |||
| return 500 / bonus; | |||
| }, | |||
| delay: 1000, | |||
| loop: true, | |||
| room: "bowels", | |||
| classes: [ | |||
| "alive" | |||
| ] | |||
| }, state); | |||
| print(["Drained of stamina, you can do little to resist as Fen's bowels grind you away."]); | |||
| playSfx("sfx/bowels-churn-danger.ogg"); | |||
| return false; | |||
| } | |||
| return true; | |||
| }, | |||
| @@ -362,6 +389,16 @@ stories.push({ | |||
| (room, state) => { | |||
| return !state.player.flags.submission; | |||
| } | |||
| ], | |||
| hooks: [ | |||
| (room, exit, state) => { | |||
| if (state.player.stats.stamina.value < 25) { | |||
| print(["You're too tired to move..."]); | |||
| playSfx("sfx/bowels-churn-safe.ogg"); | |||
| return false; | |||
| } | |||
| return true; | |||
| } | |||
| ] | |||
| } | |||
| }, | |||