소스 검색

Add player health; allow submission in the throat

geta
Fen Dweller 5 년 전
부모
커밋
4ddb42d3c6
1개의 변경된 파일28개의 추가작업 그리고 5개의 파일을 삭제
  1. +28
    -5
      stories/geta-unaware.js

+ 28
- 5
stories/geta-unaware.js 파일 보기

@@ -20,6 +20,7 @@
"intro": {
"start": "pepper-grinder",
"setup": state => {
state.player.stats.health = { name: "Health", type: "meter", value: 100, min: 0, max: 100, color: "rgb(255,55,55)" };
state.player.stats.suspicion = { name: "Suspicion", type: "meter", value: 0, min: 0, max: 100, color: "rgb(100,100,100)" };
state.info.time.value = 60 * 60 * 7 + 60 * 17;

@@ -293,7 +294,7 @@
},
"enter": (room, state) => {
startTimer({
id: "gut",
id: "throat-swallow",
func: state => {
print(["You slush down into Geta's stomach"]);
goToRoom("stomach", state);
@@ -322,6 +323,21 @@
],
conditions: [

]
},
{
name: "Give up",
desc: "Dive down into Geta's stomach",
execute: (room, state) => {
print(["You submit to your predator."]);
goToRoom("stomach", state);
stopTimer("throat-swallow", state);
},
show: [

],
conditions: [

]
},
],
@@ -348,12 +364,19 @@
startTimer({
id: "digest",
func: state => {
print(["You're digested before too long."]);
goToRoom("digested", state);
state.player.stats.health.value -= 0.3;

if (state.player.stats.health.value <= 0) {
print(["You're digested before too long."]);
goToRoom("digested", state);
return false;
}

return true;

},
delay: 10000,
loop: false,
delay: 100,
loop: true,
classes: [

]


불러오는 중...
취소
저장