mirror of
https://github.com/magefree/mage.git
synced 2025-12-22 19:41:59 -08:00
Fixed a bunch of NPE and other possible exceptions.
This commit is contained in:
parent
38b72284da
commit
c2fb2de67a
12 changed files with 65 additions and 18 deletions
|
|
@ -95,8 +95,8 @@ public class GameView implements Serializable {
|
|||
}
|
||||
for (StackObject stackObject: state.getStack()) {
|
||||
if (stackObject instanceof StackAbility) {
|
||||
// Stack Ability
|
||||
MageObject object = game.getObject(stackObject.getSourceId());
|
||||
// Stack Ability
|
||||
MageObject object = ((StackAbility)stackObject).getSourceObject(game);
|
||||
Card card = game.getCard(stackObject.getSourceId());
|
||||
if (card != null) {
|
||||
if (object != null) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue