Commit a23b29b6 authored by Melledy's avatar Melledy
Browse files

Rename excel classes

parent f1398182
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.Calendar;
......@@ -12,14 +12,14 @@ import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap;
@ResourceType(name = "DailyDungeonConfigData.json")
public class DailyDungeonData extends GameResource {
private int Id;
private int[] Monday;
private int[] Tuesday;
private int[] Wednesday;
private int[] Thursday;
private int[] Friday;
private int[] Saturday;
private int[] Sunday;
private int id;
private int[] monday;
private int[] tuesday;
private int[] wednesday;
private int[] thursday;
private int[] friday;
private int[] saturday;
private int[] sunday;
private static final int[] empty = new int[0];
private final Int2ObjectMap<int[]> map;
......@@ -30,7 +30,7 @@ public class DailyDungeonData extends GameResource {
@Override
public int getId() {
return this.Id;
return this.id;
}
public int[] getDungeonsByDay(int day) {
......@@ -39,12 +39,12 @@ public class DailyDungeonData extends GameResource {
@Override
public void onLoad() {
map.put(Calendar.MONDAY, Monday);
map.put(Calendar.TUESDAY, Tuesday);
map.put(Calendar.WEDNESDAY, Wednesday);
map.put(Calendar.THURSDAY, Thursday);
map.put(Calendar.FRIDAY, Friday);
map.put(Calendar.SATURDAY, Saturday);
map.put(Calendar.SUNDAY, Sunday);
map.put(Calendar.MONDAY, monday);
map.put(Calendar.TUESDAY, tuesday);
map.put(Calendar.WEDNESDAY, wednesday);
map.put(Calendar.THURSDAY, thursday);
map.put(Calendar.FRIDAY, friday);
map.put(Calendar.SATURDAY, saturday);
map.put(Calendar.SUNDAY, sunday);
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameData;
import emu.grasscutter.data.GameResource;
......@@ -8,25 +8,25 @@ import emu.grasscutter.game.props.SceneType;
@ResourceType(name = "DungeonExcelConfigData.json")
public class DungeonData extends GameResource {
private int Id;
private int SceneId;
private int ShowLevel;
private int PassRewardPreviewID;
private String InvolveType; // TODO enum
private int id;
private int sceneId;
private int showLevel;
private int passRewardPreviewID;
private String involveType; // TODO enum
private RewardPreviewData previewData;
@Override
public int getId() {
return this.Id;
return this.id;
}
public int getSceneId() {
return SceneId;
return sceneId;
}
public int getShowLevel() {
return ShowLevel;
return showLevel;
}
public RewardPreviewData getRewardPreview() {
......@@ -35,8 +35,8 @@ public class DungeonData extends GameResource {
@Override
public void onLoad() {
if (this.PassRewardPreviewID > 0) {
this.previewData = GameData.getRewardPreviewDataMap().get(this.PassRewardPreviewID);
if (this.passRewardPreviewID > 0) {
this.previewData = GameData.getRewardPreviewDataMap().get(this.passRewardPreviewID);
}
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.ArrayList;
import emu.grasscutter.data.GameResource;
......@@ -8,41 +8,41 @@ import emu.grasscutter.data.common.FightPropData;
@ResourceType(name = "EquipAffixExcelConfigData.json")
public class EquipAffixData extends GameResource {
private int AffixId;
private int Id;
private int Level;
private long NameTextMapHash;
private String OpenConfig;
private FightPropData[] AddProps;
private float[] ParamList;
private int affixId;
private int id;
private int level;
private long nameTextMapHash;
private String openConfig;
private FightPropData[] addProps;
private float[] paramList;
@Override
public int getId() {
return AffixId;
return affixId;
}
public int getMainId() {
return Id;
return id;
}
public int getLevel() {
return Level;
return level;
}
public long getNameTextMapHash() {
return NameTextMapHash;
return nameTextMapHash;
}
public String getOpenConfig() {
return OpenConfig;
return openConfig;
}
public FightPropData[] getAddProps() {
return AddProps;
return addProps;
}
public float[] getParamList() {
return ParamList;
return paramList;
}
@Override
......@@ -54,6 +54,6 @@ public class EquipAffixData extends GameResource {
parsed.add(prop);
}
}
this.AddProps = parsed.toArray(new FightPropData[parsed.size()]);
this.addProps = parsed.toArray(new FightPropData[parsed.size()]);
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
......@@ -6,16 +6,16 @@ import emu.grasscutter.data.ResourceType.LoadPriority;
@ResourceType(name = "FetterCharacterCardExcelConfigData.json", loadPriority = LoadPriority.HIGHEST)
public class FetterCharacterCardData extends GameResource {
private int AvatarId;
private int RewardId;
private int avatarId;
private int rewardId;
@Override
public int getId() {
return AvatarId;
return avatarId;
}
public int getRewardId() {
return RewardId;
return rewardId;
}
@Override
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.List;
......@@ -9,21 +9,21 @@ import emu.grasscutter.data.common.OpenCondData;
@ResourceType(name = {"FetterInfoExcelConfigData.json", "FettersExcelConfigData.json", "FetterStoryExcelConfigData.json", "PhotographExpressionExcelConfigData.json", "PhotographPosenameExcelConfigData.json"}, loadPriority = LoadPriority.HIGHEST)
public class FetterData extends GameResource {
private int AvatarId;
private int FetterId;
private List<OpenCondData> OpenCond;
private int avatarId;
private int fetterId;
private List<OpenCondData> openCond;
@Override
public int getId() {
return FetterId;
return fetterId;
}
public int getAvatarId() {
return AvatarId;
return avatarId;
}
public List<OpenCondData> getOpenConds() {
return OpenCond;
return openCond;
}
@Override
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
......@@ -6,53 +6,53 @@ import emu.grasscutter.game.props.EntityType;
@ResourceType(name = "GadgetExcelConfigData.json")
public class GadgetData extends GameResource {
private int Id;
private int id;
private EntityType Type;
private String JsonName;
private boolean IsInteractive;
private String[] Tags;
private String ItemJsonName;
private String InteeIconName;
private long NameTextMapHash;
private int CampID;
private EntityType type;
private String jsonName;
private boolean isInteractive;
private String[] tags;
private String itemJsonName;
private String inteeIconName;
private long nameTextMapHash;
private int campID;
private String LODPatternName;
@Override
public int getId() {
return this.Id;
return this.id;
}
public EntityType getType() {
return Type;
return type;
}
public String getJsonName() {
return JsonName;
return jsonName;
}
public boolean isInteractive() {
return IsInteractive;
return isInteractive;
}
public String[] getTags() {
return Tags;
return tags;
}
public String getItemJsonName() {
return ItemJsonName;
return itemJsonName;
}
public String getInteeIconName() {
return InteeIconName;
return inteeIconName;
}
public long getNameTextMapHash() {
return NameTextMapHash;
return nameTextMapHash;
}
public int getCampID() {
return CampID;
return campID;
}
public String getLODPatternName() { return LODPatternName; }
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
......@@ -9,164 +9,164 @@ import it.unimi.dsi.fastutil.ints.IntSet;
@ResourceType(name = {"MaterialExcelConfigData.json", "WeaponExcelConfigData.json", "ReliquaryExcelConfigData.json"})
public class ItemData extends GameResource {
private int Id;
private int StackLimit = 1;
private int MaxUseCount;
private int RankLevel;
private String EffectName;
private int[] SatiationParams;
private int Rank;
private int Weight;
private int GadgetId;
private int id;
private int stackLimit = 1;
private int maxUseCount;
private int rankLevel;
private String effectName;
private int[] satiationParams;
private int rank;
private int weight;
private int gadgetId;
private int[] DestroyReturnMaterial;
private int[] DestroyReturnMaterialCount;
private int[] destroyReturnMaterial;
private int[] destroyReturnMaterialCount;
// Food
private String FoodQuality;
private String UseTarget;
private String[] UseParam;
private String foodQuality;
private String useTarget;
private String[] iseParam;
// String enums
private String ItemType;
private String MaterialType;
private String EquipType;
private String EffectType;
private String DestroyRule;
private String itemType;
private String materialType;
private String equipType;
private String effectType;
private String destroyRule;
// Relic
private int MainPropDepotId;
private int AppendPropDepotId;
private int AppendPropNum;
private int SetId;
private int[] AddPropLevels;
private int BaseConvExp;
private int MaxLevel;
private int mainPropDepotId;
private int appendPropDepotId;
private int appendPropNum;
private int setId;
private int[] addPropLevels;
private int baseConvExp;
private int maxLevel;
// Weapon
private int WeaponPromoteId;
private int WeaponBaseExp;
private int StoryId;
private int AvatarPromoteId;
private int AwakenMaterial;
private int[] AwakenCosts;
private int[] SkillAffix;
private WeaponProperty[] WeaponProp;
private int weaponPromoteId;
private int weaponBaseExp;
private int storyId;
private int avatarPromoteId;
private int awakenMaterial;
private int[] awakenCosts;
private int[] skillAffix;
private WeaponProperty[] weaponProp;
// Hash
private String Icon;
private long NameTextMapHash;
private String icon;
private long nameTextMapHash;
// Post load
private transient emu.grasscutter.game.inventory.MaterialType materialType;
private transient emu.grasscutter.game.inventory.ItemType itemType;
private transient emu.grasscutter.game.inventory.EquipType equipType;
private transient emu.grasscutter.game.inventory.MaterialType materialEnumType;
private transient emu.grasscutter.game.inventory.ItemType itemEnumType;
private transient emu.grasscutter.game.inventory.EquipType equipEnumType;
private IntSet addPropLevelSet;
@Override
public int getId(){
return this.Id;
return this.id;
}
public String getMaterialTypeString(){
return this.MaterialType;
return this.materialType;
}
public int getStackLimit(){
return this.StackLimit;
return this.stackLimit;
}
public int getMaxUseCount(){
return this.MaxUseCount;
return this.maxUseCount;
}
public String getUseTarget(){
return this.UseTarget;
return this.useTarget;
}
public String[] getUseParam(){
return this.UseParam;
return this.iseParam;
}
public int getRankLevel(){
return this.RankLevel;
return this.rankLevel;
}
public String getFoodQuality(){
return this.FoodQuality;
return this.foodQuality;
}
public String getEffectName(){
return this.EffectName;
return this.effectName;
}
public int[] getSatiationParams(){
return this.SatiationParams;
return this.satiationParams;
}
public int[] getDestroyReturnMaterial(){
return this.DestroyReturnMaterial;
return this.destroyReturnMaterial;
}
public int[] getDestroyReturnMaterialCount(){
return this.DestroyReturnMaterialCount;
return this.destroyReturnMaterialCount;
}
public long getNameTextMapHash(){
return this.NameTextMapHash;
return this.nameTextMapHash;
}
public String getIcon(){
return this.Icon;
return this.icon;
}
public String getItemTypeString(){
return this.ItemType;
return this.itemType;
}
public int getRank(){
return this.Rank;
return this.rank;
}
public int getGadgetId() {
return GadgetId;
return gadgetId;
}
public int getBaseConvExp() {
return BaseConvExp;
return baseConvExp;
}
public int getMainPropDepotId() {
return MainPropDepotId;
return mainPropDepotId;
}
public int getAppendPropDepotId() {
return AppendPropDepotId;
return appendPropDepotId;
}
public int getAppendPropNum() {
return AppendPropNum;
return appendPropNum;
}
public int getSetId() {
return SetId;
return setId;
}
public int getWeaponPromoteId() {
return WeaponPromoteId;
return weaponPromoteId;
}
public int getWeaponBaseExp() {
return WeaponBaseExp;
return weaponBaseExp;
}
public int getAwakenMaterial() {
return AwakenMaterial;
return awakenMaterial;
}
public int[] getAwakenCosts() {
return AwakenCosts;
return awakenCosts;
}
public IntSet getAddPropLevelSet() {
......@@ -174,27 +174,27 @@ public class ItemData extends GameResource {
}
public int[] getSkillAffix() {
return SkillAffix;
return skillAffix;
}
public WeaponProperty[] getWeaponProperties() {
return WeaponProp;
return weaponProp;
}
public int getMaxLevel() {
return MaxLevel;
return maxLevel;
}
public emu.grasscutter.game.inventory.ItemType getItemType() {
return this.itemType;
return this.itemEnumType;
}
public emu.grasscutter.game.inventory.MaterialType getMaterialType() {
return this.materialType;
return this.materialEnumType;
}
public emu.grasscutter.game.inventory.EquipType getEquipType() {
return this.equipType;
return this.equipEnumType;
}
public boolean canAddRelicProp(int level) {
......@@ -202,23 +202,23 @@ public class ItemData extends GameResource {
}
public boolean isEquip() {
return this.itemType == emu.grasscutter.game.inventory.ItemType.ITEM_RELIQUARY || this.itemType == emu.grasscutter.game.inventory.ItemType.ITEM_WEAPON;
return this.itemEnumType == emu.grasscutter.game.inventory.ItemType.ITEM_RELIQUARY || this.itemEnumType == emu.grasscutter.game.inventory.ItemType.ITEM_WEAPON;
}
@Override
public void onLoad() {
this.itemType = emu.grasscutter.game.inventory.ItemType.getTypeByName(getItemTypeString());
this.materialType = emu.grasscutter.game.inventory.MaterialType.getTypeByName(getMaterialTypeString());
this.itemEnumType = emu.grasscutter.game.inventory.ItemType.getTypeByName(getItemTypeString());
this.materialEnumType = emu.grasscutter.game.inventory.MaterialType.getTypeByName(getMaterialTypeString());
if (this.itemType == emu.grasscutter.game.inventory.ItemType.ITEM_RELIQUARY) {
this.equipType = emu.grasscutter.game.inventory.EquipType.getTypeByName(this.EquipType);
if (this.AddPropLevels != null && this.AddPropLevels.length > 0) {
this.addPropLevelSet = new IntOpenHashSet(this.AddPropLevels);
if (this.itemEnumType == emu.grasscutter.game.inventory.ItemType.ITEM_RELIQUARY) {
this.equipEnumType = emu.grasscutter.game.inventory.EquipType.getTypeByName(this.equipType);
if (this.addPropLevels != null && this.addPropLevels.length > 0) {
this.addPropLevelSet = new IntOpenHashSet(this.addPropLevels);
}
} else if (this.itemType == emu.grasscutter.game.inventory.ItemType.ITEM_WEAPON) {
this.equipType = emu.grasscutter.game.inventory.EquipType.EQUIP_WEAPON;
} else if (this.itemEnumType == emu.grasscutter.game.inventory.ItemType.ITEM_WEAPON) {
this.equipEnumType = emu.grasscutter.game.inventory.EquipType.EQUIP_WEAPON;
} else {
this.equipType = emu.grasscutter.game.inventory.EquipType.EQUIP_NONE;
this.equipEnumType = emu.grasscutter.game.inventory.EquipType.EQUIP_NONE;
}
if (this.getWeaponProperties() != null) {
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.HashMap;
import java.util.Map;
......@@ -10,23 +10,23 @@ import emu.grasscutter.data.common.CurveInfo;
@ResourceType(name = "MonsterCurveExcelConfigData.json")
public class MonsterCurveData extends GameResource {
private int Level;
private CurveInfo[] CurveInfos;
private int level;
private CurveInfo[] curveInfos;
private Map<String, Float> curveInfos;
private Map<String, Float> curveInfoMap;
@Override
public int getId() {
return Level;
return level;
}
public float getMultByProp(String fightProp) {
return curveInfos.getOrDefault(fightProp, 1f);
return curveInfoMap.getOrDefault(fightProp, 1f);
}
@Override
public void onLoad() {
this.curveInfos = new HashMap<>();
Stream.of(this.CurveInfos).forEach(info -> this.curveInfos.put(info.getType(), info.getValue()));
this.curveInfoMap = new HashMap<>();
Stream.of(this.curveInfos).forEach(info -> this.curveInfoMap.put(info.getType(), info.getValue()));
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.List;
......@@ -10,152 +10,153 @@ import emu.grasscutter.data.common.PropGrowCurve;
@ResourceType(name = "MonsterExcelConfigData.json", loadPriority = LoadPriority.LOW)
public class MonsterData extends GameResource {
private int Id;
private String MonsterName;
private String Type;
private String ServerScript;
private List<Integer> Affix;
private String Ai;
private int[] Equips;
private List<HpDrops> HpDrops;
private int KillDropId;
private String ExcludeWeathers;
private int FeatureTagGroupID;
private int MpPropID;
private String Skin;
private int DescribeId;
private int CombatBGMLevel;
private int EntityBudgetLevel;
private float HpBase;
private float AttackBase;
private float DefenseBase;
private float FireSubHurt;
private float ElecSubHurt;
private float GrassSubHurt;
private float WaterSubHurt;
private float WindSubHurt;
private float RockSubHurt;
private float IceSubHurt;
private float PhysicalSubHurt;
private List<PropGrowCurve> PropGrowCurves;
private long NameTextMapHash;
private int CampID;
private int id;
private String monsterName;
private String type;
private String serverScript;
private List<Integer> affix;
private String ai;
private int[] equips;
private List<HpDrops> hpDrops;
private int killDropId;
private String excludeWeathers;
private int featureTagGroupID;
private int mpPropID;
private String skin;
private int describeId;
private int combatBGMLevel;
private int entityBudgetLevel;
private float hpBase;
private float attackBase;
private float defenseBase;
private float fireSubHurt;
private float elecSubHurt;
private float grassSubHurt;
private float waterSubHurt;
private float windSubHurt;
private float rockSubHurt;
private float iceSubHurt;
private float physicalSubHurt;
private List<PropGrowCurve> propGrowCurves;
private long nameTextMapHash;
private int campID;
// Transient
private int weaponId;
private MonsterDescribeData describeData;
@Override
public int getId() {
return this.Id;
return this.id;
}
public String getMonsterName() {
return MonsterName;
return monsterName;
}
public String getType() {
return Type;
return type;
}
public String getServerScript() {
return ServerScript;
return serverScript;
}
public List<Integer> getAffix() {
return Affix;
return affix;
}
public String getAi() {
return Ai;
return ai;
}
public int[] getEquips() {
return Equips;
return equips;
}
public List<HpDrops> getHpDrops() {
return HpDrops;
return hpDrops;
}
public int getKillDropId() {
return KillDropId;
return killDropId;
}
public String getExcludeWeathers() {
return ExcludeWeathers;
return excludeWeathers;
}
public int getFeatureTagGroupID() {
return FeatureTagGroupID;
return featureTagGroupID;
}
public int getMpPropID() {
return MpPropID;
return mpPropID;
}
public String getSkin() {
return Skin;
return skin;
}
public int getDescribeId() {
return DescribeId;
return describeId;
}
public int getCombatBGMLevel() {
return CombatBGMLevel;
return combatBGMLevel;
}
public int getEntityBudgetLevel() {
return EntityBudgetLevel;
return entityBudgetLevel;
}
public float getBaseHp() {
return HpBase;
return hpBase;
}
public float getBaseAttack() {
return AttackBase;
return attackBase;
}
public float getBaseDefense() {
return DefenseBase;
return defenseBase;
}
public float getElecSubHurt() {
return ElecSubHurt;
return elecSubHurt;
}
public float getGrassSubHurt() {
return GrassSubHurt;
return grassSubHurt;
}
public float getWaterSubHurt() {
return WaterSubHurt;
return waterSubHurt;
}
public float getWindSubHurt() {
return WindSubHurt;
return windSubHurt;
}
public float getIceSubHurt() {
return IceSubHurt;
return iceSubHurt;
}
public float getPhysicalSubHurt() {
return PhysicalSubHurt;
return physicalSubHurt;
}
public List<PropGrowCurve> getPropGrowCurves() {
return PropGrowCurves;
return propGrowCurves;
}
public long getNameTextMapHash() {
return NameTextMapHash;
return nameTextMapHash;
}
public int getCampID() {
return CampID;
return campID;
}
public MonsterDescribeData getDescribeData() {
......@@ -170,7 +171,7 @@ public class MonsterData extends GameResource {
public void onLoad() {
this.describeData = GameData.getMonsterDescribeDataMap().get(this.getDescribeId());
for (int id : this.Equips) {
for (int id : this.equips) {
if (id == 0) {
continue;
}
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
......@@ -6,31 +6,31 @@ import emu.grasscutter.data.ResourceType.LoadPriority;
@ResourceType(name = "MonsterDescribeExcelConfigData.json", loadPriority = LoadPriority.HIGH)
public class MonsterDescribeData extends GameResource {
private int Id;
private long NameTextMapHash;
private int TitleID;
private int SpecialNameLabID;
private String Icon;
private int id;
private long nameTextMapHash;
private int titleID;
private int specialNameLabID;
private String icon;
@Override
public int getId() {
return Id;
return id;
}
public long getNameTextMapHash() {
return NameTextMapHash;
return nameTextMapHash;
}
public int getTitleID() {
return TitleID;
return titleID;
}
public int getSpecialNameLabID() {
return SpecialNameLabID;
return specialNameLabID;
}
public String getIcon() {
return Icon;
return icon;
}
@Override
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
@ResourceType(name = "NpcExcelConfigData.json")
public class NpcData extends GameResource {
private int Id;
private int id;
private String JsonName;
private String Alias;
private String ScriptDataPath;
private String LuaDataPath;
private String jsonName;
private String alias;
private String scriptDataPath;
private String luaDataPath;
private boolean IsInteractive;
private boolean HasMove;
private String DyePart;
private String BillboardIcon;
private boolean isInteractive;
private boolean hasMove;
private String dyePart;
private String billboardIcon;
private long NameTextMapHash;
private int CampID;
private long nameTextMapHash;
private int campID;
@Override
public int getId() {
return this.Id;
return this.id;
}
public String getJsonName() {
return JsonName;
return jsonName;
}
public String getAlias() {
return Alias;
return alias;
}
public String getScriptDataPath() {
return ScriptDataPath;
return scriptDataPath;
}
public String getLuaDataPath() {
return LuaDataPath;
return luaDataPath;
}
public boolean isIsInteractive() {
return IsInteractive;
return isInteractive;
}
public boolean isHasMove() {
return HasMove;
return hasMove;
}
public String getDyePart() {
return DyePart;
return dyePart;
}
public String getBillboardIcon() {
return BillboardIcon;
return billboardIcon;
}
public long getNameTextMapHash() {
return NameTextMapHash;
return nameTextMapHash;
}
public int getCampID() {
return CampID;
return campID;
}
@Override
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
@ResourceType(name = "PlayerLevelExcelConfigData.json")
public class PlayerLevelData extends GameResource {
private int Level;
private int Exp;
private int RewardId;
private int UnlockWorldLevel;
private int level;
private int exp;
private int rewardId;
private int unlockWorldLevel;
@Override
public int getId() {
return this.Level;
return this.level;
}
public int getLevel() {
return Level;
return level;
}
public int getExp() {
return Exp;
return exp;
}
public int getRewardId() {
return RewardId;
return rewardId;
}
public int getUnlockWorldLevel() {
return UnlockWorldLevel;
return unlockWorldLevel;
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.ArrayList;
import java.util.List;
......@@ -11,82 +11,82 @@ import emu.grasscutter.data.common.ItemParamData;
@ResourceType(name = "ProudSkillExcelConfigData.json")
public class ProudSkillData extends GameResource {
private int ProudSkillId;
private int ProudSkillGroupId;
private int Level;
private int CoinCost;
private int BreakLevel;
private int ProudSkillType;
private String OpenConfig;
private List<ItemParamData> CostItems;
private List<String> FilterConds;
private List<String> LifeEffectParams;
private FightPropData[] AddProps;
private float[] ParamList;
private long[] ParamDescList;
private long NameTextMapHash;
private int proudSkillId;
private int proudSkillGroupId;
private int level;
private int coinCost;
private int breakLevel;
private int proudSkillType;
private String openConfig;
private List<ItemParamData> costItems;
private List<String> filterConds;
private List<String> lifeEffectParams;
private FightPropData[] addProps;
private float[] paramList;
private long[] paramDescList;
private long nameTextMapHash;
@Override
public int getId() {
return ProudSkillId;
return proudSkillId;
}
public int getProudSkillGroupId() {
return ProudSkillGroupId;
return proudSkillGroupId;
}
public int getLevel() {
return Level;
return level;
}
public int getCoinCost() {
return CoinCost;
return coinCost;
}
public int getBreakLevel() {
return BreakLevel;
return breakLevel;
}
public int getProudSkillType() {
return ProudSkillType;
return proudSkillType;
}
public String getOpenConfig() {
return OpenConfig;
return openConfig;
}
public List<ItemParamData> getCostItems() {
return CostItems;
return costItems;
}
public List<String> getFilterConds() {
return FilterConds;
return filterConds;
}
public List<String> getLifeEffectParams() {
return LifeEffectParams;
return lifeEffectParams;
}
public FightPropData[] getAddProps() {
return AddProps;
return addProps;
}
public float[] getParamList() {
return ParamList;
return paramList;
}
public long[] getParamDescList() {
return ParamDescList;
return paramDescList;
}
public long getNameTextMapHash() {
return NameTextMapHash;
return nameTextMapHash;
}
@Override
public void onLoad() {
if (this.getOpenConfig() != null & this.getOpenConfig().length() > 0) {
this.OpenConfig = "Avatar_" + this.getOpenConfig();
this.openConfig = "Avatar_" + this.getOpenConfig();
}
// Fight props
ArrayList<FightPropData> parsed = new ArrayList<FightPropData>(getAddProps().length);
......@@ -96,6 +96,6 @@ public class ProudSkillData extends GameResource {
parsed.add(prop);
}
}
this.AddProps = parsed.toArray(new FightPropData[parsed.size()]);
this.addProps = parsed.toArray(new FightPropData[parsed.size()]);
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.Arrays;
import java.util.List;
......@@ -10,54 +10,54 @@ import emu.grasscutter.game.quest.enums.QuestTrigger;
@ResourceType(name = "QuestExcelConfigData.json")
public class QuestData extends GameResource {
private int SubId;
private int MainId;
private int Order;
private long DescTextMapHash;
private int subId;
private int mainId;
private int order;
private long descTextMapHash;
private boolean FinishParent;
private boolean IsRewind;
private boolean finishParent;
private boolean isRewind;
private LogicType AcceptCondComb;
private LogicType acceptCondComb;
private QuestCondition[] acceptConditons;
private LogicType FinishCondComb;
private LogicType finishCondComb;
private QuestCondition[] finishConditons;
private LogicType FailCondComb;
private LogicType failCondComb;
private QuestCondition[] failConditons;
private List<QuestParam> AcceptCond;
private List<QuestParam> FinishCond;
private List<QuestParam> FailCond;
private List<QuestExecParam> BeginExec;
private List<QuestExecParam> FinishExec;
private List<QuestExecParam> FailExec;
private List<QuestParam> acceptCond;
private List<QuestParam> finishCond;
private List<QuestParam> failCond;
private List<QuestExecParam> beginExec;
private List<QuestExecParam> finishExec;
private List<QuestExecParam> failExec;
public int getId() {
return SubId;
return subId;
}
public int getMainId() {
return MainId;
return mainId;
}
public int getOrder() {
return Order;
return order;
}
public long getDescTextMapHash() {
return DescTextMapHash;
return descTextMapHash;
}
public boolean finishParent() {
return FinishParent;
return finishParent;
}
public boolean isRewind() {
return IsRewind;
return isRewind;
}
public LogicType getAcceptCondComb() {
return AcceptCondComb;
return acceptCondComb;
}
public QuestCondition[] getAcceptCond() {
......@@ -65,7 +65,7 @@ public class QuestData extends GameResource {
}
public LogicType getFinishCondComb() {
return FinishCondComb;
return finishCondComb;
}
public QuestCondition[] getFinishCond() {
......@@ -73,7 +73,7 @@ public class QuestData extends GameResource {
}
public LogicType getFailCondComb() {
return FailCondComb;
return failCondComb;
}
public QuestCondition[] getFailCond() {
......@@ -81,12 +81,12 @@ public class QuestData extends GameResource {
}
public void onLoad() {
this.acceptConditons = AcceptCond.stream().filter(p -> p.Type != null).map(QuestCondition::new).toArray(QuestCondition[]::new);
AcceptCond = null;
this.finishConditons = FinishCond.stream().filter(p -> p.Type != null).map(QuestCondition::new).toArray(QuestCondition[]::new);
FinishCond = null;
this.failConditons = FailCond.stream().filter(p -> p.Type != null).map(QuestCondition::new).toArray(QuestCondition[]::new);
FailCond = null;
this.acceptConditons = acceptCond.stream().filter(p -> p.Type != null).map(QuestCondition::new).toArray(QuestCondition[]::new);
acceptCond = null;
this.finishConditons = finishCond.stream().filter(p -> p.Type != null).map(QuestCondition::new).toArray(QuestCondition[]::new);
finishCond = null;
this.failConditons = failCond.stream().filter(p -> p.Type != null).map(QuestCondition::new).toArray(QuestCondition[]::new);
failCond = null;
}
public class QuestParam {
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
......@@ -10,39 +10,37 @@ public class ReliquaryAffixData extends GameResource {
private int DepotId;
private int GroupId;
private String PropType;
private FightProperty PropType;
private float PropValue;
private int Weight;
private int UpgradeWeight;
private FightProperty fightProp;
@Override
public int getId() {
return Id;
}
public int getDepotId() {
return DepotId;
}
public int getGroupId() {
return GroupId;
}
public float getPropValue() {
return PropValue;
}
public int getWeight() {
return Weight;
}
public int getUpgradeWeight() {
return UpgradeWeight;
}
public FightProperty getFightProp() {
return fightProp;
}
@Override
public void onLoad() {
this.fightProp = FightProperty.getPropByName(this.PropType);
return PropType;
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.List;
......@@ -13,10 +13,10 @@ public class ReliquaryLevelData extends GameResource {
private int id;
private Int2ObjectMap<Float> propMap;
private int Rank;
private int Level;
private int Exp;
private List<RelicLevelProperty> AddProps;
private int rank;
private int level;
private int exp;
private List<RelicLevelProperty> addProps;
@Override
public int getId() {
......@@ -24,15 +24,15 @@ public class ReliquaryLevelData extends GameResource {
}
public int getRank() {
return Rank;
return rank;
}
public int getLevel() {
return Level;
return level;
}
public int getExp() {
return Exp;
return exp;
}
public float getPropValue(FightProperty prop) {
......@@ -45,23 +45,23 @@ public class ReliquaryLevelData extends GameResource {
@Override
public void onLoad() {
this.id = (Rank << 8) + this.getLevel();
this.id = (rank << 8) + this.getLevel();
this.propMap = new Int2ObjectOpenHashMap<>();
for (RelicLevelProperty p : AddProps) {
for (RelicLevelProperty p : addProps) {
this.propMap.put(FightProperty.getPropByName(p.getPropType()).getId(), (Float) p.getValue());
}
}
public class RelicLevelProperty {
private String PropType;
private float Value;
private String propType;
private float value;
public String getPropType() {
return PropType;
return propType;
}
public float getValue() {
return Value;
return value;
}
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
......@@ -6,32 +6,26 @@ import emu.grasscutter.game.props.FightProperty;
@ResourceType(name = "ReliquaryMainPropExcelConfigData.json")
public class ReliquaryMainPropData extends GameResource {
private int Id;
private int id;
private int PropDepotId;
private String PropType;
private String AffixName;
private int Weight;
private FightProperty fightProp;
private int propDepotId;
private FightProperty propType;
private int weight;
@Override
public int getId() {
return Id;
return id;
}
public int getPropDepotId() {
return PropDepotId;
return propDepotId;
}
public int getWeight() {
return Weight;
return weight;
}
public FightProperty getFightProp() {
return fightProp;
}
@Override
public void onLoad() {
this.fightProp = FightProperty.getPropByName(this.PropType);
return propType;
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import emu.grasscutter.data.GameResource;
import emu.grasscutter.data.ResourceType;
@ResourceType(name = "ReliquarySetExcelConfigData.json")
public class ReliquarySetData extends GameResource {
private int SetId;
private int[] SetNeedNum;
private int setId;
private int[] setNeedNum;
private int EquipAffixId;
private int DisableFilter;
private int[] ContainsList;
private int disableFilter;
private int[] containsList;
@Override
public int getId() {
return SetId;
return setId;
}
public int[] getSetNeedNum() {
return SetNeedNum;
return setNeedNum;
}
public int getEquipAffixId() {
......@@ -25,11 +25,11 @@ public class ReliquarySetData extends GameResource {
}
public int getDisableFilter() {
return DisableFilter;
return disableFilter;
}
public int[] getContainsList() {
return ContainsList;
return containsList;
}
@Override
......
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.List;
......@@ -8,20 +8,20 @@ import emu.grasscutter.data.common.ItemParamData;
@ResourceType(name = "RewardExcelConfigData.json")
public class RewardData extends GameResource {
public int RewardId;
public List<ItemParamData> RewardItemList;
public int rewardId;
public List<ItemParamData> rewardItemList;
@Override
public int getId() {
return RewardId;
return rewardId;
}
public List<ItemParamData> getRewardItemList() {
return RewardItemList;
return rewardItemList;
}
@Override
public void onLoad() {
RewardItemList = RewardItemList.stream().filter(i -> i.getId() > 0).toList();
rewardItemList = rewardItemList.stream().filter(i -> i.getId() > 0).toList();
}
}
package emu.grasscutter.data.def;
package emu.grasscutter.data.excels;
import java.util.Arrays;
import java.util.List;
......@@ -16,28 +16,28 @@ import emu.grasscutter.data.common.ItemParamStringData;
@ResourceType(name = "RewardPreviewExcelConfigData.json", loadPriority = LoadPriority.HIGH)
public class RewardPreviewData extends GameResource {
private int Id;
private ItemParamStringData[] PreviewItems;
private ItemParamData[] PreviewItemsArray;
private int id;
private ItemParamStringData[] previewItems;
private ItemParamData[] previewItemsArray;
@Override
public int getId() {
return this.Id;
return this.id;
}
public ItemParamData[] getPreviewItems() {
return PreviewItemsArray;
return previewItemsArray;
}
@Override
public void onLoad() {
if (this.PreviewItems != null && this.PreviewItems.length > 0) {
this.PreviewItemsArray = Arrays.stream(this.PreviewItems)
if (this.previewItems != null && this.previewItems.length > 0) {
this.previewItemsArray = Arrays.stream(this.previewItems)
.filter(d -> d.getId() > 0 && d.getCount() != null && !d.getCount().isEmpty())
.map(ItemParamStringData::toItemParamData)
.toArray(size -> new ItemParamData[size]);
} else {
this.PreviewItemsArray = new ItemParamData[0];
this.previewItemsArray = new ItemParamData[0];
}
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment