watcher null fix for Kess Dissident Mage, issue #5563

This commit is contained in:
Ingmar Goudt 2019-02-02 17:14:54 +01:00
parent 942882bb90
commit 90bf7bd18c

View file

@ -162,7 +162,7 @@ class KessDissidentMageWatcher extends Watcher {
super(KessDissidentMageWatcher.class, WatcherScope.GAME);
}
KessDissidentMageWatcher(final KessDissidentMageWatcher watcher) {
private KessDissidentMageWatcher(final KessDissidentMageWatcher watcher) {
super(watcher);
this.allowingObjects.addAll(watcher.allowingObjects);
this.castSpells.putAll(watcher.castSpells);
@ -175,8 +175,8 @@ class KessDissidentMageWatcher extends Watcher {
Spell spell = (Spell) game.getObject(event.getTargetId());
if (event.getAdditionalReference() != null
&& event.getAdditionalReference().getSourceId() != null
&& spell.isInstant()
|| spell.isSorcery()) {
&& (spell.isInstant()
|| spell.isSorcery())) {
allowingObjects.add(event.getAdditionalReference());
castSpells.put(new MageObjectReference(spell.getSourceId(), game),
event.getAdditionalReference().getSourceId());