mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 19:58:00 +00:00
Moved call to concede to non-edt thread to see correct output on WinLose screen
This commit is contained in:
@@ -2110,6 +2110,7 @@ public class Player extends GameEntity implements Comparable<Player> {
|
|||||||
* Concede.
|
* Concede.
|
||||||
*/
|
*/
|
||||||
public final void concede() { // No cantLose checks - just lose
|
public final void concede() { // No cantLose checks - just lose
|
||||||
|
FThreads.assertExecutedByEdt(false);
|
||||||
setOutcome(PlayerOutcome.concede());
|
setOutcome(PlayerOutcome.concede());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -91,12 +91,20 @@ public enum CDock implements ICDoc {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Player p = findAffectedPlayer();
|
final Player p = findAffectedPlayer();
|
||||||
if( p == null ) return;
|
if( p == null ) return;
|
||||||
// if( c.isMindSlaved() ) return
|
// if( c.isMindSlaved() ) return
|
||||||
|
|
||||||
p.concede();
|
FThreads.invokeInNewThread(new Runnable() {
|
||||||
game.getAction().checkStateEffects();
|
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
p.concede();
|
||||||
|
p.getGame().getAction().checkStateEffects();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
game = null; // no second entry possible;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user