v0.2.3: added a null safety check.

This commit is contained in:
Evan Debenham 2014-11-28 09:47:43 -05:00
parent 7532ad91cb
commit 50c7f1e9aa

View File

@ -1104,7 +1104,7 @@ public class Hero extends Char {
}
public boolean isStarving() {
return ((Hunger)buff( Hunger.class )).isStarving();
return buff(Hunger.class) != null && ((Hunger)buff( Hunger.class )).isStarving();
}
@Override