v0.7.4: allies are now healed by magical sleep just as the hero is
This commit is contained in:
parent
93c312a53e
commit
3841f593f8
|
@ -38,14 +38,16 @@ public class MagicalSleep extends Buff {
|
||||||
|
|
||||||
target.paralysed++;
|
target.paralysed++;
|
||||||
|
|
||||||
if (target instanceof Hero) {
|
if (target.alignment == Char.Alignment.ALLY) {
|
||||||
if (target.HP == target.HT) {
|
if (target.HP == target.HT) {
|
||||||
GLog.i(Messages.get(this, "toohealthy"));
|
if (target instanceof Hero) GLog.i(Messages.get(this, "toohealthy"));
|
||||||
detach();
|
detach();
|
||||||
} else {
|
} else {
|
||||||
GLog.i(Messages.get(this, "fallasleep"));
|
if (target instanceof Hero) GLog.i(Messages.get(this, "fallasleep"));
|
||||||
}
|
}
|
||||||
} else if (target instanceof Mob) {
|
}
|
||||||
|
|
||||||
|
if (target instanceof Mob) {
|
||||||
((Mob) target).state = ((Mob) target).SLEEPING;
|
((Mob) target).state = ((Mob) target).SLEEPING;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -61,11 +63,11 @@ public class MagicalSleep extends Buff {
|
||||||
detach();
|
detach();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
if (target instanceof Hero) {
|
if (target.alignment == Char.Alignment.ALLY) {
|
||||||
target.HP = Math.min(target.HP+1, target.HT);
|
target.HP = Math.min(target.HP+1, target.HT);
|
||||||
((Hero) target).resting = true;
|
if (target instanceof Hero) ((Hero) target).resting = true;
|
||||||
if (target.HP == target.buff(Regeneration.class).regencap()) {
|
if (target.HP == target.buff(Regeneration.class).regencap()) {
|
||||||
GLog.p(Messages.get(this, "wakeup"));
|
if (target instanceof Hero) GLog.p(Messages.get(this, "wakeup"));
|
||||||
detach();
|
detach();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -890,7 +890,7 @@ items.scrolls.scrollofidentify.desc=This scroll permanently reveals all of the s
|
||||||
|
|
||||||
items.scrolls.scrolloflullaby.name=scroll of lullaby
|
items.scrolls.scrolloflullaby.name=scroll of lullaby
|
||||||
items.scrolls.scrolloflullaby.sooth=The scroll utters a soothing melody. You feel very sleepy.
|
items.scrolls.scrolloflullaby.sooth=The scroll utters a soothing melody. You feel very sleepy.
|
||||||
items.scrolls.scrolloflullaby.desc=Reading this scroll emits a soothing melody which will lull all who hear it into a deep magical sleep.
|
items.scrolls.scrolloflullaby.desc=Reading this scroll emits a soothing melody which will lull all who hear it into a deep magical sleep. For the reader and their allies the sleep is restorative.
|
||||||
|
|
||||||
items.scrolls.scrollofmagicmapping.name=scroll of magic mapping
|
items.scrolls.scrollofmagicmapping.name=scroll of magic mapping
|
||||||
items.scrolls.scrollofmagicmapping.layout=You are now aware of the level layout.
|
items.scrolls.scrollofmagicmapping.layout=You are now aware of the level layout.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user