forked from External/mage
refactor the copy functionality for no-args watchers
This commit is contained in:
parent
311532a6e7
commit
6703ba693d
52 changed files with 73 additions and 538 deletions
|
|
@ -21,18 +21,6 @@ public class PlayerAttackedStepWatcher extends Watcher {
|
|||
super(WatcherScope.GAME);
|
||||
}
|
||||
|
||||
public PlayerAttackedStepWatcher(final PlayerAttackedStepWatcher watcher) {
|
||||
super(watcher);
|
||||
for (Map.Entry<UUID, Integer> entry : watcher.playerAttacked.entrySet()) {
|
||||
this.playerAttacked.put(entry.getKey(), entry.getValue());
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public PlayerAttackedStepWatcher copy() {
|
||||
return new PlayerAttackedStepWatcher(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void watch(GameEvent event, Game game) {
|
||||
if (event.getType() == GameEvent.EventType.DECLARE_ATTACKERS_STEP_POST) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue