소스 검색

Adjusted statHealthCheck. Lalim heals when feeding

tags/v0.2.8
Fen Dweller 7 년 전
부모
커밋
a27e67ba5d
2개의 변경된 파일5개의 추가작업 그리고 4개의 파일을 삭제
  1. +2
    -2
      combat.js
  2. +3
    -2
      customs.js

+ 2
- 2
combat.js 파일 보기

@@ -27,8 +27,8 @@ function statCheck(attacker, defender, stat) {
}

function statHealthCheck(attacker, defender, stat) {
let attackerPercent = attacker.health / attacker.maxHealth;
let defenderPercent = defender.health / defender.maxHealth;
let attackerPercent = 0.5 + 0.5 * attacker.health / attacker.maxHealth;
let defenderPercent = 0.5 + 0.5 * defender.health / defender.maxHealth;

if (attacker.stamina <= 0)
attackerPercent /= 2;


+ 3
- 2
customs.js 파일 보기

@@ -1360,7 +1360,7 @@ function lalimFeed(attacker) {
return ["Lalim darts back, abruptly ripping open a tear in his shadowy realm - jaws lunging in and snapping up some unseen victim, yanking them from the world of light into his gullet. His noisy swallows and gulps mix with muffled whimpers and cries as he gulps them down."];
}, requirements: [
function(attacker, defender) { return isNormal(attacker) && isNormal(defender); },
function(attacker, defender) { return !attacker.flags.feeding && !attacker.flags.fed }
function(attacker, defender) { return !attacker.flags.feeding && !attacker.flags.fed; }
],
priority: 1,
weight: function(attacker, defender) { return 0.5 + (5 - 5 * attacker.stamina / attacker.maxStamina); }
@@ -1389,7 +1389,8 @@ function lalimFeedDigest(attacker) {
attacker.str += 10;
attacker.dex += 10;
attacker.con += 10;
attacker.changeStamina(1000);
attacker.health += 100;
attacker.changeStamina(200);
return ["You watch in horror as that writhing bulge falls limp, loses substance...and digests completely. The monster seems invigorated by its meal..."];
}, requirements: [
function(attacker, defender) { return isNormal(attacker) && isNormal(defender); },


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