Difference between revisions of "NDDynamicSpawners"
(15 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<p style="width:60%;margin: 0 auto">[[NewDawnHome|[Main]]] [[NDServerIndexTemplateMain|[Templates]]]</p> | <p style="width:60%;margin: 0 auto">[[NewDawnHome|[Main]]] [[NDServerIndexTemplateMain|[Templates]]]</p> | ||
− | <p style="color: #DDDD88;font-size: 22px;width:60%;margin: 0 auto">Example Dynamic Spawner Template</p> | + | <p style="color: #DDDD88;font-size: 22px;width:60%;margin: 0 auto">Example Dynamic Spawner Universal Template</p> |
+ | |||
+ | <p style="color: #DDDD88;font-size: 16px;width:60%;margin: 0 auto">Object Variables</p> | ||
+ | <div style="width:60%;margin: 0 auto"> | ||
+ | * spawnRadius - how far away from the dynamic spawner to place objects spawned | ||
+ | * SpawnRateIncrease - | ||
+ | * spawnEffect - effect that plays when objects spawn from the spawner | ||
+ | * spawnMode - choices are Random or Progressive, defaults to Random | ||
+ | * lootMode - choices are NoLoot as your string modifier to stop objects from spawning loot | ||
+ | * progressModifier - | ||
+ | </div> | ||
+ | <p style="color: #DDDD88;font-size: 16px;width:60%;margin: 0 auto">Initializer Variables</p> | ||
+ | <div style="width:60%;margin: 0 auto"> | ||
+ | * TriggerSpawnTeamType - then key entry and team type of the spawned objects. see dynamic_spawner_tables.lua for table entries | ||
+ | * TriggerDeathRadius - | ||
+ | * TriggerChance - this is the chance to trigger the spawner | ||
+ | * SpawnKey - used for the quest system | ||
+ | * HUDVars - when players get in range of the spawner, the hud will appear. this allows you to customize the message [[NDDynamicSpawnerHUDVars|Learn more Here!]] | ||
+ | * SpawnObjVars - | ||
+ | * ProgressMessages - a table containing the progress message for the spawner, this is broadcasted to the players | ||
+ | </div> | ||
<p style="width: 60%;margin: 0 auto">Below is an example of a typical Dynamic Spawner template file for Rebels.</p> | <p style="width: 60%;margin: 0 auto">Below is an example of a typical Dynamic Spawner template file for Rebels.</p> | ||
<div style="width:60%;margin: 0 auto"> | <div style="width:60%;margin: 0 auto"> | ||
<ObjectTemplate> | <ObjectTemplate> | ||
<ClientId>2</ClientId> | <ClientId>2</ClientId> | ||
− | <Name>Dynamic | + | <Name>Dynamic Undead Spawner</Name> |
<ObjectVariableComponent> | <ObjectVariableComponent> | ||
<DoubleVariable Name="spawnRadius">20</DoubleVariable> | <DoubleVariable Name="spawnRadius">20</DoubleVariable> | ||
+ | <StringVariable Name="spawnEffect">none</StringVariable> | ||
<DoubleVariable Name="SpawnRateIncrease">1.03</DoubleVariable> | <DoubleVariable Name="SpawnRateIncrease">1.03</DoubleVariable> | ||
− | |||
<StringVariable Name="spawnMode">Progressive</StringVariable> | <StringVariable Name="spawnMode">Progressive</StringVariable> | ||
− | + | <StringVariable Name="lootMode">Weighted</StringVariable> | |
<DoubleVariable Name="progressModifier">2.5</DoubleVariable> | <DoubleVariable Name="progressModifier">2.5</DoubleVariable> | ||
</ObjectVariableComponent> | </ObjectVariableComponent> | ||
<ScriptEngineComponent> | <ScriptEngineComponent> | ||
− | <LuaModule Name=" | + | <LuaModule Name="dynamic_spawn_controller_universal"> |
<Initializer> | <Initializer> | ||
{ | { | ||
− | TriggerSpawnTeamType = " | + | TriggerSpawnTeamType = "Demon", |
− | + | TriggerDeathRadius = 30, | |
− | + | TriggerChance = 0.1, | |
− | + | TeamType = "Corruption1", | |
+ | SpawnKey = "Corruption1DynamicSpawner", | ||
+ | HUDVars = { | ||
+ | Title = "Pitiful Calamity", | ||
+ | Description = "Kill the demons that are gathering around the pit." | ||
+ | }, | ||
+ | ProgressMessages = { | ||
+ | "A low rumble can be heard coming from the pit.", | ||
+ | nil, | ||
+ | nil, | ||
+ | "A demon emerges from the pit.", | ||
+ | }, | ||
SpawnObjVars = { | SpawnObjVars = { | ||
["AI-StationedLeash"] = false, | ["AI-StationedLeash"] = false, |
Latest revision as of 06:35, 9 December 2019
Example Dynamic Spawner Universal Template
Object Variables
- spawnRadius - how far away from the dynamic spawner to place objects spawned
- SpawnRateIncrease -
- spawnEffect - effect that plays when objects spawn from the spawner
- spawnMode - choices are Random or Progressive, defaults to Random
- lootMode - choices are NoLoot as your string modifier to stop objects from spawning loot
- progressModifier -
Initializer Variables
- TriggerSpawnTeamType - then key entry and team type of the spawned objects. see dynamic_spawner_tables.lua for table entries
- TriggerDeathRadius -
- TriggerChance - this is the chance to trigger the spawner
- SpawnKey - used for the quest system
- HUDVars - when players get in range of the spawner, the hud will appear. this allows you to customize the message Learn more Here!
- SpawnObjVars -
- ProgressMessages - a table containing the progress message for the spawner, this is broadcasted to the players
Below is an example of a typical Dynamic Spawner template file for Rebels.
<ObjectTemplate> <ClientId>2</ClientId> <Name>Dynamic Undead Spawner</Name> <ObjectVariableComponent> <DoubleVariable Name="spawnRadius">20</DoubleVariable> <StringVariable Name="spawnEffect">none</StringVariable> <DoubleVariable Name="SpawnRateIncrease">1.03</DoubleVariable> <StringVariable Name="spawnMode">Progressive</StringVariable> <StringVariable Name="lootMode">Weighted</StringVariable> <DoubleVariable Name="progressModifier">2.5</DoubleVariable> </ObjectVariableComponent> <ScriptEngineComponent> <LuaModule Name="dynamic_spawn_controller_universal"> <Initializer> { TriggerSpawnTeamType = "Demon", TriggerDeathRadius = 30, TriggerChance = 0.1, TeamType = "Corruption1", SpawnKey = "Corruption1DynamicSpawner", HUDVars = { Title = "Pitiful Calamity", Description = "Kill the demons that are gathering around the pit." }, ProgressMessages = { "A low rumble can be heard coming from the pit.", nil, nil, "A demon emerges from the pit.", }, SpawnObjVars = { ["AI-StationedLeash"] = false, ["AI-LeashDistance"] = 20, ["AI-CanWander"] = true, } } </Initializer> </LuaModule> </ScriptEngineComponent> </ObjectTemplate>