Difference between revisions of "Area Special Functions"
Line 650: | Line 650: | ||
|[[trig_time_block]] | |[[trig_time_block]] | ||
|yes | |yes | ||
|Prevents characters from using specified exit during specified (mud) | |Prevents characters from using specified exit during specified (mud) hours | ||
|} | |} | ||
[[Category:Area Development]] | [[Category:Area Development]] |
Revision as of 12:43, 27 December 2011
The following special functions are available to area writers.
All use of special functions should be approved by the Area Coordinator prior to use. If code modifications are necessary (e.g. a special function is not generic), the Area Coordinator will also discuss the use of the special function with a coder.
Mob Functions
Mob Special Functions are defined in the #SPECIALS section of an area file.
Archmob
Function Name | Generic | Description |
---|---|---|
init_mage | yes | Create an arch-mage archmob |
init_priest | yes | Create archmob cleric |
init_shaman | yes | Create archmob shaman |
Combat
Function Name | Generic | Description |
---|---|---|
spec_breath_acid | yes | Acid breath |
spec_breath_any | yes | Random dragon breath |
spec_breath_fire | yes | Fire breath |
spec_breath_frost | yes | Frost breath |
spec_breath_gas | yes | Gas breath |
spec_cast_cleric | yes | Cast cleric spells |
spec_cast_mage | yes | Cast mage spells |
spec_cast_shaman | yes | Cast shaman spells |
spec_cast_undead | yes | Cast spells associated with undead |
spec_corrosion | yes | Cast acid blast and other spells |
spec_demon | yes | Demon casting spec |
spec_demon_lord | yes | Demon lord casting spec |
spec_fight_dirty | yes | Dirty fighting |
spec_fire_demon | yes | Fire demon casting spec |
spec_guardian_demon | yes | Guardian demon casting spec |
spec_mind_affects | yes | Cast mind affect spells |
spec_one_spell | yes | Cast a single spell, as set with mob 'O' flag |
spec_pestilence | yes | Cast cause disease and other spells |
spec_poison | yes | Poison bites |
spec_poison_sting | yes | Poison sting |
spec_shadow_demon | yes | Shadow demon casting spec |
spec_storm_demon | yes | Storm demon casting spec |
Miscellaneous
Function Name | Generic | Description |
---|---|---|
spec_fido | yes | Eat animal corpses. |
spec_grudge | yes | Will attack PC in room if PC previously attacked mob. |
spec_guard | no | Racial guards. |
spec_howl | yes | Howling mob. |
spec_immediate_relay | yes | Causes mob to immediately return to its start room. |
spec_janitor | yes | Pick up trash. |
spec_no_hunt | yes | Mob will not use standard hunting. |
spec_respawn | yes | Will cause a new instance of a mob to be created immediately upon death of the mob. |
spec_sleeping_dragon | no | Provides spec_breath_acid for combat. Awakens mob, that then ROARS. Puts dragon asleep again once it thinks it's alone. |
spec_teleport_on_load | yes | Teleports mob to random location immediately upon repop. |
spec_thief | yes | Mob steals gold. |
Mob Extended Functions
Mob Extended Special Functions are defined in the #SPECIALS section of an area file.
Miscellaneous
Function Name | Generic | Description |
---|---|---|
spec_act_on_give | yes | Upon giving mob an item of a specific vnum, perform specified action, such as giving PC an item in return, or transfering PC to specified room with optional action description (must be coded if custom description needed) |
In Room
Room special functions are defined in the #RSPECS section of the area file.
Damage
Function Name | Generic | Description |
---|---|---|
spec_cliff_fall | yes | Falling down cliff face |
spec_fire_bath | yes | Engulfing flames |
spec_freefall_one | yes | Fall into room in down direction; spec_long_fall invoked |
spec_gas_chamber | yes | Choke and gag within room |
spec_mildgas | yes | Choke and gag within room (less damage than spec_gas_chamber) |
spec_steam_bath | yes | geyser of hot water and steam |
Doors
Function Name | Generic | Description |
---|---|---|
spec_lock_down | yes | Shuts and locks door down |
spec_lock_east | yes | Shuts and locks door to east |
spec_lock_north | yes | Shuts and locks door to north |
spec_lock_south | yes | Shuts and locks door to south |
spec_lock_up | yes | Shuts and locks door up |
spec_lock_west | yes | Shuts and locks door to west |
spec_seal_exits | yes | Closes all doors |
spec_shut_down | yes | Shuts door down |
spec_shut_east | yes | Shuts door to east |
spec_shut_north | yes | Shuts door to north |
spec_shut_south | yes | Shuts door to south |
spec_shut_up | yes | Shuts door up |
spec_shut_west | yes | Shuts door to west |
Miscellaneous
Function Name | Generic | Description |
---|---|---|
spec_crumble_floor | yes | Heavy characters fall through floor to room below |
spec_wind_tunnel | yes | Room is windy; can blow away items |
Movement
Function Name | Generic | Description |
---|---|---|
spec_aircurrent_down | yes | Wind. Assumes down exit |
spec_aircurrent_east | yes | Wind. Assumes east exit |
spec_aircurrent_north | yes | Wind. Assumes north exit |
spec_aircurrent_south | yes | Wind. Assumes south exit |
spec_aircurrent_up | yes | Wind. Assumes up exit |
spec_aircurrent_west | yes | Wind. Assumes west exit |
spec_airfork_ne | yes | Air current to north or east |
spec_airfork_nw | yes | Air current to north or west |
spec_airfork_se | yes | Air current to south or east |
spec_airfork_sw | yes | Air current to south or west |
spec_current_down | yes | Assumes down exit |
spec_current_east | yes | Assumes water and east exit |
spec_current_north | yes | Assumes water and north exit |
spec_current_south | yes | Assumes water and south exit |
spec_current_up | yes | Assumes up exit |
spec_current_west | yes | Assumes water and west exit |
spec_fork_ne | yes | Current to north or east |
spec_fork_nw | yes | Current to north or west |
spec_fork_se | yes | Current to south or east |
spec_fork_sw | yes | Current to south or west |
spec_oceancurrent_down | yes | Assumes down exit |
spec_oceancurrent_east | yes | Assumes east exit |
spec_oceancurrent_north | yes | Assumes north exit |
spec_oceancurrent_south | yes | Assumes south exit |
spec_oceancurrent_up | yes | Assumes up exit |
spec_oceancurrent_west | yes | Assumes west exit |
spec_oceanfork_ne | yes | |
spec_oceanfork_nw | yes | |
spec_oceanfork_se | yes | |
spec_oceanfork_sw | yes | |
spec_tide_ew | yes | |
spec_tide_ns | yes | |
spec_waterfall_east | yes | spec_current_east + spec_long_fall |
spec_waterfall_north | yes | spec_current_north + spec_long_fall |
spec_waterfall_south | yes | spec_current_south + spec_long_fall |
spec_waterfall_west | yes | spec_current_west + spec_long_fall |
Room Extended Functions
Door
Function Name | Generic | Description |
---|---|---|
spec_check_door_open | yes | Checks a stat attribute prior to opening door |
Trigger After Move
(Exit) triggers are defined in the #TRIGGERS section of the area file.
Damage
Function Name | Generic | Description |
---|---|---|
spec_cavein | no | Text assumes PC in a tunnel |
spec_crack_head | yes | Head damage |
spec_long_fall | yes | Damage character (can be any direction) |
spec_medium_fall | yes | Damage character (can be any direction) |
spec_short_fall | no | Minor damage -- text assumes a fall |
Door
Function Name | Generic | Description |
---|---|---|
spec_shut_door | yes | Closes all doors. Requires a door of name "door" in the room. |
Miscellaneous
Function Name | Generic | Description |
---|---|---|
spec_splash | yes | Assumes water. Splash size based on weight of ch |
spec_teleporter | Teleport if holding the correct key (Landru). Requires code changes. |
Trigger Before Move
(Exit) triggers are defined in the #TRIGGERS section of the area file.
Alignment
Function Name | Generic | Description |
---|---|---|
spec_evil_only | yes | Blocks non-evil-aligned PCs from going specific direction |
spec_good_only | yes | Blocks non-good-aligned PCs from going specific direction |
spec_neutral_only | yes | Blocks aligned PCs from going specific direction |
Class
Function Name | Generic | Description |
---|---|---|
spec_bard_only | yes | Allow only bard to pass |
spec_cleric_only | yes | Allow only clerics and OMs to pass |
spec_mage_only | yes | Allow only mages and bards to pass |
spec_ranger_only | yes | Allow only ranger to pass |
spec_shaman_only | yes | Allow only shaman to pass |
spec_thief_only | yes | Allow only thief, thug and bard to pass |
spec_thug_only | yes | Allow only thug to pass |
spec_warrior_only | yes | Allow only warrior, ranger, and bard to pass |
spec_warrior_only2 | yes | Allow only warrior and bard to pass |
Level
Function Name | Generic | Description |
---|---|---|
spec_mudschool_newbies | yes | Allow only those less than 5th level to pass |
Miscellaneous
Function Name | Generic | Description |
---|---|---|
spec_guild_entrance | yes | Transports character to guild |
spec_vortex_entry | yes | Creates vortex portal in specified direction |
spec_vortex_exit | no | Creates vortex exit in specified direction |
Movement
Function Name | Generic | Description |
---|---|---|
spec_fallin | yes | Fall into room in 'down' direction (no damage) |
Extended Trigger Before Move
(Exit) triggers are defined in the #TRIGGERS section of the area file.
Exit Blocks
Function Name | Generic | Description |
---|---|---|
trig_block_heathen | yes | Allow only followers (and optionally UA and/or mobs) through exit |
trig_sentinel_mob | yes | Allow only characters holding an item of specific vnum through exit |
trig_time_block | yes | Prevents characters from using specified exit during specified (mud) hours |