mirror of
https://gitlab.com/YuukiPS/GSServer-CBT.git
synced 2025-01-13 00:29:29 +03:00
215 lines
5.5 KiB
Lua
215 lines
5.5 KiB
Lua
|
--================================================================
|
|||
|
--
|
|||
|
-- 配置
|
|||
|
--
|
|||
|
--================================================================
|
|||
|
|
|||
|
-- 怪物
|
|||
|
monsters = {
|
|||
|
{ config_id = 54, monster_id = 23040101, pos = { x = 16.9, y = -0.5, z = -161.1 }, rot = { x = 0.0, y = 0.0, z = 0.0 }, level = 0 },
|
|||
|
{ config_id = 55, monster_id = 23040101, pos = { x = 66.7, y = -1.1, z = -219.4 }, rot = { x = 0.0, y = 0.0, z = 0.0 }, level = 0 },
|
|||
|
{ config_id = 56, monster_id = 23040101, pos = { x = -21.7, y = -0.5, z = -263.1 }, rot = { x = 0.0, y = 0.0, z = 0.0 }, level = 0 }
|
|||
|
}
|
|||
|
|
|||
|
-- NPC
|
|||
|
npcs = {
|
|||
|
}
|
|||
|
|
|||
|
-- 装置
|
|||
|
gadgets = {
|
|||
|
}
|
|||
|
|
|||
|
-- 区域
|
|||
|
regions = {
|
|||
|
{ config_id = 26, shape = RegionShape.SPHERE, radius = 5, pos = { x = 21.1, y = -0.5, z = -152.1 } }
|
|||
|
}
|
|||
|
|
|||
|
-- 触发器
|
|||
|
triggers = {
|
|||
|
{ name = "ANY_MONSTER_DIE_26", event = EventType.EVENT_ANY_MONSTER_DIE, source = "", condition = "condition_EVENT_ANY_MONSTER_DIE_26", action = "action_EVENT_ANY_MONSTER_DIE_26" }
|
|||
|
}
|
|||
|
|
|||
|
-- 变量
|
|||
|
variables = {
|
|||
|
}
|
|||
|
|
|||
|
--================================================================
|
|||
|
--
|
|||
|
-- 初始化配置
|
|||
|
--
|
|||
|
--================================================================
|
|||
|
|
|||
|
-- 初始化时创建
|
|||
|
init_config = {
|
|||
|
suite = 4,
|
|||
|
rand_suite = false,
|
|||
|
npcs = { }
|
|||
|
}
|
|||
|
|
|||
|
--================================================================
|
|||
|
--
|
|||
|
-- 小组配置
|
|||
|
--
|
|||
|
--================================================================
|
|||
|
|
|||
|
suites = {
|
|||
|
{
|
|||
|
-- suite_id = 0,
|
|||
|
-- description = ,
|
|||
|
monsters = { 54 },
|
|||
|
gadgets = { },
|
|||
|
regions = { 26 },
|
|||
|
triggers = { "ANY_MONSTER_DIE_26" },
|
|||
|
rand_weight = 100
|
|||
|
},
|
|||
|
{
|
|||
|
-- suite_id = 1,
|
|||
|
-- description = suite_2,
|
|||
|
monsters = { 55 },
|
|||
|
gadgets = { },
|
|||
|
regions = { 26 },
|
|||
|
triggers = { "ANY_MONSTER_DIE_26" },
|
|||
|
rand_weight = 100
|
|||
|
},
|
|||
|
{
|
|||
|
-- suite_id = 2,
|
|||
|
-- description = suite_3,
|
|||
|
monsters = { 56 },
|
|||
|
gadgets = { },
|
|||
|
regions = { 26 },
|
|||
|
triggers = { "ANY_MONSTER_DIE_26" },
|
|||
|
rand_weight = 100
|
|||
|
},
|
|||
|
{
|
|||
|
-- suite_id = 3,
|
|||
|
-- description = suite_4,
|
|||
|
monsters = { },
|
|||
|
gadgets = { },
|
|||
|
regions = { },
|
|||
|
triggers = { },
|
|||
|
rand_weight = 100
|
|||
|
}
|
|||
|
}
|
|||
|
|
|||
|
--================================================================
|
|||
|
--
|
|||
|
-- 触发器
|
|||
|
--
|
|||
|
--================================================================
|
|||
|
|
|||
|
-- 触发条件
|
|||
|
function condition_EVENT_ANY_MONSTER_DIE_26(context, evt)
|
|||
|
-- 判断剩余怪物数量是否是0
|
|||
|
if ScriptLib.GetGroupMonsterCount(context) ~= 0 then
|
|||
|
return false
|
|||
|
end
|
|||
|
|
|||
|
return true
|
|||
|
end
|
|||
|
|
|||
|
-- 触发操作
|
|||
|
function action_EVENT_ANY_MONSTER_DIE_26(context, evt)
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001001, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001002, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001003, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001005, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001006, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001007, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001008, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001009, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001010, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001011, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001012, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001013, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001014, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001015, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001016, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 杀死Group内所有monster
|
|||
|
if 0 ~= ScriptLib.KillGroupEntity(context, { group_id = 230001017, kill_policy = GroupKillPolicy.GROUP_KILL_MONSTER }) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
|
|||
|
-- 调用提示id为 20010701 的提示UI,会显示在屏幕中央偏下位置,id索引自 ReminderData表格
|
|||
|
if 0 ~= ScriptLib.ShowReminder(context, 20010701) then
|
|||
|
return -1
|
|||
|
end
|
|||
|
|
|||
|
return 0
|
|||
|
end
|