Files
hk4e-go/gdconf/game_data_config/lua/scene/50010/scene50010_group250010006.lua
T
2022-11-30 00:00:20 +08:00

271 lines
9.1 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
-- 基础信息
local base_info = {
group_id = 250010006
}
--================================================================
--
-- 配置
--
--================================================================
-- 怪物
monsters = {
{ config_id = 6001, monster_id = 20011001, pos = { x = 377.032, y = 4.000, z = -35.164 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1, disableWander = true },
{ config_id = 6002, monster_id = 20011001, pos = { x = 377.028, y = 4.000, z = -41.140 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1, disableWander = true }
}
-- NPC
npcs = {
}
-- 装置
gadgets = {
{ config_id = 6003, gadget_id = 70900033, pos = { x = 374.000, y = 3.200, z = -35.000 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
{ config_id = 6004, gadget_id = 70900033, pos = { x = 380.000, y = 3.200, z = -35.000 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
{ config_id = 6005, gadget_id = 70900033, pos = { x = 380.000, y = 3.200, z = -41.000 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
{ config_id = 6006, gadget_id = 70900033, pos = { x = 374.000, y = 3.200, z = -41.000 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
{ config_id = 6007, gadget_id = 70211032, pos = { x = 377.000, y = 4.000, z = -38.000 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1, drop_tag = "战斗超级蒙德", state = GadgetState.ChestLocked, isOneoff = true, persistent = true }
}
-- 区域
regions = {
}
-- 触发器
triggers = {
{ config_id = 1000027, name = "GADGET_STATE_CHANGE_27", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_27", action = "action_EVENT_GADGET_STATE_CHANGE_27" },
{ config_id = 1000028, name = "GADGET_STATE_CHANGE_28", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_28", action = "action_EVENT_GADGET_STATE_CHANGE_28" },
{ config_id = 1000029, name = "GADGET_STATE_CHANGE_29", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_29", action = "action_EVENT_GADGET_STATE_CHANGE_29" },
{ config_id = 1000030, name = "GADGET_STATE_CHANGE_30", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_30", action = "action_EVENT_GADGET_STATE_CHANGE_30" },
{ config_id = 1000031, name = "GADGET_STATE_CHANGE_31", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_31", action = "action_EVENT_GADGET_STATE_CHANGE_31" },
{ config_id = 1000032, name = "GADGET_STATE_CHANGE_32", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_32", action = "action_EVENT_GADGET_STATE_CHANGE_32" },
{ config_id = 1000033, name = "GADGET_STATE_CHANGE_33", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_33", action = "action_EVENT_GADGET_STATE_CHANGE_33" },
{ config_id = 1000034, name = "GADGET_STATE_CHANGE_34", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_34", action = "action_EVENT_GADGET_STATE_CHANGE_34" },
{ config_id = 1000035, name = "VARIABLE_CHANGE_35", event = EventType.EVENT_VARIABLE_CHANGE, source = "", condition = "condition_EVENT_VARIABLE_CHANGE_35", action = "action_EVENT_VARIABLE_CHANGE_35" }
}
-- 变量
variables = {
{ config_id = 1, name = "num", value = 0, no_refresh = false }
}
--================================================================
--
-- 初始化配置
--
--================================================================
-- 初始化时创建
init_config = {
suite = 1,
end_suite = 0,
rand_suite = false
}
--================================================================
--
-- 小组配置
--
--================================================================
suites = {
{
-- suite_id = 1,
-- description = ,
monsters = { 6001, 6002 },
gadgets = { 6003, 6004, 6005, 6006, 6007 },
regions = { },
triggers = { "GADGET_STATE_CHANGE_27", "GADGET_STATE_CHANGE_28", "GADGET_STATE_CHANGE_29", "GADGET_STATE_CHANGE_30", "GADGET_STATE_CHANGE_31", "GADGET_STATE_CHANGE_32", "GADGET_STATE_CHANGE_33", "GADGET_STATE_CHANGE_34", "VARIABLE_CHANGE_35" },
rand_weight = 100
}
}
--================================================================
--
-- 触发器
--
--================================================================
-- 触发条件
function condition_EVENT_GADGET_STATE_CHANGE_27(context, evt)
if 6006 ~= evt.param2 or GadgetState.GearStart ~= evt.param1 then
return false
end
return true
end
-- 触发操作
function action_EVENT_GADGET_STATE_CHANGE_27(context, evt)
-- 针对当前group内变量名为 "num" 的变量,进行修改,变化值为 1
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "num", 1) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
return -1
end
return 0
end
-- 触发条件
function condition_EVENT_GADGET_STATE_CHANGE_28(context, evt)
if 6005 ~= evt.param2 or GadgetState.GearStart ~= evt.param1 then
return false
end
return true
end
-- 触发操作
function action_EVENT_GADGET_STATE_CHANGE_28(context, evt)
-- 针对当前group内变量名为 "num" 的变量,进行修改,变化值为 1
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "num", 1) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
return -1
end
return 0
end
-- 触发条件
function condition_EVENT_GADGET_STATE_CHANGE_29(context, evt)
if 6004 ~= evt.param2 or GadgetState.GearStart ~= evt.param1 then
return false
end
return true
end
-- 触发操作
function action_EVENT_GADGET_STATE_CHANGE_29(context, evt)
-- 针对当前group内变量名为 "num" 的变量,进行修改,变化值为 1
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "num", 1) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
return -1
end
return 0
end
-- 触发条件
function condition_EVENT_GADGET_STATE_CHANGE_30(context, evt)
if 6003 ~= evt.param2 or GadgetState.GearStart ~= evt.param1 then
return false
end
return true
end
-- 触发操作
function action_EVENT_GADGET_STATE_CHANGE_30(context, evt)
-- 针对当前group内变量名为 "num" 的变量,进行修改,变化值为 1
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "num", 1) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
return -1
end
return 0
end
-- 触发条件
function condition_EVENT_GADGET_STATE_CHANGE_31(context, evt)
if 6003 ~= evt.param2 or GadgetState.Default ~= evt.param1 then
return false
end
return true
end
-- 触发操作
function action_EVENT_GADGET_STATE_CHANGE_31(context, evt)
-- 针对当前group内变量名为 "num" 的变量,进行修改,变化值为 -1
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "num", -1) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
return -1
end
return 0
end
-- 触发条件
function condition_EVENT_GADGET_STATE_CHANGE_32(context, evt)
if 6004 ~= evt.param2 or GadgetState.Default ~= evt.param1 then
return false
end
return true
end
-- 触发操作
function action_EVENT_GADGET_STATE_CHANGE_32(context, evt)
-- 针对当前group内变量名为 "num" 的变量,进行修改,变化值为 -1
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "num", -1) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
return -1
end
return 0
end
-- 触发条件
function condition_EVENT_GADGET_STATE_CHANGE_33(context, evt)
if 6005 ~= evt.param2 or GadgetState.Default ~= evt.param1 then
return false
end
return true
end
-- 触发操作
function action_EVENT_GADGET_STATE_CHANGE_33(context, evt)
-- 针对当前group内变量名为 "num" 的变量,进行修改,变化值为 -1
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "num", -1) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
return -1
end
return 0
end
-- 触发条件
function condition_EVENT_GADGET_STATE_CHANGE_34(context, evt)
if 6006 ~= evt.param2 or GadgetState.Default ~= evt.param1 then
return false
end
return true
end
-- 触发操作
function action_EVENT_GADGET_STATE_CHANGE_34(context, evt)
-- 针对当前group内变量名为 "num" 的变量,进行修改,变化值为 -1
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "num", -1) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
return -1
end
return 0
end
-- 触发条件
function condition_EVENT_VARIABLE_CHANGE_35(context, evt)
if evt.param1 == evt.param2 then return false end
-- 判断变量"num"为4
if ScriptLib.GetGroupVariableValue(context, "num") ~= 4 then
return false
end
return true
end
-- 触发操作
function action_EVENT_VARIABLE_CHANGE_35(context, evt)
-- 解锁目标6007
if 0 ~= ScriptLib.ChangeGroupGadget(context, { config_id = 6007, state = GadgetState.Default }) then
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : unlock_gadget")
return -1
end
return 0
end