mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 04:38:00 +00:00
- Updating Label observers after a ChangeZone
This commit is contained in:
@@ -111,6 +111,10 @@ public class GameAction {
|
||||
public static Card changeZone(final PlayerZone prev, final PlayerZone zone, final Card c) {
|
||||
if ((prev == null) && !c.isToken()) {
|
||||
zone.add(c);
|
||||
Player p = zone.getPlayer();
|
||||
if (p != null){
|
||||
p.updateLabelObservers();
|
||||
}
|
||||
return c;
|
||||
}
|
||||
|
||||
@@ -190,6 +194,11 @@ public class GameAction {
|
||||
|
||||
prev.remove(c);
|
||||
}
|
||||
|
||||
Player p = zone.getPlayer();
|
||||
if (p != null){
|
||||
p.updateLabelObservers();
|
||||
}
|
||||
|
||||
final HashMap<String, Object> runParams = new HashMap<String, Object>();
|
||||
runParams.put("Card", lastKnownInfo);
|
||||
|
||||
@@ -2733,6 +2733,10 @@ public abstract class Player extends GameEntity {
|
||||
public final Object getMustAttackEntity() {
|
||||
return this.mustAttackEntity;
|
||||
}
|
||||
|
||||
public final void updateLabelObservers() {
|
||||
this.getZone(Zone.Hand).updateObservers();
|
||||
}
|
||||
|
||||
// //////////////////////////////
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user