local L0_1, L1_1, L2_1, L3_1, L4_1, L5_1, L6_1, L7_1, L8_1, L9_1, L10_1 L0_1 = {} L0_1.group_id = 133007230 L1_1 = {} L1_1.group_id = 133007230 L1_1.battle_radius = 15 L1_1.battle_time = 120 L1_1.battle_progress = 3 L1_1.seal_model = 973 L1_1.seal_id = 976 L1_1.light_1 = 230002 L1_1.light_2 = 230003 L1_1.light_3 = 230004 L2_1 = {} L3_1 = {} L3_1.config_id = 422 L3_1.monster_id = 22010101 L4_1 = {} L4_1.x = 2561.086 L4_1.y = 208.524 L4_1.z = 311.213 L3_1.pos = L4_1 L4_1 = {} L4_1.x = 0.0 L4_1.y = 0.0 L4_1.z = 0.0 L3_1.rot = L4_1 L3_1.level = 24 L3_1.drop_id = 1000100 L3_1.area_id = 4 L4_1 = {} L4_1.config_id = 423 L4_1.monster_id = 21030201 L5_1 = {} L5_1.x = 2569.039 L5_1.y = 208.202 L5_1.z = 305.856 L4_1.pos = L5_1 L5_1 = {} L5_1.x = 0.0 L5_1.y = 0.0 L5_1.z = 0.0 L4_1.rot = L5_1 L4_1.level = 22 L4_1.drop_id = 1000100 L4_1.area_id = 4 L5_1 = {} L5_1.config_id = 424 L5_1.monster_id = 21030201 L6_1 = {} L6_1.x = 2567.324 L6_1.y = 208.108 L6_1.z = 319.888 L5_1.pos = L6_1 L6_1 = {} L6_1.x = 0.0 L6_1.y = 0.0 L6_1.z = 0.0 L5_1.rot = L6_1 L5_1.level = 22 L5_1.drop_id = 1000100 L5_1.area_id = 4 L2_1[1] = L3_1 L2_1[2] = L4_1 L2_1[3] = L5_1 monsters = L2_1 L2_1 = {} npcs = L2_1 L2_1 = {} L3_1 = {} L3_1.config_id = 973 L3_1.gadget_id = 70950008 L4_1 = {} L4_1.x = 2566.507 L4_1.y = 208.411 L4_1.z = 311.177 L3_1.pos = L4_1 L4_1 = {} L4_1.x = 0.0 L4_1.y = 81.978 L4_1.z = 0.0 L3_1.rot = L4_1 L3_1.level = 28 L3_1.persistent = true L3_1.area_id = 4 L4_1 = {} L4_1.config_id = 976 L4_1.gadget_id = 70950007 L5_1 = {} L5_1.x = 2566.5 L5_1.y = 208.4 L5_1.z = 311.2 L4_1.pos = L5_1 L5_1 = {} L5_1.x = 0.0 L5_1.y = 278.917 L5_1.z = 0.0 L4_1.rot = L5_1 L4_1.level = 28 L5_1 = GadgetState L5_1 = L5_1.GearStop L4_1.state = L5_1 L4_1.area_id = 4 L5_1 = {} L5_1.config_id = 230002 L5_1.gadget_id = 70950006 L6_1 = {} L6_1.x = 2561.456 L6_1.y = 208.793 L6_1.z = 337.677 L5_1.pos = L6_1 L6_1 = {} L6_1.x = 0.0 L6_1.y = 0.0 L6_1.z = 0.0 L5_1.rot = L6_1 L5_1.level = 1 L5_1.area_id = 4 L6_1 = {} L6_1.config_id = 230003 L6_1.gadget_id = 70950006 L7_1 = {} L7_1.x = 2589.25 L7_1.y = 206.739 L7_1.z = 299.651 L6_1.pos = L7_1 L7_1 = {} L7_1.x = 0.0 L7_1.y = 0.0 L7_1.z = 0.0 L6_1.rot = L7_1 L6_1.level = 1 L6_1.area_id = 4 L7_1 = {} L7_1.config_id = 230004 L7_1.gadget_id = 70950006 L8_1 = {} L8_1.x = 2555.736 L8_1.y = 208.002 L8_1.z = 289.801 L7_1.pos = L8_1 L8_1 = {} L8_1.x = 0.0 L8_1.y = 0.0 L8_1.z = 0.0 L7_1.rot = L8_1 L7_1.level = 1 L7_1.area_id = 4 L2_1[1] = L3_1 L2_1[2] = L4_1 L2_1[3] = L5_1 L2_1[4] = L6_1 L2_1[5] = L7_1 gadgets = L2_1 L2_1 = {} L3_1 = {} L3_1.config_id = 230001 L4_1 = RegionShape L4_1 = L4_1.SPHERE L3_1.shape = L4_1 L3_1.radius = 15 L4_1 = {} L4_1.x = 2566.5 L4_1.y = 210.716 L4_1.z = 311.2 L3_1.pos = L4_1 L3_1.area_id = 4 L2_1[1] = L3_1 regions = L2_1 L2_1 = {} L3_1 = {} L3_1.config_id = 1000302 L3_1.name = "SELECT_OPTION_302" L4_1 = EventType L4_1 = L4_1.EVENT_SELECT_OPTION L3_1.event = L4_1 L3_1.source = "" L3_1.condition = "condition_EVENT_SELECT_OPTION_302" L3_1.action = "action_EVENT_SELECT_OPTION_302" L3_1.trigger_count = 0 L4_1 = {} L4_1.config_id = 1000303 L4_1.name = "SEAL_BATTLE_END_303" L5_1 = EventType L5_1 = L5_1.EVENT_SEAL_BATTLE_END L4_1.event = L5_1 L4_1.source = "" L4_1.condition = "condition_EVENT_SEAL_BATTLE_END_303" L4_1.action = "action_EVENT_SEAL_BATTLE_END_303" L4_1.trigger_count = 0 L5_1 = {} L5_1.config_id = 1000315 L5_1.name = "QUEST_FINISH_315" L6_1 = EventType L6_1 = L6_1.EVENT_QUEST_FINISH L5_1.event = L6_1 L5_1.source = "39004" L5_1.condition = "" L5_1.action = "action_EVENT_QUEST_FINISH_315" L5_1.trigger_count = 0 L6_1 = {} L6_1.config_id = 1000318 L6_1.name = "GROUP_LOAD_318" L7_1 = EventType L7_1 = L7_1.EVENT_GROUP_LOAD L6_1.event = L7_1 L6_1.source = "" L6_1.condition = "" L6_1.action = "action_EVENT_GROUP_LOAD_318" L6_1.trigger_count = 0 L7_1 = {} L7_1.config_id = 1230001 L7_1.name = "ENTER_REGION_230001" L8_1 = EventType L8_1 = L8_1.EVENT_ENTER_REGION L7_1.event = L8_1 L7_1.source = "1" L7_1.condition = "condition_EVENT_ENTER_REGION_230001" L7_1.action = "action_EVENT_ENTER_REGION_230001" L8_1 = {} L8_1.config_id = 1230005 L8_1.name = "GADGET_CREATE_230005" L9_1 = EventType L9_1 = L9_1.EVENT_GADGET_CREATE L8_1.event = L9_1 L8_1.source = "" L8_1.condition = "condition_EVENT_GADGET_CREATE_230005" L8_1.action = "action_EVENT_GADGET_CREATE_230005" L8_1.trigger_count = 0 L9_1 = {} L9_1.config_id = 1230006 L9_1.name = "GADGET_STATE_CHANGE_230006" L10_1 = EventType L10_1 = L10_1.EVENT_GADGET_STATE_CHANGE L9_1.event = L10_1 L9_1.source = "" L9_1.condition = "" L9_1.action = "action_EVENT_GADGET_STATE_CHANGE_230006" L9_1.trigger_count = 0 L2_1[1] = L3_1 L2_1[2] = L4_1 L2_1[3] = L5_1 L2_1[4] = L6_1 L2_1[5] = L7_1 L2_1[6] = L8_1 L2_1[7] = L9_1 triggers = L2_1 L2_1 = {} L3_1 = {} L3_1.configId = 1 L3_1.name = "Quest_Flag" L3_1.value = 0 L3_1.no_refresh = true L4_1 = {} L4_1.configId = 2 L4_1.name = "first_touch_done" L4_1.value = 0 L4_1.no_refresh = true L5_1 = {} L5_1.configId = 3 L5_1.name = "seal_battle_done" L5_1.value = 0 L5_1.no_refresh = true L6_1 = {} L6_1.configId = 4 L6_1.name = "Point_Value" L6_1.value = 0 L6_1.no_refresh = true L7_1 = {} L7_1.configId = 5 L7_1.name = "Temp_Point_Value" L7_1.value = 0 L7_1.no_refresh = true L2_1[1] = L3_1 L2_1[2] = L4_1 L2_1[3] = L5_1 L2_1[4] = L6_1 L2_1[5] = L7_1 variables = L2_1 L2_1 = {} L2_1.suite = 1 L2_1.end_suite = 0 L2_1.rand_suite = false init_config = L2_1 L2_1 = {} L3_1 = {} L4_1 = {} L3_1.monsters = L4_1 L4_1 = {} L5_1 = 973 L4_1[1] = L5_1 L3_1.gadgets = L4_1 L4_1 = {} L3_1.regions = L4_1 L4_1 = {} L5_1 = "QUEST_FINISH_315" L6_1 = "GROUP_LOAD_318" L4_1[1] = L5_1 L4_1[2] = L6_1 L3_1.triggers = L4_1 L3_1.rand_weight = 100 L4_1 = {} L5_1 = {} L4_1.monsters = L5_1 L5_1 = {} L6_1 = 976 L5_1[1] = L6_1 L4_1.gadgets = L5_1 L5_1 = {} L6_1 = 230001 L5_1[1] = L6_1 L4_1.regions = L5_1 L5_1 = {} L6_1 = "SELECT_OPTION_302" L7_1 = "SEAL_BATTLE_END_303" L8_1 = "ENTER_REGION_230001" L9_1 = "GADGET_CREATE_230005" L10_1 = "GADGET_STATE_CHANGE_230006" L5_1[1] = L6_1 L5_1[2] = L7_1 L5_1[3] = L8_1 L5_1[4] = L9_1 L5_1[5] = L10_1 L4_1.triggers = L5_1 L4_1.rand_weight = 100 L5_1 = {} L6_1 = {} L7_1 = 422 L8_1 = 423 L9_1 = 424 L6_1[1] = L7_1 L6_1[2] = L8_1 L6_1[3] = L9_1 L5_1.monsters = L6_1 L6_1 = {} L5_1.gadgets = L6_1 L6_1 = {} L5_1.regions = L6_1 L6_1 = {} L5_1.triggers = L6_1 L5_1.rand_weight = 100 L2_1[1] = L3_1 L2_1[2] = L4_1 L2_1[3] = L5_1 suites = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2 L2_2 = A1_2.param1 L3_2 = L1_1.seal_model if L2_2 ~= L3_2 then L2_2 = false return L2_2 end L2_2 = A1_2.param2 if L2_2 ~= 24 then L2_2 = false return L2_2 end L2_2 = true return L2_2 end condition_EVENT_SELECT_OPTION_302 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2, L4_2, L5_2, L6_2 L2_2 = ScriptLib L2_2 = L2_2.SetGadgetStateByConfigId L3_2 = A0_2 L4_2 = L1_1.seal_model L5_2 = GadgetState L5_2 = L5_2.GearAction1 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.AddExtraGroupSuite L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = 3 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.StartSealBattle L3_2 = A0_2 L4_2 = L1_1.seal_model L5_2 = {} L6_2 = L1_1.battle_radius L5_2.radius = L6_2 L6_2 = L1_1.battle_time L5_2.kill_time = L6_2 L6_2 = L1_1.group_id L5_2.monster_group_id = L6_2 L6_2 = L1_1.battle_progress L5_2.max_progress = L6_2 L6_2 = SealBattleType L6_2 = L6_2.KILL_MONSTER L5_2.battle_type = L6_2 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.ShowReminder L3_2 = A0_2 L4_2 = 1109001 L2_2(L3_2, L4_2) L2_2 = ScriptLib L2_2 = L2_2.DelWorktopOption L3_2 = A0_2 L4_2 = A1_2.param2 L2_2(L3_2, L4_2) L2_2 = 0 return L2_2 end action_EVENT_SELECT_OPTION_302 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2 L2_2 = A1_2.param1 L3_2 = L1_1.seal_model if L2_2 ~= L3_2 then L2_2 = false return L2_2 end L2_2 = true return L2_2 end condition_EVENT_SEAL_BATTLE_END_303 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2, L4_2, L5_2, L6_2, L7_2 L2_2 = A1_2.param2 if L2_2 == 0 then L2_2 = ScriptLib L2_2 = L2_2.ShowReminder L3_2 = A0_2 L4_2 = 1109004 L2_2(L3_2, L4_2) L2_2 = ScriptLib L2_2 = L2_2.RemoveExtraGroupSuite L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = 3 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.SetGadgetStateByConfigId L3_2 = A0_2 L4_2 = L1_1.seal_model L5_2 = GadgetState L5_2 = L5_2.GearStart L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.AddExtraGroupSuite L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = 2 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.SetWorktopOptionsByGroupId L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = L1_1.seal_model L6_2 = {} L7_2 = 24 L6_2[1] = L7_2 L2_2(L3_2, L4_2, L5_2, L6_2) else L2_2 = A1_2.param2 if L2_2 == 1 then L2_2 = ScriptLib L2_2 = L2_2.SetGroupVariableValue L3_2 = A0_2 L4_2 = "seal_battle_done" L5_2 = 1 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.SetGadgetStateByConfigId L3_2 = A0_2 L4_2 = L1_1.seal_model L5_2 = GadgetState L5_2 = L5_2.Default L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.SetGadgetStateByConfigId L3_2 = A0_2 L4_2 = L1_1.seal_id L5_2 = GadgetState L5_2 = L5_2.Default L2_2(L3_2, L4_2, L5_2) end end L2_2 = 0 return L2_2 end action_EVENT_SEAL_BATTLE_END_303 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2, L4_2, L5_2 L2_2 = ScriptLib L2_2 = L2_2.AddExtraGroupSuite L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = 2 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.SetGroupVariableValue L3_2 = A0_2 L4_2 = "Quest_Flag" L5_2 = 1 L2_2(L3_2, L4_2, L5_2) L2_2 = 0 return L2_2 end action_EVENT_QUEST_FINISH_315 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2, L4_2, L5_2, L6_2, L7_2, L8_2 L2_2 = ScriptLib L2_2 = L2_2.GetGroupVariableValue L3_2 = A0_2 L4_2 = "Point_Value" L2_2 = L2_2(L3_2, L4_2) if L2_2 == 7 then L2_2 = ScriptLib L2_2 = L2_2.GetGadgetStateByConfigId L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = L1_1.seal_model L2_2 = L2_2(L3_2, L4_2, L5_2) L3_2 = GadgetState L3_2 = L3_2.Action03 if L2_2 ~= L3_2 then L2_2 = ScriptLib L2_2 = L2_2.SetGroupVariableValue L3_2 = A0_2 L4_2 = "Point_Value" L5_2 = 3 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.SetGroupVariableValue L3_2 = A0_2 L4_2 = "Temp_Point_Value" L5_2 = 3 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.SetGroupGadgetStateByConfigId L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = L1_1.seal_model L6_2 = GadgetState L6_2 = L6_2.Action02 L2_2(L3_2, L4_2, L5_2, L6_2) end end L2_2 = ScriptLib L2_2 = L2_2.GetGroupVariableValue L3_2 = A0_2 L4_2 = "Quest_Flag" L2_2 = L2_2(L3_2, L4_2) if L2_2 == 1 then L3_2 = ScriptLib L3_2 = L3_2.AddExtraGroupSuite L4_2 = A0_2 L5_2 = L1_1.group_id L6_2 = 2 L3_2(L4_2, L5_2, L6_2) L3_2 = ScriptLib L3_2 = L3_2.GetGroupVariableValue L4_2 = A0_2 L5_2 = "first_touch_done" L3_2 = L3_2(L4_2, L5_2) if L3_2 == 1 then L3_2 = ScriptLib L3_2 = L3_2.SetWorktopOptionsByGroupId L4_2 = A0_2 L5_2 = L1_1.group_id L6_2 = L1_1.seal_model L7_2 = {} L8_2 = 24 L7_2[1] = L8_2 L3_2(L4_2, L5_2, L6_2, L7_2) end end L3_2 = 0 return L3_2 end action_EVENT_GROUP_LOAD_318 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2, L4_2 L2_2 = A1_2.param1 if L2_2 ~= 230001 then L2_2 = false return L2_2 end L2_2 = ScriptLib L2_2 = L2_2.GetGroupVariableValue L3_2 = A0_2 L4_2 = "first_touch_done" L2_2 = L2_2(L3_2, L4_2) if 1 == L2_2 then L2_2 = false return L2_2 end L2_2 = true return L2_2 end condition_EVENT_ENTER_REGION_230001 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2, L4_2, L5_2, L6_2 L2_2 = ScriptLib L2_2 = L2_2.SetGroupVariableValue L3_2 = A0_2 L4_2 = "first_touch_done" L5_2 = 1 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.AddExtraGroupSuite L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = 3 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.StartSealBattle L3_2 = A0_2 L4_2 = L1_1.seal_model L5_2 = {} L6_2 = L1_1.battle_radius L5_2.radius = L6_2 L6_2 = L1_1.battle_time L5_2.kill_time = L6_2 L6_2 = L1_1.group_id L5_2.monster_group_id = L6_2 L6_2 = L1_1.battle_progress L5_2.max_progress = L6_2 L6_2 = SealBattleType L6_2 = L6_2.KILL_MONSTER L5_2.battle_type = L6_2 L2_2(L3_2, L4_2, L5_2) L2_2 = ScriptLib L2_2 = L2_2.SetGroupGadgetStateByConfigId L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = L1_1.seal_model L6_2 = GadgetState L6_2 = L6_2.GearStart L2_2(L3_2, L4_2, L5_2, L6_2) L2_2 = 0 return L2_2 end action_EVENT_ENTER_REGION_230001 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2 L2_2 = A1_2.param1 L3_2 = L1_1.seal_id if L2_2 ~= L3_2 then L2_2 = false return L2_2 end L2_2 = true return L2_2 end condition_EVENT_GADGET_CREATE_230005 = L2_1 function L2_1(A0_2, A1_2) local L2_2, L3_2, L4_2, L5_2, L6_2, L7_2 L2_2 = ScriptLib L2_2 = L2_2.GetGadgetStateByConfigId L3_2 = A0_2 L4_2 = L1_1.group_id L5_2 = L1_1.seal_model L2_2 = L2_2(L3_2, L4_2, L5_2) L3_2 = ScriptLib L3_2 = L3_2.GetGroupVariableValue L4_2 = A0_2 L5_2 = "seal_battle_done" L3_2 = L3_2(L4_2, L5_2) if 1 == L3_2 then L3_2 = ScriptLib L3_2 = L3_2.SetGroupGadgetStateByConfigId L4_2 = A0_2 L5_2 = L1_1.group_id L6_2 = L1_1.seal_id L7_2 = L2_2 L3_2(L4_2, L5_2, L6_2, L7_2) else L3_2 = ScriptLib L3_2 = L3_2.SetGroupGadgetStateByConfigId L4_2 = A0_2 L5_2 = L1_1.group_id L6_2 = L1_1.seal_id L7_2 = GadgetState L7_2 = L7_2.GearAction2 L3_2(L4_2, L5_2, L6_2, L7_2) end L3_2 = GadgetState L3_2 = L3_2.Default if L2_2 == L3_2 then L3_2 = ScriptLib L3_2 = L3_2.SetGroupVariableValue L4_2 = A0_2 L5_2 = "Point_Value" L6_2 = 0 L3_2(L4_2, L5_2, L6_2) L3_2 = ScriptLib L3_2 = L3_2.SetGroupVariableValue L4_2 = A0_2 L5_2 = "Temp_Point_Value" L6_2 = 0 L3_2(L4_2, L5_2, L6_2) end L3_2 = ScriptLib L3_2 = L3_2.GetGroupVariableValue L4_2 = A0_2 L5_2 = "Point_Value" L3_2 = L3_2(L4_2, L5_2) if L3_2 ~= 7 then L4_2 = ScriptLib L4_2 = L4_2.SetGroupVariableValue L5_2 = A0_2 L6_2 = "Temp_Point_Value" L7_2 = L3_2 L4_2(L5_2, L6_2, L7_2) L4_2 = L3_2 % 2 if L4_2 == 0 then L4_2 = ScriptLib L4_2 = L4_2.CreateGadget L5_2 = A0_2 L6_2 = {} L7_2 = L1_1.light_1 L6_2.config_id = L7_2 L4_2(L5_2, L6_2) end L4_2 = L3_2 % 4 if L4_2 < 2 then L4_2 = ScriptLib L4_2 = L4_2.CreateGadget L5_2 = A0_2 L6_2 = {} L7_2 = L1_1.light_2 L6_2.config_id = L7_2 L4_2(L5_2, L6_2) end if L3_2 < 4 then L4_2 = ScriptLib L4_2 = L4_2.CreateGadget L5_2 = A0_2 L6_2 = {} L7_2 = L1_1.light_3 L6_2.config_id = L7_2 L4_2(L5_2, L6_2) end end L4_2 = 0 return L4_2 end action_EVENT_GADGET_CREATE_230005 = L2_1 function action_EVENT_GADGET_STATE_CHANGE_230006(A0_2, A1_2) local L2_2, L3_2, L4_2, L5_2, L6_2, L7_2, L8_2 L2_2 = 0 if A1_2.param2 == L1_1.light_1 or A1_2.param2 == L1_1.light_2 or A1_2.param2 == L1_1.light_3 then if A1_2.param1 == GadgetState.GearStart then L3_2 = ScriptLib.GetGadgetStateByConfigId(A0_2, L1_1.group_id, L1_1.seal_id) ScriptLib.SetGroupGadgetStateByConfigId(A0_2, L1_1.group_id, L1_1.seal_id, GadgetState.ChestTrap) ScriptLib.SetGroupGadgetStateByConfigId(A0_2, L1_1.group_id, L1_1.seal_id, L3_2) if A1_2.param2 == L1_1.light_1 then L2_2 = 1 elseif A1_2.param2 == L1_1.light_2 then L2_2 = 2 elseif A1_2.param2 == L1_1.light_3 then L2_2 = 4 end ScriptLib.ChangeGroupVariableValue(A0_2, "Temp_Point_Value", L2_2) return 0 end elseif A1_2.param2 == L1_1.seal_id then if A1_2.param1 == GadgetState.ChestLocked or A1_2.param3 == GadgetState.ChestLocked then L3_2 = ScriptLib.GetGroupVariableValue(A0_2, "Point_Value") ScriptLib.SetGroupVariableValue(A0_2, "Temp_Point_Value", L3_2) if L3_2%2 == 0 then ScriptLib.CreateGadget(A0_2, {config_id = L1_1.light_1}) end if L3_2%4 < 2 then ScriptLib.CreateGadget(A0_2, {config_id = L1_1.light_2}) end if L3_2< 4 then ScriptLib.CreateGadget(A0_2, {config_id = L1_1.light_3}) end elseif 1 == ScriptLib.GetGroupVariableValue(A0_2, "seal_battle_done") then if A1_2.param1 == GadgetState.Action01 or A1_2.param1 == GadgetState.Action02 then if A1_2.param1 ~= GadgetState.ChestTrap and A1_2.param3 ~= GadgetState.ChestTrap then L2_2 = ScriptLib.GetGroupVariableValue(A0_2, "Temp_Point_Value") ScriptLib.SetGroupVariableValue(A0_2, "Point_Value", L2_2) ScriptLib.SetGroupGadgetStateByConfigId(A0_2, L1_1.group_id, L1_1.seal_model, A1_2.param1) end elseif A1_2.param1 == GadgetState.Action03 then ScriptLib.SetGroupGadgetStateByConfigId(A0_2, L1_1.group_id, L1_1.seal_model, A1_2.param1) L2_2 = ScriptLib.GetGroupVariableValue(A0_2, "Temp_Point_Value") ScriptLib.SetGroupVariableValue(A0_2, "Point_Value", L2_2) ScriptLib.AddQuestProgress(A0_2, "39007_success") ScriptLib.SetGroupVariableValue(A0_2, "Quest_Flag", 0) ScriptLib.KillEntityByConfigId(A0_2, { group_id = L1_1.group_id, config_id = L1_1.seal_id }) ScriptLib.RemoveExtraGroupSuite(A0_2, L1_1.group_id, 2) elseif A1_2.param3 == GadgetState.GearAction2 and A1_2.param1 == GadgetState.Default then ScriptLib.SetGroupGadgetStateByConfigId(A0_2, L1_1.group_id, L1_1.seal_model, A1_2.param1) end end return 0 else return -1 end end