소스 검색

Make stomach events a bit more random. Add flavor text at different stages of digestion

geta
Fen Dweller 6 년 전
부모
커밋
414bc7867a
1개의 변경된 파일38개의 추가작업 그리고 2개의 파일을 삭제
  1. +38
    -2
      stories/geta-unaware.js

+ 38
- 2
stories/geta-unaware.js 파일 보기

@@ -887,8 +887,40 @@
playLoop("loop/stomach.ogg");
stopClassTimers("maw-struggle");

state.geta.digestionStage = 0;
state.geta.acidStrength = 1;

startTimer({
id: "digest-stages",
func: () => {
if (100 - state.geta.digestionStage * 25 - 25> getStat("health")) {
state.geta.digestionStage = Math.floor((100 - getStat("health")) / 25);
console.log(state.geta.digestionStage);
switch (state.geta.digestionStage) {
case 1:
print(["Your skin begins to tingle."]);
break;
case 2:
print(["The stinging acids work their way into your tender body."]);
break;
case 3:
print(["You're starting to fall apart..."]);
break;
default:
break;
}
}

return true;
},
delay: 1000,
loop: true,
classes: [
"digestion"
]
});


startTimer({
id: "digest-random",
func: () => {
@@ -911,7 +943,7 @@
() => {
printRandom([["Geta squeezes in on his gut with both hands, sloshing you around in the sickly stew of cereal, milk, and enzymatic slime."],
["Your organic prison snarls and churns, soaking you in fresh acids and hastening your wretched demise."]]);
changeStat("health", -10);
statLerp("health", -10, 2000);
return true;
},
() => {
@@ -968,7 +1000,11 @@
}
];

return choices[Math.floor(Math.random() * choices.length)]();
if (choices[Math.floor(Math.random() * choices.length)]()) {
return Math.random() * 3000 + 3500;
} else {
return false;
}

},
delay: 5000,


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