651 lines
26 KiB
Go
651 lines
26 KiB
Go
-- 基础信息
|
||
local base_info = {
|
||
group_id = 133006001
|
||
}
|
||
|
||
--================================================================
|
||
--
|
||
-- 配置
|
||
--
|
||
--================================================================
|
||
|
||
-- 怪物
|
||
monsters = {
|
||
}
|
||
|
||
-- NPC
|
||
npcs = {
|
||
}
|
||
|
||
-- 装置
|
||
gadgets = {
|
||
{ config_id = 1003, gadget_id = 70710130, pos = { x = 2611.586, y = 221.690, z = -2366.325 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 30, isOneoff = true, persistent = true, area_id = 1 },
|
||
{ config_id = 1004, gadget_id = 70710130, pos = { x = 2692.315, y = 196.682, z = -2305.836 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 30, isOneoff = true, persistent = true, area_id = 1 },
|
||
{ config_id = 1005, gadget_id = 70710130, pos = { x = 2547.141, y = 195.611, z = -2297.081 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 30, isOneoff = true, persistent = true, area_id = 1 },
|
||
{ config_id = 1006, gadget_id = 70710130, pos = { x = 2621.854, y = 200.825, z = -2401.854 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 30, isOneoff = true, persistent = true, area_id = 1 },
|
||
{ config_id = 1007, gadget_id = 70710133, pos = { x = 2626.975, y = 204.318, z = -2373.391 }, rot = { x = 354.925, y = 6.734, z = 348.947 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1013, gadget_id = 70710090, pos = { x = 2631.640, y = 202.030, z = -2344.847 }, rot = { x = 321.941, y = 5.704, z = 358.629 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1014, gadget_id = 70710090, pos = { x = 2624.711, y = 202.835, z = -2388.769 }, rot = { x = 0.000, y = 197.590, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1016, gadget_id = 70710133, pos = { x = 2626.769, y = 204.342, z = -2373.366 }, rot = { x = 354.926, y = 6.630, z = 348.429 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1018, gadget_id = 70710133, pos = { x = 2627.510, y = 204.349, z = -2373.496 }, rot = { x = 349.314, y = 24.763, z = 15.202 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1019, gadget_id = 70710133, pos = { x = 2627.299, y = 204.306, z = -2373.471 }, rot = { x = 358.657, y = 8.547, z = 10.898 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1022, gadget_id = 70710090, pos = { x = 2627.708, y = 202.972, z = -2371.836 }, rot = { x = 0.000, y = 4.674, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1023, gadget_id = 70710090, pos = { x = 2630.334, y = 200.234, z = -2353.718 }, rot = { x = 0.000, y = 7.008, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1024, gadget_id = 70710090, pos = { x = 2632.349, y = 204.114, z = -2338.662 }, rot = { x = 0.000, y = 3.481, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1025, gadget_id = 70710090, pos = { x = 2616.251, y = 198.222, z = -2311.496 }, rot = { x = 0.000, y = 271.529, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1026, gadget_id = 70710090, pos = { x = 2599.591, y = 197.934, z = -2310.138 }, rot = { x = 3.257, y = 263.238, z = 357.772 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1027, gadget_id = 70710090, pos = { x = 2658.521, y = 198.869, z = -2314.188 }, rot = { x = 0.000, y = 81.326, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1028, gadget_id = 70710090, pos = { x = 2579.276, y = 195.445, z = -2310.931 }, rot = { x = 0.000, y = 298.823, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1029, gadget_id = 70710090, pos = { x = 2675.363, y = 196.483, z = -2319.920 }, rot = { x = 0.000, y = 48.684, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1030, gadget_id = 70710090, pos = { x = 2624.915, y = 203.220, z = -2379.475 }, rot = { x = 0.000, y = 177.802, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1031, gadget_id = 70710090, pos = { x = 2615.557, y = 200.305, z = -2399.429 }, rot = { x = 0.000, y = 109.491, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1032, gadget_id = 70360001, pos = { x = 2622.365, y = 183.170, z = -2375.960 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 30, area_id = 1 },
|
||
{ config_id = 1034, gadget_id = 70710090, pos = { x = 2612.071, y = 204.189, z = -2363.979 }, rot = { x = 276.357, y = 186.749, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1035, gadget_id = 70710090, pos = { x = 2609.698, y = 210.357, z = -2366.176 }, rot = { x = 273.363, y = 13.698, z = 81.952 }, level = 30, isOneoff = true, area_id = 1 },
|
||
{ config_id = 1037, gadget_id = 70710090, pos = { x = 2638.041, y = 200.692, z = -2313.101 }, rot = { x = 0.000, y = 81.326, z = 0.000 }, level = 30, isOneoff = true, area_id = 1 }
|
||
}
|
||
|
||
-- 区域
|
||
regions = {
|
||
}
|
||
|
||
-- 触发器
|
||
triggers = {
|
||
{ config_id = 1001001, name = "ANY_GADGET_DIE_1001", event = EventType.EVENT_ANY_GADGET_DIE, source = "", condition = "condition_EVENT_ANY_GADGET_DIE_1001", action = "action_EVENT_ANY_GADGET_DIE_1001" },
|
||
{ config_id = 1001002, name = "VARIABLE_CHANGE_1002", event = EventType.EVENT_VARIABLE_CHANGE, source = "count", condition = "condition_EVENT_VARIABLE_CHANGE_1002", action = "action_EVENT_VARIABLE_CHANGE_1002" },
|
||
{ config_id = 1001008, name = "ANY_GADGET_DIE_1008", event = EventType.EVENT_ANY_GADGET_DIE, source = "", condition = "condition_EVENT_ANY_GADGET_DIE_1008", action = "action_EVENT_ANY_GADGET_DIE_1008" },
|
||
{ config_id = 1001009, name = "ANY_GADGET_DIE_1009", event = EventType.EVENT_ANY_GADGET_DIE, source = "", condition = "condition_EVENT_ANY_GADGET_DIE_1009", action = "action_EVENT_ANY_GADGET_DIE_1009" },
|
||
{ config_id = 1001010, name = "ANY_GADGET_DIE_1010", event = EventType.EVENT_ANY_GADGET_DIE, source = "", condition = "condition_EVENT_ANY_GADGET_DIE_1010", action = "action_EVENT_ANY_GADGET_DIE_1010" },
|
||
{ config_id = 1001011, name = "VARIABLE_CHANGE_1011", event = EventType.EVENT_VARIABLE_CHANGE, source = "big", condition = "condition_EVENT_VARIABLE_CHANGE_1011", action = "action_EVENT_VARIABLE_CHANGE_1011" },
|
||
{ config_id = 1001012, name = "TIMER_EVENT_1012", event = EventType.EVENT_TIMER_EVENT, source = "BLACKWIND", condition = "", action = "action_EVENT_TIMER_EVENT_1012" },
|
||
{ config_id = 1001015, name = "VARIABLE_CHANGE_1015", event = EventType.EVENT_VARIABLE_CHANGE, source = "reminder", condition = "condition_EVENT_VARIABLE_CHANGE_1015", action = "action_EVENT_VARIABLE_CHANGE_1015" },
|
||
{ config_id = 1001017, name = "VARIABLE_CHANGE_1017", event = EventType.EVENT_VARIABLE_CHANGE, source = "dead", condition = "condition_EVENT_VARIABLE_CHANGE_1017", action = "action_EVENT_VARIABLE_CHANGE_1017" },
|
||
{ config_id = 1001020, name = "GADGET_CREATE_1020", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_1020", action = "action_EVENT_GADGET_CREATE_1020" },
|
||
{ config_id = 1001021, name = "QUEST_FINISH_1021", event = EventType.EVENT_QUEST_FINISH, source = "7101215", condition = "condition_EVENT_QUEST_FINISH_1021", action = "action_EVENT_QUEST_FINISH_1021" },
|
||
{ config_id = 1001033, name = "GADGET_CREATE_1033", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_1033", action = "action_EVENT_GADGET_CREATE_1033" },
|
||
{ config_id = 1001036, name = "GADGET_CREATE_1036", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_1036", action = "action_EVENT_GADGET_CREATE_1036" }
|
||
}
|
||
|
||
-- 变量
|
||
variables = {
|
||
{ config_id = 1, name = "count", value = 0, no_refresh = true },
|
||
{ config_id = 2, name = "dead", value = 0, no_refresh = true },
|
||
{ config_id = 3, name = "reminder", value = 0, no_refresh = true },
|
||
{ config_id = 4, name = "big", value = 0, no_refresh = true }
|
||
}
|
||
|
||
--================================================================
|
||
--
|
||
-- 初始化配置
|
||
--
|
||
--================================================================
|
||
|
||
-- 初始化时创建
|
||
init_config = {
|
||
suite = 3,
|
||
end_suite = 0,
|
||
rand_suite = false
|
||
}
|
||
|
||
--================================================================
|
||
--
|
||
-- 小组配置
|
||
--
|
||
--================================================================
|
||
|
||
suites = {
|
||
{
|
||
-- suite_id = 1,
|
||
-- description = ,
|
||
monsters = { },
|
||
gadgets = { 1032 },
|
||
regions = { },
|
||
triggers = { "ANY_GADGET_DIE_1001", "VARIABLE_CHANGE_1002", "ANY_GADGET_DIE_1008", "ANY_GADGET_DIE_1009", "ANY_GADGET_DIE_1010", "VARIABLE_CHANGE_1011", "TIMER_EVENT_1012", "VARIABLE_CHANGE_1015", "VARIABLE_CHANGE_1017", "GADGET_CREATE_1020", "QUEST_FINISH_1021", "GADGET_CREATE_1033", "GADGET_CREATE_1036" },
|
||
rand_weight = 100
|
||
},
|
||
{
|
||
-- suite_id = 2,
|
||
-- description = ,
|
||
monsters = { },
|
||
gadgets = { 1003, 1004, 1005, 1006, 1007, 1013, 1014, 1016, 1018, 1019, 1022, 1023, 1024, 1025, 1026, 1027, 1028, 1029, 1030, 1031, 1034, 1035, 1037 },
|
||
regions = { },
|
||
triggers = { "ANY_GADGET_DIE_1001", "VARIABLE_CHANGE_1002", "ANY_GADGET_DIE_1008", "ANY_GADGET_DIE_1009", "ANY_GADGET_DIE_1010", "VARIABLE_CHANGE_1011", "TIMER_EVENT_1012", "VARIABLE_CHANGE_1015", "VARIABLE_CHANGE_1017", "GADGET_CREATE_1020", "QUEST_FINISH_1021" },
|
||
rand_weight = 100
|
||
},
|
||
{
|
||
-- suite_id = 3,
|
||
-- description = ,
|
||
monsters = { },
|
||
gadgets = { },
|
||
regions = { },
|
||
triggers = { "ANY_GADGET_DIE_1001", "VARIABLE_CHANGE_1002", "ANY_GADGET_DIE_1008", "ANY_GADGET_DIE_1009", "ANY_GADGET_DIE_1010", "VARIABLE_CHANGE_1011", "TIMER_EVENT_1012", "VARIABLE_CHANGE_1015", "VARIABLE_CHANGE_1017", "GADGET_CREATE_1020", "QUEST_FINISH_1021" },
|
||
rand_weight = 100
|
||
}
|
||
}
|
||
|
||
--================================================================
|
||
--
|
||
-- 触发器
|
||
--
|
||
--================================================================
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_ANY_GADGET_DIE_1001(context, evt)
|
||
if 1003 ~= evt.param1 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_ANY_GADGET_DIE_1001(context, evt)
|
||
-- 通知任务系统完成条件类型"LUA通知",复杂参数为quest_param的进度+1
|
||
if 0 ~= ScriptLib.AddQuestProgress(context, "7101203_end") then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : add_quest_progress")
|
||
return -1
|
||
end
|
||
|
||
-- 针对当前group内变量名为 "count" 的变量,进行修改,变化值为 1
|
||
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "count", 1) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
|
||
return -1
|
||
end
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1007 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1034 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1035 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1024 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1023 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1022 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 将本组内变量名为 "reminder" 的变量设置为 1
|
||
if 0 ~= ScriptLib.SetGroupVariableValue(context, "reminder", 1) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_groupVariable")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_VARIABLE_CHANGE_1002(context, evt)
|
||
if evt.param1 == evt.param2 then return false end
|
||
|
||
-- 判断变量"count"为4
|
||
if ScriptLib.GetGroupVariableValue(context, "count") ~= 4 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_VARIABLE_CHANGE_1002(context, evt)
|
||
-- 通知任务系统完成条件类型"LUA通知",复杂参数为quest_param的进度+1
|
||
if 0 ~= ScriptLib.AddQuestProgress(context, "7101202_end") then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : add_quest_progress")
|
||
return -1
|
||
end
|
||
|
||
-- 将本组内变量名为 "count1" 的变量设置为 4
|
||
if 0 ~= ScriptLib.SetGroupVariableValueByGroup(context, "count1", 4, 133006003) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_groupVariable_by_group")
|
||
return -1
|
||
end
|
||
|
||
-- 延迟3秒后,向groupId为:133006001的对象,请求一次调用,并将string参数:"BLACKWIND" 传递过去
|
||
if 0 ~= ScriptLib.CreateGroupTimerEvent(context, 133006001, "BLACKWIND", 3) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : create_timerevent_by_group")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_ANY_GADGET_DIE_1008(context, evt)
|
||
if 1004 ~= evt.param1 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_ANY_GADGET_DIE_1008(context, evt)
|
||
-- 通知任务系统完成条件类型"LUA通知",复杂参数为quest_param的进度+1
|
||
if 0 ~= ScriptLib.AddQuestProgress(context, "7101204_end") then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : add_quest_progress")
|
||
return -1
|
||
end
|
||
|
||
-- 针对当前group内变量名为 "count" 的变量,进行修改,变化值为 1
|
||
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "count", 1) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
|
||
return -1
|
||
end
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1016 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1037 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1027 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1029 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1013 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1025 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 将本组内变量名为 "reminder" 的变量设置为 1
|
||
if 0 ~= ScriptLib.SetGroupVariableValue(context, "reminder", 1) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_groupVariable")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_ANY_GADGET_DIE_1009(context, evt)
|
||
if 1005 ~= evt.param1 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_ANY_GADGET_DIE_1009(context, evt)
|
||
-- 通知任务系统完成条件类型"LUA通知",复杂参数为quest_param的进度+1
|
||
if 0 ~= ScriptLib.AddQuestProgress(context, "7101205_end") then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : add_quest_progress")
|
||
return -1
|
||
end
|
||
|
||
-- 针对当前group内变量名为 "count" 的变量,进行修改,变化值为 1
|
||
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "count", 1) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
|
||
return -1
|
||
end
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1018 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1026 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1028 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1024 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1023 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 将本组内变量名为 "reminder" 的变量设置为 1
|
||
if 0 ~= ScriptLib.SetGroupVariableValue(context, "reminder", 1) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_groupVariable")
|
||
return -1
|
||
end
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1025 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_ANY_GADGET_DIE_1010(context, evt)
|
||
if 1006 ~= evt.param1 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_ANY_GADGET_DIE_1010(context, evt)
|
||
-- 通知任务系统完成条件类型"LUA通知",复杂参数为quest_param的进度+1
|
||
if 0 ~= ScriptLib.AddQuestProgress(context, "7101206_end") then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : add_quest_progress")
|
||
return -1
|
||
end
|
||
|
||
-- 针对当前group内变量名为 "count" 的变量,进行修改,变化值为 1
|
||
if 0 ~= ScriptLib.ChangeGroupVariableValue(context, "count", 1) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : change_GroupVariable")
|
||
return -1
|
||
end
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1019 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1030 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1014 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1031 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 1022 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||
return -1
|
||
end
|
||
|
||
|
||
-- 将本组内变量名为 "reminder" 的变量设置为 1
|
||
if 0 ~= ScriptLib.SetGroupVariableValue(context, "reminder", 1) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_groupVariable")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_VARIABLE_CHANGE_1011(context, evt)
|
||
if evt.param1 == evt.param2 then return false end
|
||
|
||
-- 判断变量"big"为1
|
||
if ScriptLib.GetGroupVariableValue(context, "big") ~= 1 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_VARIABLE_CHANGE_1011(context, evt)
|
||
-- 将本组内变量名为 "windcore1" 的变量设置为 1
|
||
if 0 ~= ScriptLib.SetGroupVariableValueByGroup(context, "windcore1", 1, 133006003) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_groupVariable_by_group")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_TIMER_EVENT_1012(context, evt)
|
||
-- 调用提示id为 31020854 的提示UI,会显示在屏幕中央偏下位置,id索引自 ReminderData表格
|
||
if 0 ~= ScriptLib.ShowReminder(context, 31020854) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : active_reminder_ui")
|
||
return -1
|
||
end
|
||
|
||
-- 触发镜头注目,注目位置为坐标(2630,214,-2356),持续时间为3秒,并且为强制注目形式,不广播其他玩家
|
||
local pos = {x=2630, y=214, z=-2356}
|
||
local pos_follow = {x=0, y=0, z=0}
|
||
if 0 ~= ScriptLib.BeginCameraSceneLook(context, { look_pos = pos, is_allow_input = false, duration = 3, is_force = true, is_broadcast = false, is_recover_keep_current = true, delay = 1,
|
||
is_set_follow_pos = false, follow_pos = pos_follow, is_force_walk = false, is_change_play_mode = false,
|
||
is_set_screen_XY = false, screen_x = 0, screen_y = 0 }) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : active_cameraLook_Begin")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_VARIABLE_CHANGE_1015(context, evt)
|
||
if evt.param1 == evt.param2 then return false end
|
||
|
||
-- 判断变量"reminder"为1
|
||
if ScriptLib.GetGroupVariableValue(context, "reminder") ~= 1 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_VARIABLE_CHANGE_1015(context, evt)
|
||
-- 调用提示id为 31020860 的提示UI,会显示在屏幕中央偏下位置,id索引自 ReminderData表格
|
||
if 0 ~= ScriptLib.ShowReminder(context, 31020860) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : active_reminder_ui")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_VARIABLE_CHANGE_1017(context, evt)
|
||
if evt.param1 == evt.param2 then return false end
|
||
|
||
-- 判断变量"dead"为1
|
||
if ScriptLib.GetGroupVariableValue(context, "dead") ~= 1 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_VARIABLE_CHANGE_1017(context, evt)
|
||
-- 卸载指定gadget
|
||
if 0 ~= ScriptLib.RemoveEntityByConfigId(context, 133006001, EntityType.GADGET, 1020 ) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : remove_gadget_by_configid")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_GADGET_CREATE_1020(context, evt)
|
||
if 1032 ~= evt.param1 then
|
||
return false
|
||
end
|
||
|
||
-- 判断变量"count"为1
|
||
if ScriptLib.GetGroupVariableValue(context, "count") ~= 1 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_GADGET_CREATE_1020(context, evt)
|
||
-- 在指定位置对应半径范围播放reminder
|
||
local pos = {x=2630,y=200,z=-2356}
|
||
if 0 ~= ScriptLib.ShowReminderRadius(context, 31020861, pos, 100) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : active_reminder_ui_bypos")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_QUEST_FINISH_1021(context, evt)
|
||
--检查ID为7101215的任务的完成状态是否为1(1=完成,0=失败)
|
||
--此事件需要配合Quest表使用,在Quest表里的完成执行中配置“通知group脚本”,则该任务完成后服务端会向对应的group发送通知,参数1填写场景ID,参数2填写group ID(如果不填则会通知所有group)
|
||
|
||
--检查任务ID
|
||
if 7101215 ~= evt.param1 then
|
||
return false
|
||
end
|
||
|
||
--检查任务成功状态
|
||
if 1 ~= evt.param2 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_QUEST_FINISH_1021(context, evt)
|
||
-- 调用提示id为 31020855 的提示UI,会显示在屏幕中央偏下位置,id索引自 ReminderData表格
|
||
if 0 ~= ScriptLib.ShowReminder(context, 31020855) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : active_reminder_ui")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_GADGET_CREATE_1033(context, evt)
|
||
if 1032 ~= evt.param1 then
|
||
return false
|
||
end
|
||
|
||
-- 判断变量"count"为2
|
||
if ScriptLib.GetGroupVariableValue(context, "count") ~= 2 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_GADGET_CREATE_1033(context, evt)
|
||
-- 在指定位置对应半径范围播放reminder
|
||
local pos = {x=2630,y=200,z=-2356}
|
||
if 0 ~= ScriptLib.ShowReminderRadius(context, 31020861, pos, 100) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : active_reminder_ui_bypos")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end
|
||
|
||
-- 触发条件
|
||
function condition_EVENT_GADGET_CREATE_1036(context, evt)
|
||
if 1032 ~= evt.param1 then
|
||
return false
|
||
end
|
||
|
||
-- 判断变量"count"为3
|
||
if ScriptLib.GetGroupVariableValue(context, "count") ~= 3 then
|
||
return false
|
||
end
|
||
|
||
return true
|
||
end
|
||
|
||
-- 触发操作
|
||
function action_EVENT_GADGET_CREATE_1036(context, evt)
|
||
-- 在指定位置对应半径范围播放reminder
|
||
local pos = {x=2630,y=200,z=-2356}
|
||
if 0 ~= ScriptLib.ShowReminderRadius(context, 31020861, pos, 100) then
|
||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : active_reminder_ui_bypos")
|
||
return -1
|
||
end
|
||
|
||
return 0
|
||
end |