All Downloads are FREE. Search and download functionalities are using the official Maven repository.

emu.grasscutter.data.binout.AbilityMixinData Maven / Gradle / Ivy

There is a newer version: 1.7.3
Show newest version
package emu.grasscutter.data.binout;

import com.google.gson.*;
import com.google.gson.annotations.SerializedName;
import com.google.gson.reflect.TypeToken;
import java.io.Serializable;
import java.util.*;

public class AbilityMixinData implements Serializable {
    private static final long serialVersionUID = -2001232313615923575L;

    public enum Type {
        AttachToGadgetStateMixin,
        AttachToStateIDMixin,
        ShieldBarMixin,
        TileAttackManagerMixin;
    }

    @SerializedName("$type")
    public Type type;

    private JsonElement modifierName;

    public List getModifierNames() {
        if (modifierName.isJsonArray()) {
            java.lang.reflect.Type listType = (new TypeToken>() {}).getType();
            List list = (new Gson()).fromJson(modifierName, listType);
            return list;
        } else {
            return Arrays.asList(modifierName.getAsString());
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy