mirror of
https://gitlab.com/YuukiPS/GSServer-CBT.git
synced 2024-12-25 15:29:22 +03:00
91 lines
2.1 KiB
Lua
91 lines
2.1 KiB
Lua
|
--================================================================
|
||
|
--
|
||
|
-- 配置
|
||
|
--
|
||
|
--================================================================
|
||
|
|
||
|
-- 怪物
|
||
|
monsters = {
|
||
|
}
|
||
|
|
||
|
-- NPC
|
||
|
npcs = {
|
||
|
}
|
||
|
|
||
|
-- 装置
|
||
|
gadgets = {
|
||
|
}
|
||
|
|
||
|
-- 区域
|
||
|
regions = {
|
||
|
{ config_id = 1, shape = RegionShape.SPHERE, radius = 3, pos = { x = 4.8, y = 0.0, z = 4.2 } },
|
||
|
{ config_id = 2, shape = RegionShape.SPHERE, radius = 2, pos = { x = 2.1, y = 5.5, z = -2.7 } }
|
||
|
}
|
||
|
|
||
|
-- 触发器
|
||
|
triggers = {
|
||
|
{ name = "ENTER_REGION_1", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_1", action = "", trigger_count = 0 },
|
||
|
{ name = "ENTER_REGION_2", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_2", action = "", trigger_count = 0 }
|
||
|
}
|
||
|
|
||
|
-- 变量
|
||
|
variables = {
|
||
|
}
|
||
|
|
||
|
--================================================================
|
||
|
--
|
||
|
-- 初始化配置
|
||
|
--
|
||
|
--================================================================
|
||
|
|
||
|
-- 初始化时创建
|
||
|
init_config = {
|
||
|
suite = 1,
|
||
|
rand_suite = true,
|
||
|
npcs = { }
|
||
|
}
|
||
|
|
||
|
--================================================================
|
||
|
--
|
||
|
-- 小组配置
|
||
|
--
|
||
|
--================================================================
|
||
|
|
||
|
suites = {
|
||
|
{
|
||
|
-- suite_id = 0,
|
||
|
-- description = ,
|
||
|
monsters = { },
|
||
|
gadgets = { },
|
||
|
regions = { 1, 2 },
|
||
|
triggers = { "ENTER_REGION_1", "ENTER_REGION_2" },
|
||
|
rand_weight = 100
|
||
|
}
|
||
|
}
|
||
|
|
||
|
--================================================================
|
||
|
--
|
||
|
-- 触发器
|
||
|
--
|
||
|
--================================================================
|
||
|
|
||
|
-- 触发条件
|
||
|
function condition_EVENT_ENTER_REGION_1(context, evt)
|
||
|
if ScriptLib.GetEntityType(evt.target_eid) == EntityType.AVATAR and ScriptLib.GetQuestState(context, evt.target_eid, 37604) == QuestState.UNFINISHED and evt.param1 == 1 then
|
||
|
return true
|
||
|
end
|
||
|
return false
|
||
|
end
|
||
|
|
||
|
-- 触发操作
|
||
|
|
||
|
-- 触发条件
|
||
|
function condition_EVENT_ENTER_REGION_2(context, evt)
|
||
|
if ScriptLib.GetEntityType(evt.target_eid) == EntityType.AVATAR and ScriptLib.GetQuestState(context, evt.target_eid, 37606) == QuestState.UNFINISHED and evt.param1 == 2 then
|
||
|
return true
|
||
|
end
|
||
|
return false
|
||
|
end
|
||
|
|
||
|
-- 触发操作
|