Exemplo n.º 1
0
        new public static SlowSpellAction fromJSON(ObjectJSON json)
        {
            SlowSpellAction output = new SlowSpellAction();

            output.entityId     = json.getInt("entityId");
            output.spellId      = json.getString("spellId");
            output.targetCellId = json.getInt("targetCellId");
            return(output);
        }
Exemplo n.º 2
0
        public static Action fromJSON(ObjectJSON json)
        {
            switch (json.getString("class"))
            {
            case "QuickSpellAction":
                return(QuickSpellAction.fromJSON(json));

            case "MovementAction":
                return(MovementAction.fromJSON(json));

            case "SlowSpellAction":
                return(SlowSpellAction.fromJSON(json));

            default:
                return(null);
            }
        }