diff --git a/src/main/java/emu/grasscutter/game/player/PlayerProgress.java b/src/main/java/emu/grasscutter/game/player/PlayerProgress.java index ea5fb457d..5ac575f5a 100644 --- a/src/main/java/emu/grasscutter/game/player/PlayerProgress.java +++ b/src/main/java/emu/grasscutter/game/player/PlayerProgress.java @@ -8,7 +8,6 @@ import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap; import it.unimi.dsi.fastutil.ints.IntArrayList; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; - import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; diff --git a/src/main/java/emu/grasscutter/game/quest/GameQuest.java b/src/main/java/emu/grasscutter/game/quest/GameQuest.java index 9466577b8..904a7b404 100644 --- a/src/main/java/emu/grasscutter/game/quest/GameQuest.java +++ b/src/main/java/emu/grasscutter/game/quest/GameQuest.java @@ -155,8 +155,8 @@ public class GameQuest { // TODO improve var oldState = state; if (questData.getFinishCond() != null && questData.getFinishCond().size() != 0) { - for(var condition : questData.getFinishCond()) { - if(condition.getType() == QuestContent.QUEST_CONTENT_LUA_NOTIFY) { + for (var condition : questData.getFinishCond()) { + if (condition.getType() == QuestContent.QUEST_CONTENT_LUA_NOTIFY) { this.getOwner().getPlayerProgress().resetCurrentProgress(condition.getParamStr()); } } @@ -164,8 +164,8 @@ public class GameQuest { } if (questData.getFailCond() != null && questData.getFailCond().size() != 0) { - for(var condition : questData.getFailCond()) { - if(condition.getType() == QuestContent.QUEST_CONTENT_LUA_NOTIFY) { + for (var condition : questData.getFailCond()) { + if (condition.getType() == QuestContent.QUEST_CONTENT_LUA_NOTIFY) { this.getOwner().getPlayerProgress().resetCurrentProgress(condition.getParamStr()); } } diff --git a/src/main/java/emu/grasscutter/game/quest/content/ContentAddQuestProgress.java b/src/main/java/emu/grasscutter/game/quest/content/ContentAddQuestProgress.java index 9b6aa3c7c..cdf1ff0f5 100644 --- a/src/main/java/emu/grasscutter/game/quest/content/ContentAddQuestProgress.java +++ b/src/main/java/emu/grasscutter/game/quest/content/ContentAddQuestProgress.java @@ -14,7 +14,8 @@ public class ContentAddQuestProgress extends BaseContent { public boolean execute( GameQuest quest, QuestData.QuestContentCondition condition, String paramStr, int... params) { val progressId = condition.getParam()[0]; - val currentCount = quest.getOwner().getPlayerProgress().getCurrentProgress(String.valueOf(progressId)); + val currentCount = + quest.getOwner().getPlayerProgress().getCurrentProgress(String.valueOf(progressId)); // if the condition count is 0 I think it is safe to assume that the // condition count from EXEC only needs to be 1 diff --git a/src/main/java/emu/grasscutter/game/quest/content/ContentLuaNotify.java b/src/main/java/emu/grasscutter/game/quest/content/ContentLuaNotify.java index 4f87f608d..47d65bcd8 100644 --- a/src/main/java/emu/grasscutter/game/quest/content/ContentLuaNotify.java +++ b/src/main/java/emu/grasscutter/game/quest/content/ContentLuaNotify.java @@ -12,6 +12,8 @@ public class ContentLuaNotify extends BaseContent { @Override public boolean execute( GameQuest quest, QuestData.QuestContentCondition condition, String paramStr, int... params) { - return condition.getParamStr().equals(paramStr) && condition.getCount() <= quest.getOwner().getPlayerProgress().getCurrentProgress(paramStr); + return condition.getParamStr().equals(paramStr) + && condition.getCount() + <= quest.getOwner().getPlayerProgress().getCurrentProgress(paramStr); } }