v1.2.1: fixed char awareness working after a character dies
This commit is contained in:
@@ -762,7 +762,7 @@ public class Dungeon {
|
|||||||
|
|
||||||
for (TalismanOfForesight.CharAwareness c : hero.buffs(TalismanOfForesight.CharAwareness.class)){
|
for (TalismanOfForesight.CharAwareness c : hero.buffs(TalismanOfForesight.CharAwareness.class)){
|
||||||
Char ch = (Char) Actor.findById(c.charID);
|
Char ch = (Char) Actor.findById(c.charID);
|
||||||
if (ch == null) continue;
|
if (ch == null || !ch.isAlive()) continue;
|
||||||
BArray.or( level.visited, level.heroFOV, ch.pos - 1 - level.width(), 3, level.visited );
|
BArray.or( level.visited, level.heroFOV, ch.pos - 1 - level.width(), 3, level.visited );
|
||||||
BArray.or( level.visited, level.heroFOV, ch.pos - 1, 3, level.visited );
|
BArray.or( level.visited, level.heroFOV, ch.pos - 1, 3, level.visited );
|
||||||
BArray.or( level.visited, level.heroFOV, ch.pos - 1 + level.width(), 3, level.visited );
|
BArray.or( level.visited, level.heroFOV, ch.pos - 1 + level.width(), 3, level.visited );
|
||||||
|
|||||||
@@ -1203,7 +1203,7 @@ public abstract class Level implements Bundlable {
|
|||||||
|
|
||||||
for (TalismanOfForesight.CharAwareness a : c.buffs(TalismanOfForesight.CharAwareness.class)){
|
for (TalismanOfForesight.CharAwareness a : c.buffs(TalismanOfForesight.CharAwareness.class)){
|
||||||
Char ch = (Char) Actor.findById(a.charID);
|
Char ch = (Char) Actor.findById(a.charID);
|
||||||
if (ch == null) {
|
if (ch == null || !ch.isAlive()) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
int p = ch.pos;
|
int p = ch.pos;
|
||||||
|
|||||||
Reference in New Issue
Block a user