From 7225f1143a0fa2c2176bb09c52cdf5f52c94682e Mon Sep 17 00:00:00 2001 From: Cekis Date: Sun, 29 Jan 2017 06:25:32 +0000 Subject: [PATCH] Fixed issue occurring when taskId could not be found. --- .../game/script/quest/task/ground/give_item_to_npc.java | 4 ++++ 1 file changed, 4 insertions(+) mode change 100644 => 100755 sku.0/sys.server/compiled/game/script/quest/task/ground/give_item_to_npc.java diff --git a/sku.0/sys.server/compiled/game/script/quest/task/ground/give_item_to_npc.java b/sku.0/sys.server/compiled/game/script/quest/task/ground/give_item_to_npc.java old mode 100644 new mode 100755 index ab7231a7b..697a9d81d --- a/sku.0/sys.server/compiled/game/script/quest/task/ground/give_item_to_npc.java +++ b/sku.0/sys.server/compiled/game/script/quest/task/ground/give_item_to_npc.java @@ -30,6 +30,10 @@ public class give_item_to_npc extends script.base_script } int questCrc = groundquests.getQuestIdFromString(questName); int taskId = groundquests.getTaskId(questCrc, taskName); + if(taskId == -1){ + LOG("groundquests","Task could not be found for this quest."); + return SCRIPT_CONTINUE; + } if (!questIsTaskActive(questCrc, taskId, giver)) { if (hasObjVar(self, "alternate_quest_name"))