server: improved server stability (#11285) and reworked triggers/playable logic (#8426):

* game: now all playable calculations done in game simulation, outside real game (no more freeze and ruined games by wrong Nyxbloom Ancient and other cards with wrong replacement dialog);
* game: fixed multiple problems with triggers (wrong order, duplicated calls or "too many mana" bugs, see #8426, #12087);
* tests: added data integrity checks for game's triggers (3 enabled and 3 disabled due current game engine logic);
This commit is contained in:
Oleg Agafonov 2024-04-16 23:10:04 +04:00
parent f68e435fc4
commit e8e2f23284
23 changed files with 362 additions and 120 deletions

View file

@ -820,7 +820,7 @@ public interface Player extends MageItem, Copyable<Player> {
void updateRange(Game game);
ManaOptions getManaAvailable(Game game);
ManaOptions getManaAvailable(Game originalGame);
void addAvailableTriggeredMana(List<Mana> netManaAvailable);
@ -832,7 +832,7 @@ public interface Player extends MageItem, Copyable<Player> {
PlayableObjectsList getPlayableObjects(Game game, Zone zone);
Map<UUID, ActivatedAbility> getPlayableActivatedAbilities(MageObject object, Zone zone, Game game);
Map<UUID, ActivatedAbility> getPlayableActivatedAbilities(MageObject object, Zone zone, Game originalGame);
boolean addCounters(Counter counter, UUID playerAddingCounters, Ability source, Game game);