User Tools

Site Tools


building:spawn:sinfar_system

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
building:spawn:sinfar_system [2019/03/10 06:34]
Mavrixio
building:spawn:sinfar_system [2019/03/10 18:20]
Mavrixio
Line 3: Line 3:
 This system is technically unlimited: it can support any object type, any number of object, spawn condition or spawn location... but for now it is very limited. If you need an extra feature, please request it instead of making your own system. This system is technically unlimited: it can support any object type, any number of object, spawn condition or spawn location... but for now it is very limited. If you need an extra feature, please request it instead of making your own system.
  
-===== Spawning ​a Single Object at a Specific Location. ​=====+===== Spawning ​Events ​===== 
 +Objects will spawn during a scripted area event called "​WokeUp"​ ([[https://​nwn.sinfar.net/​res_nss_edit.php?​name=msds_wokeuparea|msds_wokeuparea]]) and despawn during an area event called "Area Suspend"​ ([[https://​nwn.sinfar.net/​res_nss_edit.php?​name=msds_suspendarea|msds_suspendarea]]). Both events can be registered on a specific area with the following variable event: 
 +  * **EVENT_SUSPEND** \\ This event happens when no player has been in the area for a number of second define by the variable MSDS_SUSPEND_AREA_TIMER here: [[https://​nwn.sinfar.net/​res_nss_edit.php?​name=msds_include|msds_include]]. 
 +  * **EVENT_WOKEUP** \\ This event happens when a player enter an area after that is has been suspended.
  
 +
 +===== Spawning a Single Object at a Specific Location. =====
   - Create a waypoint at the specific location \\   - Create a waypoint at the specific location \\
-  - Set the tag of the waypoint to: SPAWN_<​type letter>​_<​object blueprint>,​ where <type letter> is "​C"​ or "​P"​ and <object blueprint>​ is the ResRef of the placeable or creature that you want to spawn. \\ For example, the tag: "​SPAWN_C_MOB_WOLF"​ will spawn this cute wolf: [[https://​nwn.sinfar.net/​res_edit.php?​name=mob_wolf.utc|mob_wolf.utc]]:​ \\ {{:​building:​spawn:​sinfar_system_20190310-004836.png?​600}}+  - Set the tag of the waypoint to: **SPAWN_<​type letter>​_<​object blueprint>​**, where <type letter> is "​C" ​for a creature ​or "​P" ​for a placeable ​and <object blueprint>​ is the ResRef of the placeable or creature that you want to spawn. \\ For example, the tag: "​SPAWN_C_MOB_WOLF"​ will spawn this cute wolf: [[https://​nwn.sinfar.net/​res_edit.php?​name=mob_wolf.utc|mob_wolf.utc]]:​ \\ {{:​building:​spawn:​sinfar_system_20190310-004836.png?​400}}
  
 ===== Spawning Multiple Objects Inside a Determined Zone  ===== ===== Spawning Multiple Objects Inside a Determined Zone  =====
- 
   - Create a trigger and define the zone with it.   - Create a trigger and define the zone with it.
-  - Set the tag of the trigger to SPAWN_C_<type letter>_<object blueprint>​. \\ For now only creatures are supported. +  - Set the tag of the trigger to **SPAWN_C_<​object blueprint>​**. \\ For now only creatures are supported. 
-  - Add the SPAWN_MIN and SPAWN_MAX integer variables on the trigger to define the minimum and maximum number of creature that should be spawned. Everytime that the area is "​reset",​ there will be a random number between those 2  values, of creatures spawned: {{:​building:​spawn:​sinfar_system_20190310-013418.png?​400}}+  - Add the SPAWN_MIN and SPAWN_MAX integer variables on the trigger to define the minimum and maximum number of creature that should be spawned. Everytime that the area is "​reset",​ there will be a random number between those 2  values, of creatures spawned: {{:​building:​spawn:​sinfar_system_20190310-013418.png?​600}} 
 + 
 +===== Spawning Conditions ===== 
 +You can control when the objects will spawn with the following variables:​ 
 +^Variable Name^Type^Description^ 
 +|SPAWN_CHANCE|Integer|Percent of chance that the object(s) spawn| 
 +|SPAWN_TIME|Integer|1 = Spawn only during the day \\ 2 = Spawn only during the night| 
 +|SPAWN_FREQUENCY|Integer|Minimum number of seconds after which to re-spawn the objects. By default objects will always (try) to re-spawn in the area WOKEUP event. This variable will prevent the objects to spawn if the event is triggered before the defined number of seconds but the objects will still only spawn during a WOKEUP event.| 
 +|SPAWN_SCENARIO|Integer|The objects will only spawn when the SPAWN_SCENARIO variable on the area has the same value.| 
 + 
 +For example, with the following variables:​\\ 
 +{{:​building:​spawn:​sinfar_system_20190310-141830.png}}\\ 
 +Objects will only have 30% of chance to spawn (0 or between 2 and 5 objects), during the day, if the area has the SPAWN_SCENARIO variable set to 1 and if the objects didn't spawn in the last hour.
  
building/spawn/sinfar_system.txt · Last modified: 2019/03/10 18:20 by Mavrixio

phpBB Appliance - Powered by TurnKey Linux