mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-12-16 17:05:20 +01:00
Some fix about scene script and quest (#2029)
* [ScriptLib] Query player when not get entity from scene * Fix NPE when doing quests * Add QUEST_CONTENT_SKILL trigger Q353 need it * Add some missing fields that contain in scene scripts * Add a lua table serializer implement with jackson This do not replace the original one,it is useful when debug * Fix point_array type error * feat: fix space
This commit is contained in:
@@ -132,14 +132,16 @@ public class GameMainQuest {
|
||||
|
||||
// Add rewards
|
||||
MainQuestData mainQuestData = GameData.getMainQuestDataMap().get(this.getParentQuestId());
|
||||
for (int rewardId : mainQuestData.getRewardIdList()) {
|
||||
RewardData rewardData = GameData.getRewardDataMap().get(rewardId);
|
||||
if (mainQuestData != null && mainQuestData.getRewardIdList() != null) {
|
||||
for (int rewardId : mainQuestData.getRewardIdList()) {
|
||||
RewardData rewardData = GameData.getRewardDataMap().get(rewardId);
|
||||
|
||||
if (rewardData == null) {
|
||||
continue;
|
||||
if (rewardData == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
getOwner().getInventory().addItemParamDatas(rewardData.getRewardItemList(), ActionReason.QuestReward);
|
||||
}
|
||||
|
||||
getOwner().getInventory().addItemParamDatas(rewardData.getRewardItemList(), ActionReason.QuestReward);
|
||||
}
|
||||
|
||||
// handoff main quest
|
||||
|
||||
Reference in New Issue
Block a user