magefree / mage

Magic Another Game Engine
http://xmage.today
MIT License
1.84k stars 759 forks source link

Client-side error on watching a game and trying to look at the back face of a dfc #12225

Open Susucre opened 4 months ago

Susucre commented 4 months ago

I was watching a game, there was a flipped [[Ajani, Nacatl Avenger]], I did click on the button to see the other face, and that did cause the following error:

FATAL 2024-05-05 15:41:01,466 Client error =>[AWT-EventQueue-0] CallbackClientImpl.handleException 
java.lang.ClassCastException: mage.view.CardView cannot be cast to mage.view.PermanentView
    at org.mage.card.arcane.CardPanel.getOriginalPermanent(CardPanel.java:839)
    at mage.client.game.BattlefieldPanel.update(BattlefieldPanel.java:159)
    at mage.client.game.PlayAreaPanel.update(PlayAreaPanel.java:532)
    at mage.client.game.GamePanel.updateGame(GamePanel.java:884)
    at mage.client.game.GamePanel.updateGame(GamePanel.java:785)
    at mage.client.game.GamePanel.updateGame(GamePanel.java:773)
    at mage.client.game.GamePanel.inform(GamePanel.java:1770)
    at mage.client.remote.CallbackClientImpl.lambda$onCallback$2(CallbackClientImpl.java:412)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
    at java.awt.EventQueue.access$500(EventQueue.java:97)
    at java.awt.EventQueue$3.run(EventQueue.java:709)
    at java.awt.EventQueue$3.run(EventQueue.java:703)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
github-actions[bot] commented 4 months ago

Ajani, Nacatl Pariah // Ajani, Nacatl Avenger - (Gatherer) (Scryfall) (EDHREC)

{1}{W} Legendary Creature — Cat Warrior 1/2 When Ajani, Nacatl Pariah enters the battlefield, create a 2/1 white Cat Warrior creature token. Whenever one or more other Cats you control die, you may exile Ajani, then return him to the battlefield transformed under his owner's control. :arrows_counterclockwise: Legendary Planeswalker — Ajani 3 +2: Put a +1/+1 counter on each Cat you control. 0: Create a 2/1 white Cat Warrior creature token. When you do, if you control a red permanent other than Ajani, Nacatl Avenger, he deals damage equal to the number of creatures you control to any target. −4: Each opponent chooses an artifact, a creature, an enchantment and a planeswalker from among the nonland permanents they control, then sacrifices the rest.