mirror of
https://github.com/FlourishingWorld/hk4e.git
synced 2026-02-23 14:32:27 +08:00
更新配置表
This commit is contained in:
24
gdconf/game_data_config/lua/scene/20169/scene20169.lua
Normal file
24
gdconf/game_data_config/lua/scene/20169/scene20169.lua
Normal file
@@ -0,0 +1,24 @@
|
||||
-- 地图配置
|
||||
scene_config = {
|
||||
begin_pos = { x = -512.0, z = -512.0 },
|
||||
size = { x = 1024.0, z = 1024.0 },
|
||||
born_pos = { x = 10.747, y = 77.174, z = -80.603 },
|
||||
born_rot = { x = 0.000, y = 90.000, z = 0.000 },
|
||||
die_y = -20,
|
||||
city_id = 4,
|
||||
vision_anchor = { x = -1000.0, z = -1000.0 }
|
||||
}
|
||||
|
||||
-- 所有的区块
|
||||
blocks = { 20169 }
|
||||
|
||||
-- 所有的区块范围坐标
|
||||
block_rects = {
|
||||
{ min = { x = -512.0, z = -512.0 }, max = { x = 512.0, z = 512.0 } }
|
||||
}
|
||||
|
||||
-- Dummy Points
|
||||
dummy_points = { "dummy_points" }
|
||||
|
||||
-- Routes
|
||||
routes_config = { "routes" }
|
||||
@@ -0,0 +1,42 @@
|
||||
{
|
||||
"sceneId": 20169,
|
||||
"routes": [
|
||||
{
|
||||
"localId": 1,
|
||||
"name": "Route_001",
|
||||
"type": "Loop",
|
||||
"rotType": "ROT_NONE",
|
||||
"rotAngleType": "ROT_ANGLE_Y",
|
||||
"arriveRange": 2.0,
|
||||
"points": [
|
||||
{
|
||||
"pos": {
|
||||
"x": -36.26289,
|
||||
"y": 0.485065937,
|
||||
"z": 56.1520271
|
||||
},
|
||||
"waitTime": 2.0,
|
||||
"speedLevel": 1
|
||||
},
|
||||
{
|
||||
"pos": {
|
||||
"x": -34.4597778,
|
||||
"y": 0.474999756,
|
||||
"z": 49.7778
|
||||
},
|
||||
"waitTime": 2.0,
|
||||
"speedLevel": 1
|
||||
},
|
||||
{
|
||||
"pos": {
|
||||
"x": -37.53732,
|
||||
"y": 0.459999084,
|
||||
"z": 52.0528564
|
||||
},
|
||||
"waitTime": 0.0,
|
||||
"speedLevel": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
-- 所有的group
|
||||
groups = {
|
||||
{ id = 220169001, refresh_id = 1, pos = { x = -33.145, y = 0.460, z = 57.993 } },
|
||||
{ id = 220169002, refresh_id = 1001, pos = { x = -34.057, y = 0.467, z = 51.893 } },
|
||||
{ id = 220169003, refresh_id = 1, pos = { x = -21.255, y = 0.511, z = 50.483 } },
|
||||
{ id = 220169004, refresh_id = 1002, pos = { x = -2.610, y = -2.531, z = 52.948 } },
|
||||
{ id = 220169005, refresh_id = 1, pos = { x = -5.092, y = 54.332, z = -74.052 } },
|
||||
{ id = 220169006, refresh_id = 1, pos = { x = 25.743, y = 76.984, z = -83.069 } },
|
||||
{ id = 220169007, refresh_id = 1, pos = { x = 20.909, y = 65.152, z = -70.827 } },
|
||||
{ id = 220169008, refresh_id = 1, pos = { x = -4.401, y = 54.356, z = -75.708 } },
|
||||
{ id = 220169009, refresh_id = 1, pos = { x = 11.187, y = 65.923, z = -81.731 } },
|
||||
{ id = 220169010, pos = { x = 63.711, y = 76.945, z = -81.278 }, business = { type = 1 } },
|
||||
{ id = 220169011, pos = { x = -3.807, y = -2.531, z = 53.175 }, business = { type = 1 } },
|
||||
{ id = 220169012, refresh_id = 1, pos = { x = 37.112, y = 77.040, z = -81.199 } },
|
||||
{ id = 220169013, refresh_id = 1, pos = { x = 25.273, y = 65.722, z = -87.026 } }
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
dummy_points = {
|
||||
["Q303105_guide"] = { pos = { x = -8.131, y = -2.531, z = 54.131 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303105_kaiche"] = { pos = { x = -63.270, y = 1.875, z = 52.341 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303105_N12947"] = { pos = { x = -9.169, y = -2.531, z = 53.425 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303105_T303105_N10000005"] = { pos = { x = -8.177, y = -2.531, z = 54.754 }, rot = { x = 0.000, y = 113.060, z = 0.000 } },
|
||||
["Q303105_T303105_N10013"] = { pos = { x = -0.155, y = -2.531, z = 50.764 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303105_T303105_N1005"] = { pos = { x = -8.312, y = -2.531, z = 53.141 }, rot = { x = 0.000, y = 101.820, z = 0.000 } },
|
||||
["Q303105_T303105_N1017"] = { pos = { x = -0.336, y = -2.531, z = 54.207 }, rot = { x = 0.000, y = 184.190, z = 0.000 } },
|
||||
["Q303105_T303105_N1056"] = { pos = { x = -6.828, y = -2.506, z = 51.072 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303105_T303105_N12947"] = { pos = { x = -8.475, y = -2.531, z = 52.130 }, rot = { x = 0.000, y = 78.310, z = 0.000 } },
|
||||
["Q303105_transpoint"] = { pos = { x = -77.169, y = 1.806, z = 51.958 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303111_guide"] = { pos = { x = 17.609, y = 77.040, z = -81.971 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303111_N12947"] = { pos = { x = 16.706, y = 77.040, z = -82.860 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303111_T303103_N10000005"] = { pos = { x = 16.413, y = 77.040, z = -80.653 }, rot = { x = 0.000, y = 174.620, z = 0.000 } },
|
||||
["Q303111_T303103_N10013"] = { pos = { x = 2.603, y = 76.921, z = -84.417 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303111_T303103_N1005"] = { pos = { x = 15.431, y = 77.123, z = -80.805 }, rot = { x = 0.000, y = 175.310, z = 0.000 } },
|
||||
["Q303111_T303103_N1056"] = { pos = { x = 15.091, y = 77.126, z = -82.639 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303111_T303103_N12947"] = { pos = { x = 15.159, y = 77.085, z = -83.303 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303111_T303103_N12994"] = { pos = { x = 2.832, y = 76.921, z = -83.546 }, rot = { x = 0.000, y = 177.070, z = 0.000 } },
|
||||
["Q303117_guide"] = { pos = { x = 10.811, y = 65.850, z = -90.566 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303118_guide"] = { pos = { x = 18.543, y = 77.040, z = -81.025 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303118_N12947"] = { pos = { x = 17.114, y = 77.040, z = -81.433 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303118_T303118_N10000005"] = { pos = { x = 17.363, y = 77.040, z = -78.488 }, rot = { x = 0.000, y = 250.360, z = 0.000 } },
|
||||
["Q303118_T303118_N10013"] = { pos = { x = 3.393, y = 76.921, z = -85.094 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303118_T303118_N1005"] = { pos = { x = 17.417, y = 77.040, z = -79.597 }, rot = { x = 0.000, y = 279.340, z = 0.000 } },
|
||||
["Q303118_T303118_N1056"] = { pos = { x = 15.242, y = 77.127, z = -79.029 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303118_T303118_N12947"] = { pos = { x = 15.982, y = 77.040, z = -77.278 }, rot = { x = 0.000, y = 240.380, z = 0.000 } },
|
||||
["Q303118_T303118_N12997"] = { pos = { x = 3.340, y = 76.921, z = -83.589 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303119_guide"] = { pos = { x = 57.593, y = 76.940, z = -81.142 }, rot = { x = 0.000, y = 0.000, z = 0.000 } },
|
||||
["Q303120_guide"] = { pos = { x = -3.588, y = -2.532, z = 53.148 }, rot = { x = 0.000, y = 0.000, z = 0.000 } }
|
||||
}
|
||||
@@ -0,0 +1,165 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169001
|
||||
}
|
||||
|
||||
-- DEFS_MISCS
|
||||
local EnterConfigID = 1013
|
||||
|
||||
local thunderFloorTimer = {7}
|
||||
|
||||
local floorList = {1001,1002}
|
||||
|
||||
local randomNumMin = 2
|
||||
|
||||
local randomNumMax = 2
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 1001, gadget_id = 70360285, pos = { x = -65.514, y = 1.703, z = 52.016 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 1002, gadget_id = 70360285, pos = { x = -62.853, y = 1.726, z = 52.016 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 1003, gadget_id = 70360280, pos = { x = -57.518, y = 3.000, z = 48.070 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 1004, gadget_id = 70360280, pos = { x = -53.267, y = 3.000, z = 48.070 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 1007, gadget_id = 70220070, pos = { x = -59.501, y = 1.695, z = 50.903 }, rot = { x = 0.000, y = 115.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 1008, gadget_id = 70220071, pos = { x = -58.541, y = 1.695, z = 52.935 }, rot = { x = 0.000, y = 115.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 1009, gadget_id = 70360291, pos = { x = -57.518, y = 3.000, z = 56.879 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 1010, gadget_id = 70360291, pos = { x = -53.267, y = 3.000, z = 56.717 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
-- 邪眼工厂切环境
|
||||
{ config_id = 1005, shape = RegionShape.CUBIC, size = { x = 15.000, y = 10.000, z = 15.000 }, pos = { x = -76.557, y = 4.722, z = 52.117 } },
|
||||
-- 雷电地板触发
|
||||
{ config_id = 1013, shape = RegionShape.CUBIC, size = { x = 10.000, y = 15.000, z = 15.000 }, pos = { x = -67.537, y = 6.000, z = 51.897 } },
|
||||
-- 雷矢触发
|
||||
{ config_id = 1014, shape = RegionShape.CUBIC, size = { x = 10.000, y = 15.000, z = 15.000 }, pos = { x = -55.613, y = 6.000, z = 51.897 } }
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
-- 邪眼工厂切环境
|
||||
{ config_id = 1001005, name = "ENTER_REGION_1005", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_1005", action = "action_EVENT_ENTER_REGION_1005" },
|
||||
-- 雷电地板触发
|
||||
{ config_id = 1001013, name = "ENTER_REGION_1013", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_1013", action = "" },
|
||||
-- 雷矢触发
|
||||
{ config_id = 1001014, name = "ENTER_REGION_1014", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_1014", action = "action_EVENT_ENTER_REGION_1014", trigger_count = 0 }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 1001, 1002, 1003, 1004, 1007, 1008, 1009, 1010 },
|
||||
regions = { 1005, 1013, 1014 },
|
||||
triggers = { "ENTER_REGION_1005", "ENTER_REGION_1013", "ENTER_REGION_1014" },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_1005(context, evt)
|
||||
if evt.param1 ~= 1005 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_1005(context, evt)
|
||||
|
||||
ScriptLib.SetWeatherAreaState(context, 10150, 1)
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_1013(context, evt)
|
||||
if evt.param1 ~= 1013 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_1014(context, evt)
|
||||
if evt.param1 ~= 1014 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_1014(context, evt)
|
||||
-- 将configid为 1003 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 1003, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 将configid为 1004 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 1004, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
require "V2_0/ThunderFloor"
|
||||
@@ -0,0 +1,144 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169002
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
{ config_id = 2001, monster_id = 23010501, pos = { x = -30.433, y = 0.460, z = 58.802 }, rot = { x = 0.000, y = 60.000, z = 0.000 }, level = 1, disableWander = true, pose_id = 9001 },
|
||||
{ config_id = 2002, monster_id = 23010401, pos = { x = -30.512, y = 0.460, z = 49.119 }, rot = { x = 0.000, y = 315.000, z = 0.000 }, level = 1, pose_id = 9012 },
|
||||
{ config_id = 2003, monster_id = 23010301, pos = { x = -36.263, y = 0.485, z = 56.152 }, rot = { x = 0.000, y = 90.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 2004, gadget_id = 70220070, pos = { x = -39.765, y = 0.460, z = 59.082 }, rot = { x = 0.000, y = 145.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2005, gadget_id = 70220071, pos = { x = -37.932, y = 0.458, z = 60.391 }, rot = { x = 0.000, y = 145.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2006, gadget_id = 70220070, pos = { x = -28.772, y = 0.451, z = 45.212 }, rot = { x = 0.000, y = 145.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2007, gadget_id = 70220071, pos = { x = -26.940, y = 0.460, z = 46.522 }, rot = { x = 0.000, y = 145.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2008, gadget_id = 70220071, pos = { x = -29.248, y = 1.563, z = 67.321 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2009, gadget_id = 70220070, pos = { x = -27.004, y = 1.563, z = 67.321 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2010, gadget_id = 70220071, pos = { x = -34.082, y = 1.563, z = 67.321 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2011, gadget_id = 70220070, pos = { x = -31.838, y = 1.563, z = 67.321 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2012, gadget_id = 70211001, pos = { x = -24.223, y = 1.563, z = 69.032 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1, drop_tag = "战斗低级须弥", isOneoff = true, persistent = true },
|
||||
{ config_id = 2013, gadget_id = 70220071, pos = { x = -39.417, y = 0.460, z = 47.178 }, rot = { x = 0.000, y = 30.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2014, gadget_id = 70220070, pos = { x = -37.477, y = 0.460, z = 46.061 }, rot = { x = 0.000, y = 30.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2015, gadget_id = 70220048, pos = { x = -28.369, y = 0.496, z = 60.744 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2016, gadget_id = 70220048, pos = { x = -27.695, y = 0.460, z = 57.539 }, rot = { x = 0.000, y = 30.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2017, gadget_id = 70220050, pos = { x = -28.630, y = 0.497, z = 58.998 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 2018, gadget_id = 70220050, pos = { x = -27.607, y = 0.483, z = 59.279 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
-- 指引点
|
||||
{ config_id = 2020, shape = RegionShape.CUBIC, size = { x = 10.000, y = 15.000, z = 20.000 }, pos = { x = -45.431, y = 2.387, z = 51.893 } }
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
{ config_id = 1002019, name = "ANY_MONSTER_DIE_2019", event = EventType.EVENT_ANY_MONSTER_DIE, source = "", condition = "condition_EVENT_ANY_MONSTER_DIE_2019", action = "action_EVENT_ANY_MONSTER_DIE_2019" },
|
||||
-- 指引点
|
||||
{ config_id = 1002020, name = "ENTER_REGION_2020", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_2020", action = "action_EVENT_ENTER_REGION_2020" }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { 2001, 2002, 2003 },
|
||||
gadgets = { 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018 },
|
||||
regions = { 2020 },
|
||||
triggers = { "ANY_MONSTER_DIE_2019", "ENTER_REGION_2020" },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ANY_MONSTER_DIE_2019(context, evt)
|
||||
-- 判断剩余怪物数量是否是0
|
||||
if ScriptLib.GetGroupMonsterCount(context) ~= 0 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ANY_MONSTER_DIE_2019(context, evt)
|
||||
-- 改变指定group组220169003中, configid为3001的gadget的state
|
||||
if 0 ~= ScriptLib.SetGroupGadgetStateByConfigId(context, 220169003, 3001, GadgetState.GearAction2) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_GroupId_ConfigId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 重新生成指定group,指定suite
|
||||
if 0 ~= ScriptLib.RefreshGroup(context, { group_id = 220169013, suite = 5 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : refresh_group_to_suite")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_2020(context, evt)
|
||||
if evt.param1 ~= 2020 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_2020(context, evt)
|
||||
-- 重新生成指定group,指定suite
|
||||
if 0 ~= ScriptLib.RefreshGroup(context, { group_id = 220169013, suite = 6 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : refresh_group_to_suite")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
@@ -0,0 +1,157 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169003
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 3001, gadget_id = 70290140, pos = { x = -21.196, y = 0.628, z = 52.153 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1, state = GadgetState.GearStop },
|
||||
{ config_id = 3002, gadget_id = 70290145, pos = { x = -21.810, y = 6.754, z = 51.174 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 3003, gadget_id = 70290142, pos = { x = -21.417, y = 2.456, z = 52.157 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 3004, gadget_id = 70290144, pos = { x = -21.452, y = 2.062, z = 51.535 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1, state = GadgetState.Action01 },
|
||||
{ config_id = 3005, gadget_id = 70290144, pos = { x = -21.452, y = 3.229, z = 52.163 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1, state = GadgetState.Action01 },
|
||||
{ config_id = 3006, gadget_id = 70290143, pos = { x = -21.452, y = 2.062, z = 52.746 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1, state = GadgetState.Action01 },
|
||||
{ config_id = 3007, gadget_id = 70360001, pos = { x = -21.408, y = 1.422, z = 52.140 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
{ config_id = 1003008, name = "TIME_AXIS_PASS_3008", event = EventType.EVENT_TIME_AXIS_PASS, source = "", condition = "", action = "" },
|
||||
{ config_id = 1003009, name = "SELECT_OPTION_3009", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_3009", action = "action_EVENT_SELECT_OPTION_3009" },
|
||||
{ config_id = 1003010, name = "GADGET_STATE_CHANGE_3010", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_3010", action = "action_EVENT_GADGET_STATE_CHANGE_3010" }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 3001, 3002 },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_3009(context, evt)
|
||||
-- 判断是gadgetid 3007 option_id 1
|
||||
if 3007 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 1 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_3009(context, evt)
|
||||
-- 将configid为 3001 的物件更改为状态 GadgetState.GearAction2
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 3001, GadgetState.GearAction2) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 将configid为 3006 的物件更改为状态 GadgetState.GearStop
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 3006, GadgetState.GearStop) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 将configid为 3004 的物件更改为状态 GadgetState.GearStop
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 3004, GadgetState.GearStop) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 将configid为 3005 的物件更改为状态 GadgetState.GearStop
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 3005, GadgetState.GearStop) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 将configid为 3003 的物件更改为状态 GadgetState.GearStop
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 3003, GadgetState.GearStop) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 删除指定group: 220169003 ;指定config:3007;物件身上指定option:1;
|
||||
if 0 ~= ScriptLib.DelWorktopOptionByGroupId(context, 220169003, 3007, 1) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : del_work_options_by_group_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_STATE_CHANGE_3010(context, evt)
|
||||
if 3003 ~= evt.param2 or GadgetState.GearStart ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_STATE_CHANGE_3010(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptionsByGroupId(context, 220169003, 3007, {1}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_wok_options_by_configid")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
@@ -0,0 +1,195 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169004
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
{ config_id = 4001, monster_id = 23050101, pos = { x = 0.233, y = -2.544, z = 50.043 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 4002, monster_id = 23020101, pos = { x = 0.233, y = -2.544, z = 54.987 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 4006, gadget_id = 70290833, pos = { x = 6.046, y = -2.045, z = 52.463 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
{ config_id = 4003, shape = RegionShape.CUBIC, size = { x = 4.000, y = 6.000, z = 3.000 }, pos = { x = 6.046, y = -2.045, z = 52.463 } }
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
{ config_id = 1004003, name = "ENTER_REGION_4003", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_4003", action = "action_EVENT_ENTER_REGION_4003" },
|
||||
{ config_id = 1004004, name = "QUEST_FINISH_4004", event = EventType.EVENT_QUEST_FINISH, source = "", condition = "condition_EVENT_QUEST_FINISH_4004", action = "action_EVENT_QUEST_FINISH_4004" },
|
||||
{ config_id = 1004005, name = "ANY_MONSTER_DIE_4005", event = EventType.EVENT_ANY_MONSTER_DIE, source = "", condition = "condition_EVENT_ANY_MONSTER_DIE_4005", action = "action_EVENT_ANY_MONSTER_DIE_4005" }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { },
|
||||
regions = { },
|
||||
triggers = { "QUEST_FINISH_4004" },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 2,
|
||||
-- description = ,
|
||||
monsters = { 4001, 4002 },
|
||||
gadgets = { },
|
||||
regions = { },
|
||||
triggers = { "ANY_MONSTER_DIE_4005" },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 3,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 4006 },
|
||||
regions = { 4003 },
|
||||
triggers = { "ENTER_REGION_4003" },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 创建指定group的指定suite内所有内容
|
||||
function TLA_add_groupsuite(context, evt, group_id, suite_id)
|
||||
-- 添加suitesuite_id的新内容
|
||||
ScriptLib.AddExtraGroupSuite(context, group_id, suite_id)
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 设置指定gadget的state
|
||||
function TLA_set_gadget_state_by_configid(context, evt, config_id, state)
|
||||
-- 将configid为 config_id 的物件更改为状态 state
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, config_id, state) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_4003(context, evt)
|
||||
if evt.param1 ~= 4003 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_4003(context, evt)
|
||||
-- 通知任务系统完成条件类型"LUA通知",复杂参数为quest_param的进度+1
|
||||
if 0 ~= ScriptLib.AddQuestProgress(context, "30312101") then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : add_quest_progress")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_QUEST_FINISH_4004(context, evt)
|
||||
--检查ID为303105的任务的完成状态是否为1(1=完成,0=失败)
|
||||
--此事件需要配合Quest表使用,在Quest表里的完成执行中配置“通知group脚本”,则该任务完成后服务端会向对应的group发送通知,参数1填写场景ID,参数2填写group ID(如果不填则会通知所有group)
|
||||
|
||||
--检查任务ID
|
||||
if 303105 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
--检查任务成功状态
|
||||
if 1 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_QUEST_FINISH_4004(context, evt)
|
||||
-- 添加suite2的新内容
|
||||
ScriptLib.AddExtraGroupSuite(context, 220169004, 2)
|
||||
|
||||
-- 改变指定group组220169003中, configid为3001的gadget的state
|
||||
if 0 ~= ScriptLib.SetGroupGadgetStateByConfigId(context, 220169003, 3001, GadgetState.Default) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_GroupId_ConfigId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 重新生成指定group,指定suite
|
||||
if 0 ~= ScriptLib.RefreshGroup(context, { group_id = 220169013, suite = 6 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : refresh_group_to_suite")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ANY_MONSTER_DIE_4005(context, evt)
|
||||
-- 判断剩余怪物数量是否是0
|
||||
if ScriptLib.GetGroupMonsterCount(context) ~= 0 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ANY_MONSTER_DIE_4005(context, evt)
|
||||
TLA_add_groupsuite(context, evt, 220169004, 3)
|
||||
|
||||
ScriptLib.AddQuestProgress(context, "30312001")
|
||||
|
||||
TLA_set_gadget_state_by_configid(context, evt, 4006, GadgetState.GearStart)
|
||||
|
||||
return 0
|
||||
end
|
||||
@@ -0,0 +1,244 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169005
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 5001, gadget_id = 70290141, pos = { x = 28.952, y = 65.783, z = -87.105 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5002, gadget_id = 70290141, pos = { x = -13.086, y = 54.575, z = -73.675 }, rot = { x = 0.000, y = 90.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5003, gadget_id = 70290141, pos = { x = 10.896, y = 71.990, z = -94.407 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5007, gadget_id = 70360001, pos = { x = 28.952, y = 66.486, z = -87.105 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5008, gadget_id = 70360001, pos = { x = -13.086, y = 55.266, z = -73.675 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5009, gadget_id = 70360001, pos = { x = 10.896, y = 72.694, z = -94.407 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5013, gadget_id = 70220048, pos = { x = 13.059, y = 71.990, z = -93.692 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5014, gadget_id = 70220048, pos = { x = 8.502, y = 71.990, z = -94.620 }, rot = { x = 0.000, y = 30.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5015, gadget_id = 70220050, pos = { x = 8.666, y = 71.990, z = -93.132 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5016, gadget_id = 70220051, pos = { x = 14.253, y = 71.990, z = -92.978 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 5017, gadget_id = 70211101, pos = { x = 11.070, y = 71.990, z = -93.705 }, rot = { x = 0.000, y = 45.000, z = 0.000 }, level = 1, drop_tag = "解谜低级须弥", isOneoff = true, persistent = true }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
{ config_id = 1005004, name = "GADGET_CREATE_5004", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_5004", action = "action_EVENT_GADGET_CREATE_5004" },
|
||||
{ config_id = 1005005, name = "GADGET_CREATE_5005", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_5005", action = "action_EVENT_GADGET_CREATE_5005" },
|
||||
{ config_id = 1005006, name = "GADGET_CREATE_5006", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_5006", action = "action_EVENT_GADGET_CREATE_5006" },
|
||||
{ config_id = 1005010, name = "SELECT_OPTION_5010", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_5010", action = "action_EVENT_SELECT_OPTION_5010" },
|
||||
{ config_id = 1005011, name = "SELECT_OPTION_5011", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_5011", action = "action_EVENT_SELECT_OPTION_5011" },
|
||||
{ config_id = 1005012, name = "SELECT_OPTION_5012", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_5012", action = "action_EVENT_SELECT_OPTION_5012" }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 5013, 5014, 5015, 5016, 5017 },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_CREATE_5004(context, evt)
|
||||
if 5007 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_CREATE_5004(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptions(context, {73}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_work_options")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_CREATE_5005(context, evt)
|
||||
if 5008 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_CREATE_5005(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptions(context, {73}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_work_options")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_CREATE_5006(context, evt)
|
||||
if 5009 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_CREATE_5006(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptions(context, {73}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_work_options")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_5010(context, evt)
|
||||
-- 判断是gadgetid 5007 option_id 73
|
||||
if 5007 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 73 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_5010(context, evt)
|
||||
-- 将configid为 5001 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 5001, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 删除指定group: 220169005 ;指定config:5007;物件身上指定option:73;
|
||||
if 0 ~= ScriptLib.DelWorktopOptionByGroupId(context, 220169005, 5007, 73) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : del_work_options_by_group_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_5011(context, evt)
|
||||
-- 判断是gadgetid 5008 option_id 73
|
||||
if 5008 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 73 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_5011(context, evt)
|
||||
-- 将configid为 5002 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 5002, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 删除指定group: 220169005 ;指定config:5008;物件身上指定option:73;
|
||||
if 0 ~= ScriptLib.DelWorktopOptionByGroupId(context, 220169005, 5008, 73) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : del_work_options_by_group_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_5012(context, evt)
|
||||
-- 判断是gadgetid 5009 option_id 73
|
||||
if 5009 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 73 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_5012(context, evt)
|
||||
-- 将configid为 5003 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 5003, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 删除指定group: 220169005 ;指定config:5009;物件身上指定option:73;
|
||||
if 0 ~= ScriptLib.DelWorktopOptionByGroupId(context, 220169005, 5009, 73) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : del_work_options_by_group_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
@@ -0,0 +1,347 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169006
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 6001, gadget_id = 70290140, pos = { x = 25.572, y = 77.038, z = -81.017 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 6002, gadget_id = 70290145, pos = { x = 25.045, y = 83.199, z = -81.022 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 6003, gadget_id = 70290142, pos = { x = 25.315, y = 79.034, z = -81.019 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 6004, gadget_id = 70290144, pos = { x = 25.284, y = 78.567, z = -81.593 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 6005, gadget_id = 70290144, pos = { x = 25.284, y = 79.752, z = -81.022 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 6006, gadget_id = 70290143, pos = { x = 25.269, y = 78.570, z = -80.492 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 6007, gadget_id = 70360001, pos = { x = 25.608, y = 77.985, z = -81.225 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 6016, gadget_id = 70290833, pos = { x = 68.739, y = 77.470, z = -81.017 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
-- 创建退出点
|
||||
{ config_id = 6014, shape = RegionShape.CUBIC, size = { x = 10.000, y = 10.000, z = 15.000 }, pos = { x = 47.916, y = 80.473, z = -81.017 } },
|
||||
-- 退出点传送
|
||||
{ config_id = 6015, shape = RegionShape.CUBIC, size = { x = 4.000, y = 6.000, z = 3.000 }, pos = { x = 68.739, y = 77.470, z = -81.017 } }
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
{ config_id = 1006008, name = "TIME_AXIS_PASS_6008", event = EventType.EVENT_TIME_AXIS_PASS, source = "", condition = "condition_EVENT_TIME_AXIS_PASS_6008", action = "action_EVENT_TIME_AXIS_PASS_6008" },
|
||||
{ config_id = 1006009, name = "GADGET_STATE_CHANGE_6009", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_6009", action = "action_EVENT_GADGET_STATE_CHANGE_6009" },
|
||||
{ config_id = 1006010, name = "GADGET_STATE_CHANGE_6010", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_6010", action = "action_EVENT_GADGET_STATE_CHANGE_6010" },
|
||||
{ config_id = 1006011, name = "GADGET_STATE_CHANGE_6011", event = EventType.EVENT_GADGET_STATE_CHANGE, source = "", condition = "condition_EVENT_GADGET_STATE_CHANGE_6011", action = "action_EVENT_GADGET_STATE_CHANGE_6011" },
|
||||
{ config_id = 1006012, name = "SELECT_OPTION_6012", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_6012", action = "action_EVENT_SELECT_OPTION_6012" },
|
||||
{ config_id = 1006013, name = "QUEST_FINISH_6013", event = EventType.EVENT_QUEST_FINISH, source = "", condition = "condition_EVENT_QUEST_FINISH_6013", action = "action_EVENT_QUEST_FINISH_6013" },
|
||||
-- 创建退出点
|
||||
{ config_id = 1006014, name = "ENTER_REGION_6014", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_6014", action = "action_EVENT_ENTER_REGION_6014" },
|
||||
-- 退出点传送
|
||||
{ config_id = 1006015, name = "ENTER_REGION_6015", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_6015", action = "action_EVENT_ENTER_REGION_6015" }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 6001, 6002 },
|
||||
regions = { 6014 },
|
||||
triggers = { "QUEST_FINISH_6013", "ENTER_REGION_6014" },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 2,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 6016 },
|
||||
regions = { 6015 },
|
||||
triggers = { "ENTER_REGION_6015" },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 通知任务进度
|
||||
function TLA_add_quest_progress(context, evt, quest_param)
|
||||
-- 通知任务系统完成条件类型"LUA通知",复杂参数为quest_param的进度+1
|
||||
if 0 ~= ScriptLib.AddQuestProgress(context, quest_param) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : add_quest_progress")
|
||||
return -1
|
||||
end
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 刷新指定group至指定suite
|
||||
function TLA_refresh_group_tosuite(context, evt, group_id, suite_id)
|
||||
-- 重新生成指定group,指定suite
|
||||
if 0 ~= ScriptLib.RefreshGroup(context, { group_id = group_id, suite = suite_id }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : refresh_group_to_suite")
|
||||
return -1
|
||||
end
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_TIME_AXIS_PASS_6008(context, evt)
|
||||
if "timer1" ~= evt.source_name or 1 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_TIME_AXIS_PASS_6008(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptionsByGroupId(context, 220169006, 6007, {1}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_wok_options_by_configid")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 改变指定group组220169006中, configid为6003的gadget的state
|
||||
if 0 ~= ScriptLib.SetGroupGadgetStateByConfigId(context, 220169006, 6003, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_GroupId_ConfigId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_STATE_CHANGE_6009(context, evt)
|
||||
-- 检测config_id为6001的gadget是否从GadgetState.Default变为GadgetState.GearStart
|
||||
if 6001 ~= evt.param2 or GadgetState.GearStart ~= evt.param1 or GadgetState.Default ~= evt.param3 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_STATE_CHANGE_6009(context, evt)
|
||||
-- 改变指定group组220169006中, configid为6004的gadget的state
|
||||
if 0 ~= ScriptLib.SetGroupGadgetStateByConfigId(context, 220169006, 6004, GadgetState.Action01) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_GroupId_ConfigId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_STATE_CHANGE_6010(context, evt)
|
||||
-- 检测config_id为6001的gadget是否从GadgetState.GearStart变为GadgetState.GearStop
|
||||
if 6001 ~= evt.param2 or GadgetState.GearStop ~= evt.param1 or GadgetState.GearStart ~= evt.param3 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_STATE_CHANGE_6010(context, evt)
|
||||
-- 改变指定group组220169006中, configid为6005的gadget的state
|
||||
if 0 ~= ScriptLib.SetGroupGadgetStateByConfigId(context, 220169006, 6005, GadgetState.Action01) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_GroupId_ConfigId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_STATE_CHANGE_6011(context, evt)
|
||||
-- 检测config_id为6001的gadget是否从GadgetState.GearStop变为GadgetState.GearAction1
|
||||
if 6001 ~= evt.param2 or GadgetState.GearAction1 ~= evt.param1 or GadgetState.GearStop ~= evt.param3 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_STATE_CHANGE_6011(context, evt)
|
||||
-- 改变指定group组220169006中, configid为6006的gadget的state
|
||||
if 0 ~= ScriptLib.SetGroupGadgetStateByConfigId(context, 220169006, 6006, GadgetState.Action01) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_GroupId_ConfigId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 创建标识为"timer1",时间节点为{2}的时间轴,false用于控制该时间轴是否循环
|
||||
ScriptLib.InitTimeAxis(context, "timer1", {2}, false)
|
||||
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_6012(context, evt)
|
||||
-- 判断是gadgetid 6007 option_id 1
|
||||
if 6007 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 1 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_6012(context, evt)
|
||||
-- 改变指定group组220169006中, configid为6001的gadget的state
|
||||
if 0 ~= ScriptLib.SetGroupGadgetStateByConfigId(context, 220169006, 6001, GadgetState.GearAction2) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_GroupId_ConfigId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 6003 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
|
||||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 6006 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
|
||||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 6004 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
|
||||
-- 永久关闭CongfigId的Gadget,需要和Groups的RefreshWithBlock标签搭配
|
||||
if 0 ~= ScriptLib.KillEntityByConfigId(context, { config_id = 6005 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : kill_entity_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_QUEST_FINISH_6013(context, evt)
|
||||
--检查ID为303118的任务的完成状态是否为1(1=完成,0=失败)
|
||||
--此事件需要配合Quest表使用,在Quest表里的完成执行中配置“通知group脚本”,则该任务完成后服务端会向对应的group发送通知,参数1填写场景ID,参数2填写group ID(如果不填则会通知所有group)
|
||||
|
||||
--检查任务ID
|
||||
if 303118 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
--检查任务成功状态
|
||||
if 1 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_QUEST_FINISH_6013(context, evt)
|
||||
-- 将configid为 6001 的物件更改为状态 GadgetState.GearAction2
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 6001, GadgetState.GearAction2) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_6014(context, evt)
|
||||
if evt.param1 ~= 6014 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_6014(context, evt)
|
||||
-- 添加suite2的新内容
|
||||
ScriptLib.AddExtraGroupSuite(context, 220169006, 2)
|
||||
|
||||
-- 将configid为 6016 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 6016, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_6015(context, evt)
|
||||
if evt.param1 ~= 6015 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_6015(context, evt)
|
||||
TLA_add_quest_progress(context, evt, "30311901")
|
||||
|
||||
ScriptLib.SetWeatherAreaState(context, 10150, 1)
|
||||
|
||||
TLA_refresh_group_tosuite(context, evt, 220169013, 4)
|
||||
|
||||
return 0
|
||||
end
|
||||
@@ -0,0 +1,94 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169007
|
||||
}
|
||||
|
||||
-- DEFS_MISCS
|
||||
local EnterConfigID = 7009
|
||||
|
||||
local thunderFloorTimer = {7}
|
||||
|
||||
local floorList = {7001,7002,7003,7004,7005,7006,7007,7008}
|
||||
|
||||
local randomNumMin = 8
|
||||
|
||||
local randomNumMax = 8
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 7001, gadget_id = 70360285, pos = { x = 25.370, y = 65.152, z = -73.803 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 7002, gadget_id = 70360285, pos = { x = 25.370, y = 65.152, z = -68.558 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 7003, gadget_id = 70360285, pos = { x = 22.708, y = 65.152, z = -68.558 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 7004, gadget_id = 70360285, pos = { x = 22.708, y = 65.152, z = -73.804 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 7005, gadget_id = 70360285, pos = { x = 20.056, y = 65.152, z = -68.565 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 7006, gadget_id = 70360285, pos = { x = 20.056, y = 65.152, z = -73.814 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 7007, gadget_id = 70360285, pos = { x = 17.407, y = 65.152, z = -73.814 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 7008, gadget_id = 70360285, pos = { x = 17.407, y = 65.152, z = -68.565 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
{ config_id = 7009, shape = RegionShape.CUBIC, size = { x = 10.000, y = 10.000, z = 20.000 }, pos = { x = 21.180, y = 68.436, z = -68.145 } }
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
{ config_id = 1007009, name = "ENTER_REGION_7009", event = EventType.EVENT_ENTER_REGION, source = "", condition = "", action = "" }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 7001, 7002, 7003, 7004, 7005, 7006, 7007, 7008 },
|
||||
regions = { 7009 },
|
||||
triggers = { "ENTER_REGION_7009" },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
require "V2_0/ThunderFloor"
|
||||
@@ -0,0 +1,234 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169008
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 8001, gadget_id = 70360283, pos = { x = -5.619, y = 63.363, z = -72.188 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 8002, gadget_id = 70360283, pos = { x = -2.701, y = 63.671, z = -63.282 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 8006, gadget_id = 70290833, pos = { x = -5.290, y = 54.768, z = -80.886 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 8008, gadget_id = 70290734, pos = { x = 15.196, y = 77.061, z = -80.645 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
{ config_id = 8003, shape = RegionShape.CUBIC, size = { x = 5.000, y = 10.000, z = 5.000 }, pos = { x = -5.619, y = 58.466, z = -72.188 } },
|
||||
{ config_id = 8004, shape = RegionShape.CUBIC, size = { x = 5.000, y = 10.000, z = 5.000 }, pos = { x = -2.701, y = 58.657, z = -63.282 } },
|
||||
-- 创建退出点
|
||||
{ config_id = 8005, shape = RegionShape.CUBIC, size = { x = 20.000, y = 10.000, z = 10.000 }, pos = { x = -8.082, y = 58.552, z = -75.708 } },
|
||||
-- 退出点传送
|
||||
{ config_id = 8007, shape = RegionShape.CUBIC, size = { x = 3.000, y = 6.000, z = 4.000 }, pos = { x = -5.290, y = 54.768, z = -80.886 } },
|
||||
{ config_id = 8009, shape = RegionShape.CUBIC, size = { x = 40.000, y = 10.000, z = 30.000 }, pos = { x = 22.899, y = 64.053, z = -88.281 } }
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
{ config_id = 1008003, name = "ENTER_REGION_8003", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_8003", action = "action_EVENT_ENTER_REGION_8003" },
|
||||
{ config_id = 1008004, name = "ENTER_REGION_8004", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_8004", action = "action_EVENT_ENTER_REGION_8004" },
|
||||
-- 创建退出点
|
||||
{ config_id = 1008005, name = "ENTER_REGION_8005", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_8005", action = "action_EVENT_ENTER_REGION_8005" },
|
||||
-- 退出点传送
|
||||
{ config_id = 1008007, name = "ENTER_REGION_8007", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_8007", action = "action_EVENT_ENTER_REGION_8007" },
|
||||
{ config_id = 1008009, name = "ENTER_REGION_8009", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_8009", action = "action_EVENT_ENTER_REGION_8009" }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 8001, 8002 },
|
||||
regions = { 8003, 8004, 8005, 8009 },
|
||||
triggers = { "ENTER_REGION_8003", "ENTER_REGION_8004", "ENTER_REGION_8005", "ENTER_REGION_8009" },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 2,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 8006 },
|
||||
regions = { 8007 },
|
||||
triggers = { "ENTER_REGION_8007" },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 3,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 8008 },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_8003(context, evt)
|
||||
if evt.param1 ~= 8003 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_8003(context, evt)
|
||||
-- 将configid为 8001 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 8001, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_8004(context, evt)
|
||||
if evt.param1 ~= 8004 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_8004(context, evt)
|
||||
-- 将configid为 8002 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 8002, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_8005(context, evt)
|
||||
if evt.param1 ~= 8005 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_8005(context, evt)
|
||||
-- 添加suite2的新内容
|
||||
ScriptLib.AddExtraGroupSuite(context, 220169008, 2)
|
||||
|
||||
-- 将configid为 8006 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 8006, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_8007(context, evt)
|
||||
if evt.param1 ~= 8007 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_8007(context, evt)
|
||||
-- 通知任务系统完成条件类型"LUA通知",复杂参数为quest_param的进度+1
|
||||
if 0 ~= ScriptLib.AddQuestProgress(context, "30311701") then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : add_quest_progress")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 添加suite3的新内容
|
||||
ScriptLib.AddExtraGroupSuite(context, 220169008, 3)
|
||||
|
||||
-- 重新生成指定group,指定suite
|
||||
if 0 ~= ScriptLib.RefreshGroup(context, { group_id = 220169013, suite = 3 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : refresh_group_to_suite")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_8009(context, evt)
|
||||
if evt.param1 ~= 8009 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_8009(context, evt)
|
||||
-- 重新生成指定group,指定suite
|
||||
if 0 ~= ScriptLib.RefreshGroup(context, { group_id = 220169013, suite = 2 }) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : refresh_group_to_suite")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
@@ -0,0 +1,422 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169009
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 9001, gadget_id = 70360287, pos = { x = 10.692, y = 65.721, z = -81.953 }, rot = { x = 0.000, y = 180.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 9002, gadget_id = 70360287, pos = { x = 10.850, y = 71.000, z = -76.619 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 9009, gadget_id = 70360288, pos = { x = 15.941, y = 71.104, z = -84.107 }, rot = { x = 0.000, y = 90.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 9010, gadget_id = 70360170, pos = { x = 20.131, y = 67.230, z = -82.407 }, rot = { x = 270.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 9013, gadget_id = 70360288, pos = { x = 13.460, y = 76.989, z = -69.929 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 9014, gadget_id = 70360170, pos = { x = 10.689, y = 72.571, z = -66.146 }, rot = { x = 270.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 9017, gadget_id = 70211101, pos = { x = 23.188, y = 65.301, z = -74.004 }, rot = { x = 0.000, y = 315.000, z = 0.000 }, level = 1, drop_tag = "解谜低级须弥", isOneoff = true, persistent = true }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
-- 单向门1开门
|
||||
{ config_id = 9007, shape = RegionShape.CUBIC, size = { x = 8.000, y = 8.000, z = 8.000 }, pos = { x = 10.692, y = 65.992, z = -87.525 } },
|
||||
-- 单向门2开门
|
||||
{ config_id = 9008, shape = RegionShape.CUBIC, size = { x = 10.000, y = 8.000, z = 6.000 }, pos = { x = 10.692, y = 71.902, z = -74.252 } },
|
||||
-- 单向门2关门
|
||||
{ config_id = 9018, shape = RegionShape.CUBIC, size = { x = 10.000, y = 8.000, z = 8.000 }, pos = { x = 10.692, y = 71.724, z = -85.567 } },
|
||||
-- 单向门1关门
|
||||
{ config_id = 9019, shape = RegionShape.CUBIC, size = { x = 9.000, y = 8.000, z = 8.000 }, pos = { x = 10.692, y = 65.921, z = -74.431 } }
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
-- 单向门1
|
||||
{ config_id = 1009003, name = "GADGET_CREATE_9003", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_9003", action = "action_EVENT_GADGET_CREATE_9003" },
|
||||
-- 单向门2
|
||||
{ config_id = 1009004, name = "GADGET_CREATE_9004", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_9004", action = "action_EVENT_GADGET_CREATE_9004" },
|
||||
-- 单向门1
|
||||
{ config_id = 1009005, name = "SELECT_OPTION_9005", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_9005", action = "action_EVENT_SELECT_OPTION_9005" },
|
||||
-- 单向门2
|
||||
{ config_id = 1009006, name = "SELECT_OPTION_9006", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_9006", action = "action_EVENT_SELECT_OPTION_9006" },
|
||||
-- 单向门1开门
|
||||
{ config_id = 1009007, name = "ENTER_REGION_9007", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_9007", action = "action_EVENT_ENTER_REGION_9007", trigger_count = 0 },
|
||||
-- 单向门2开门
|
||||
{ config_id = 1009008, name = "ENTER_REGION_9008", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_9008", action = "action_EVENT_ENTER_REGION_9008", trigger_count = 0 },
|
||||
-- 拉杆机关1
|
||||
{ config_id = 1009011, name = "GADGET_CREATE_9011", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_9011", action = "action_EVENT_GADGET_CREATE_9011" },
|
||||
-- 拉杆机关1
|
||||
{ config_id = 1009012, name = "SELECT_OPTION_9012", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_9012", action = "action_EVENT_SELECT_OPTION_9012" },
|
||||
-- 拉杆机关2
|
||||
{ config_id = 1009015, name = "GADGET_CREATE_9015", event = EventType.EVENT_GADGET_CREATE, source = "", condition = "condition_EVENT_GADGET_CREATE_9015", action = "action_EVENT_GADGET_CREATE_9015" },
|
||||
-- 拉杆机关2
|
||||
{ config_id = 1009016, name = "SELECT_OPTION_9016", event = EventType.EVENT_SELECT_OPTION, source = "", condition = "condition_EVENT_SELECT_OPTION_9016", action = "action_EVENT_SELECT_OPTION_9016" },
|
||||
-- 单向门2关门
|
||||
{ config_id = 1009018, name = "ENTER_REGION_9018", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_9018", action = "action_EVENT_ENTER_REGION_9018", trigger_count = 0 },
|
||||
-- 单向门1关门
|
||||
{ config_id = 1009019, name = "ENTER_REGION_9019", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_9019", action = "action_EVENT_ENTER_REGION_9019", trigger_count = 0 }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 9001, 9002, 9009, 9010, 9017 },
|
||||
regions = { 9007, 9008, 9018, 9019 },
|
||||
triggers = { "ENTER_REGION_9007", "ENTER_REGION_9008", "GADGET_CREATE_9011", "SELECT_OPTION_9012", "ENTER_REGION_9018", "ENTER_REGION_9019" },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_CREATE_9003(context, evt)
|
||||
if 9001 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_CREATE_9003(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptions(context, {1}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_work_options")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_CREATE_9004(context, evt)
|
||||
if 9002 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_CREATE_9004(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptions(context, {1}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_work_options")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_9005(context, evt)
|
||||
-- 判断是gadgetid 9001 option_id 1
|
||||
if 9001 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 1 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_9005(context, evt)
|
||||
-- 将configid为 9001 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9001, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 删除指定group: 220169009 ;指定config:9001;物件身上指定option:1;
|
||||
if 0 ~= ScriptLib.DelWorktopOptionByGroupId(context, 220169009, 9001, 1) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : del_work_options_by_group_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_9006(context, evt)
|
||||
-- 判断是gadgetid 9002 option_id 1
|
||||
if 9002 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 1 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_9006(context, evt)
|
||||
-- 将configid为 9002 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9002, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 删除指定group: 220169009 ;指定config:9002;物件身上指定option:1;
|
||||
if 0 ~= ScriptLib.DelWorktopOptionByGroupId(context, 220169009, 9002, 1) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : del_work_options_by_group_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_9007(context, evt)
|
||||
if evt.param1 ~= 9007 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_9007(context, evt)
|
||||
-- 将configid为 9001 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9001, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_9008(context, evt)
|
||||
if evt.param1 ~= 9008 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_9008(context, evt)
|
||||
-- 将configid为 9002 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9002, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_CREATE_9011(context, evt)
|
||||
if 9010 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_CREATE_9011(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptions(context, {7}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_work_options")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_9012(context, evt)
|
||||
-- 判断是gadgetid 9010 option_id 7
|
||||
if 9010 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 7 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_9012(context, evt)
|
||||
-- 将configid为 9010 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9010, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 将configid为 9009 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9009, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 删除指定group: 220169009 ;指定config:9010;物件身上指定option:7;
|
||||
if 0 ~= ScriptLib.DelWorktopOptionByGroupId(context, 220169009, 9010, 7) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : del_work_options_by_group_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_GADGET_CREATE_9015(context, evt)
|
||||
if 9014 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_GADGET_CREATE_9015(context, evt)
|
||||
-- 设置操作台选项
|
||||
if 0 ~= ScriptLib.SetWorktopOptions(context, {7}) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_work_options")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_SELECT_OPTION_9016(context, evt)
|
||||
-- 判断是gadgetid 9014 option_id 7
|
||||
if 9014 ~= evt.param1 then
|
||||
return false
|
||||
end
|
||||
|
||||
if 7 ~= evt.param2 then
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_SELECT_OPTION_9016(context, evt)
|
||||
-- 将configid为 9014 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9014, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 将configid为 9013 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9013, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 删除指定group: 220169009 ;指定config:9014;物件身上指定option:7;
|
||||
if 0 ~= ScriptLib.DelWorktopOptionByGroupId(context, 220169009, 9014, 7) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : del_work_options_by_group_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_9018(context, evt)
|
||||
if evt.param1 ~= 9018 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_9018(context, evt)
|
||||
-- 将configid为 9002 的物件更改为状态 GadgetState.Default
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9002, GadgetState.Default) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_9019(context, evt)
|
||||
if evt.param1 ~= 9019 then return false end
|
||||
|
||||
-- 判断角色数量不少于1
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 1 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_9019(context, evt)
|
||||
-- 将configid为 9001 的物件更改为状态 GadgetState.Default
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 9001, GadgetState.Default) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
@@ -0,0 +1,71 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169010
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
@@ -0,0 +1,71 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169011
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
@@ -0,0 +1,106 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169012
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 12001, gadget_id = 70360280, pos = { x = 35.110, y = 78.638, z = -85.906 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 12002, gadget_id = 70360280, pos = { x = 37.432, y = 78.642, z = -76.073 }, rot = { x = 0.000, y = 180.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 12003, gadget_id = 70360291, pos = { x = 35.110, y = 78.638, z = -74.967 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 12004, gadget_id = 70360291, pos = { x = 37.432, y = 78.642, z = -86.587 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
{ config_id = 12005, shape = RegionShape.CUBIC, size = { x = 10.000, y = 15.000, z = 15.000 }, pos = { x = 36.342, y = 82.386, z = -81.117 } }
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
{ config_id = 1012005, name = "ENTER_REGION_12005", event = EventType.EVENT_ENTER_REGION, source = "", condition = "condition_EVENT_ENTER_REGION_12005", action = "action_EVENT_ENTER_REGION_12005", trigger_count = 0 }
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 12001, 12002, 12003, 12004 },
|
||||
regions = { 12005 },
|
||||
triggers = { "ENTER_REGION_12005" },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 触发条件
|
||||
function condition_EVENT_ENTER_REGION_12005(context, evt)
|
||||
if evt.param1 ~= 12005 then return false end
|
||||
|
||||
-- 判断角色数量不少于0
|
||||
if ScriptLib.GetRegionEntityCount(context, { region_eid = evt.source_eid, entity_type = EntityType.AVATAR }) < 0 then
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 触发操作
|
||||
function action_EVENT_ENTER_REGION_12005(context, evt)
|
||||
-- 将configid为 12001 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 12001, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
-- 将configid为 12002 的物件更改为状态 GadgetState.GearStart
|
||||
if 0 ~= ScriptLib.SetGadgetStateByConfigId(context, 12002, GadgetState.GearStart) then
|
||||
ScriptLib.PrintContextLog(context, "@@ LUA_WARNING : set_gadget_state_by_configId")
|
||||
return -1
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
@@ -0,0 +1,121 @@
|
||||
-- 基础信息
|
||||
local base_info = {
|
||||
group_id = 220169013
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 怪物
|
||||
monsters = {
|
||||
}
|
||||
|
||||
-- NPC
|
||||
npcs = {
|
||||
}
|
||||
|
||||
-- 装置
|
||||
gadgets = {
|
||||
{ config_id = 13001, gadget_id = 70900201, pos = { x = 26.429, y = 65.851, z = -87.089 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 13002, gadget_id = 70900201, pos = { x = -5.290, y = 54.884, z = -79.569 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 13003, gadget_id = 70900201, pos = { x = 67.382, y = 77.457, z = -81.062 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 13004, gadget_id = 70900201, pos = { x = -33.652, y = 0.990, z = 52.260 }, rot = { x = 0.000, y = 0.000, z = 0.000 }, level = 1 },
|
||||
{ config_id = 13005, gadget_id = 70900201, pos = { x = 0.316, y = -1.916, z = 52.463 }, rot = { x = 0.000, y = 270.000, z = 0.000 }, level = 1 }
|
||||
}
|
||||
|
||||
-- 区域
|
||||
regions = {
|
||||
}
|
||||
|
||||
-- 触发器
|
||||
triggers = {
|
||||
}
|
||||
|
||||
-- 变量
|
||||
variables = {
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 初始化配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
-- 初始化时创建
|
||||
init_config = {
|
||||
suite = 1,
|
||||
end_suite = 0,
|
||||
rand_suite = false
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 小组配置
|
||||
--
|
||||
--================================================================
|
||||
|
||||
suites = {
|
||||
{
|
||||
-- suite_id = 1,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 13001 },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 2,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 13002 },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 3,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 13003 },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 4,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 13004 },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 5,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { 13005 },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
},
|
||||
{
|
||||
-- suite_id = 6,
|
||||
-- description = ,
|
||||
monsters = { },
|
||||
gadgets = { },
|
||||
regions = { },
|
||||
triggers = { },
|
||||
rand_weight = 100
|
||||
}
|
||||
}
|
||||
|
||||
--================================================================
|
||||
--
|
||||
-- 触发器
|
||||
--
|
||||
--================================================================
|
||||
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"areas": {},
|
||||
"doors": {},
|
||||
"entities": {},
|
||||
"forces": {},
|
||||
"points": {
|
||||
"1": {
|
||||
"$type": "DungeonWayPoint",
|
||||
"alias": "",
|
||||
"areaId": 0,
|
||||
"disableClientTrigger": true,
|
||||
"gadgetId": 70360001,
|
||||
"groupIds": [],
|
||||
"groupLimit": false,
|
||||
"isActive": false,
|
||||
"isBoss": false,
|
||||
"isModelHidden": false,
|
||||
"pointType": "DungeonWayPoint",
|
||||
"pos": {
|
||||
"x": 11.424,
|
||||
"y": 65.864,
|
||||
"z": -71.35536
|
||||
},
|
||||
"rot": {
|
||||
"x": 0.0,
|
||||
"y": 0.0,
|
||||
"z": 0.0
|
||||
},
|
||||
"size": {
|
||||
"x": 5.0,
|
||||
"y": 5.0,
|
||||
"z": 5.0
|
||||
},
|
||||
"tranPos": {
|
||||
"x": 11.4239988,
|
||||
"y": 65.864,
|
||||
"z": -71.35536
|
||||
},
|
||||
"tranRot": {
|
||||
"x": 0.0,
|
||||
"y": 0.0,
|
||||
"z": 0.0
|
||||
},
|
||||
"type": "NORMAL",
|
||||
"unlocked": false
|
||||
}
|
||||
},
|
||||
"transRadius": 0.0
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
[
|
||||
{
|
||||
"area_id": 10150,
|
||||
"points": [
|
||||
{
|
||||
"x": -106.628265,
|
||||
"y": 94.80458
|
||||
},
|
||||
{
|
||||
"x": 80.25726,
|
||||
"y": 91.80997
|
||||
},
|
||||
{
|
||||
"x": 79.24252,
|
||||
"y": 13.1528816
|
||||
},
|
||||
{
|
||||
"x": -105.4106,
|
||||
"y": 9.506355
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
Reference in New Issue
Block a user