v0.6.0b: fixed crashes when gamescene closed while waiting on animations

This commit is contained in:
Evan Debenham 2017-06-11 15:41:16 -04:00
parent 4467146d33
commit 0cc15d9a69

View File

@ -216,12 +216,16 @@ public abstract class Actor implements Bundlable {
interrupted = interrupted || Thread.interrupted();
doNext = !interrupted && acting.act();
if (interrupted){
doNext = false;
current = null;
} else {
doNext = acting.act();
if (doNext && !Dungeon.hero.isAlive()) {
doNext = false;
current = null;
}
}
} else {
doNext = false;
}