GUI: fixed wrong feedback panel status in computer games (related to #11189)

This commit is contained in:
Oleg Agafonov 2023-09-22 11:00:47 +04:00
parent 598aaa7632
commit abda1fb53b
5 changed files with 17 additions and 17 deletions

View file

@ -49,7 +49,7 @@ public enum ClientCallbackMethod {
// game
START_GAME(ClientCallbackType.TABLE_CHANGE, "startGame"),
GAME_INIT(ClientCallbackType.TABLE_CHANGE, "gameInit"),
GAME_INFORM(ClientCallbackType.MESSAGE, "gameInform"),
GAME_UPDATE_AND_INFORM(ClientCallbackType.UPDATE, "gameInform"), // update game and feedback panel with current status (e.g. on non our priority)
GAME_INFORM_PERSONAL(ClientCallbackType.MESSAGE, "gameInformPersonal"),
GAME_ERROR(ClientCallbackType.MESSAGE, "gameError"),
GAME_UPDATE(ClientCallbackType.UPDATE, "gameUpdate"),

View file

@ -7,26 +7,26 @@ package mage.interfaces.callback;
*/
public enum ClientCallbackType {
TABLE_CHANGE,
UPDATE(true, true),
MESSAGE(true, false),
DIALOG,
CLIENT_SIDE_EVENT(true, true);
UPDATE(true, true), // game update
TABLE_CHANGE, // all important game events + game update
MESSAGE(true, false), // show message/log without game update
DIALOG, // all dialogs + game update
CLIENT_SIDE_EVENT(true, true); // without game uodate
final boolean canProcessInAnyOrder;
final boolean mustIgnoreOnOutdated;
final boolean canComeInAnyOrder;
final boolean mustIgnoreOnOutdated; // if event come in any order and contain game update then it must be ignored on outdate
ClientCallbackType() {
this(false, false);
}
ClientCallbackType(boolean canProcessInAnyOrder, boolean mustIgnoreOnOutdated) {
this.canProcessInAnyOrder = canProcessInAnyOrder;
ClientCallbackType(boolean canComeInAnyOrder, boolean mustIgnoreOnOutdated) {
this.canComeInAnyOrder = canComeInAnyOrder;
this.mustIgnoreOnOutdated = mustIgnoreOnOutdated;
}
public boolean canProcessInAnyOrder() {
return this.canProcessInAnyOrder;
public boolean canComeInAnyOrder() {
return this.canComeInAnyOrder;
}
public boolean mustIgnoreOnOutdated() {