User Tools

Site Tools


zone

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
zone [2025/04/03 09:19] justinzone [2025/04/03 13:57] (current) justin
Line 1: Line 1:
-=====Zones======+======Zones======
 ---- ----
  
Line 23: Line 23:
 ====Scripting==== ====Scripting====
 From a scripting perspective, there are several Bauxite functions related to the management of zones. Below is a list of these new functions that are available to use: From a scripting perspective, there are several Bauxite functions related to the management of zones. Below is a list of these new functions that are available to use:
-  * **[[Add Zone]]**: Adds a new zone to the current [[map]], with parameters for zone name, passability, position, width, depth, and height. The width, depth, and height are measured in [[voxel|voxels]]. For example, add_zone("toxic_zone", true, coord[0, 0, 0], 64, 64, 16) will add a passable zone named "toxic_zone" at [[coordinate]] (0, 0, 0) with dimensions of 64 x 64 x 16 [[voxel|voxels]]. +  * **[[Add Zone]]**: Adds a new zone to the current [[map]], with parameters for zone name, passability, position, width, depth, and height. The width, depth, and height are measured in [[voxel|voxels]]. For example, **add_zone("toxic_zone", true, coord[0, 0, 0], 64, 64, 16)** will add a passable zone named "toxic_zone" at [[coordinate]] (0, 0, 0) with dimensions of 64 x 64 x 16 [[voxel|voxels]]. 
-  * **[[Disable Zone]]**: Disables a zone in the current [[map]], e.g. disable_zone("toxic_zone"). When a zone is disabled, scripts for that zone will not trigger. If the zone is impassable, it won't block the player when disabled. +  * **[[Disable Zone]]**: Disables a zone in the current [[map]], e.g. **disable_zone("toxic_zone")**. When a zone is disabled, scripts for that zone will not trigger. If the zone is impassable, it won't block the player when disabled. 
-  * **[[Enable Zone]]**: Enables a zone that was previously disabled via the [[Disable Zone]] function, e.g. enable_zone("toxic_zone"). +  * **[[Enable Zone]]**: Enables a zone that was previously disabled via the [[Disable Zone]] function, e.g. **enable_zone("toxic_zone")**
-  * **[[Remove Zone]]**: Removes a zone from the current [[map]], e.g. remove_zone("toxic_zone"). +  * **[[Remove Zone]]**: Removes a zone from the current [[map]], e.g. **remove_zone("toxic_zone")**
-  * **[[Set Zone Script]]**: Modifies a zone's [[script]], with trigger options of CHARACTER_ENTER and CHARACTER_EXIT for passable zones and CHARACTER_COLLIDE for impassable zones. For example, set_zone_script("toxic_zone", "apply_poison_status", CHARACTER_ENTER) will cause the "apply_poison_status" script to be triggered whenever a [[character]] enters that zone.+  * **[[Set Zone Script]]**: Modifies a zone's [[script]], with trigger options of CHARACTER_ENTER and CHARACTER_EXIT for passable zones and CHARACTER_COLLIDE for impassable zones. For example, **set_zone_script("toxic_zone", "apply_poison_status", CHARACTER_ENTER)** will cause the "apply_poison_status" script to be triggered whenever a [[character]] enters that zone.
  
 +**Bauxite Examples:**
 <code bauxite> <code bauxite>
 add_zone("toxic_zone", true, coord[0, 0, 0], 64, 64, 16); add_zone("toxic_zone", true, coord[0, 0, 0], 64, 64, 16);
zone.1743697150.txt.gz · Last modified: 2025/04/03 09:19 by justin