Should fix all NPEs encountered because of nonexistant task maps (#1667)
This commit is contained in:
parent
e56c0cdbb9
commit
5f31f8c69a
1 changed files with 5 additions and 3 deletions
|
@ -250,9 +250,11 @@ public class GenericHandler {
|
||||||
targetTaskMap.remove(animal);
|
targetTaskMap.remove(animal);
|
||||||
attackTaskMap.remove(animal);
|
attackTaskMap.remove(animal);
|
||||||
}
|
}
|
||||||
} else if (targetTaskMap.containsKey(animal)) {
|
} else {
|
||||||
targetTaskMap.remove(animal);
|
if (targetTaskMap != null)
|
||||||
attackTaskMap.remove(animal);
|
targetTaskMap.remove(animal);
|
||||||
|
if (attackTaskMap != null)
|
||||||
|
attackTaskMap.remove(animal);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue