Difference between revisions of "Proc:Ambient Messages Random"

From WikiName
Jump to: navigation, search
(Created page with " = Overview = The ambient_messages_random procedure allows builders to create custom messages that display on the game hour. These messages have no effect on game play and c...")
 
(Replaced content with " There are two different procedures that use this name that slightly differ: * Proc:Ambient_Messages_Random_(area) * Proc:Ambient_Messages_Random_(room) Catego...")
 
Line 1: Line 1:
  
= Overview =
+
There are two different procedures that use this name that slightly differ:
 
+
* [[Proc:Ambient_Messages_Random_(area)]]
The ambient_messages_random procedure allows builders to create custom messages that display on the game hour.  These messages have no effect on game play and can be used to substitute for custom climate messages or just add to the flavor of a particular area.  This procedure can only be added to areas.
+
* [[Proc:Ambient_Messages_Random_(room)]]
 
 
The builder defines a number of indoor and outdoor messages and each game hour a random roll is done (0 to MAX) and one of the messages is chosen to be displayed.  The number of indoor and outdoor messages may be different.  The "first" indoor message is defined in INDOOR_MSG_0 and the "first" outdoor message is defined in OUTDOOR_MSG_0.
 
 
 
Note that to turn off normal climate messages, you need to set the climate to none via "SETAREA <area #> CLIMATE NONE".  Sky messages such as sunrise and sunset can be disabled via "SETAREA <area #> HIDE_SKY YES".
 
 
 
Here is a list of keys that the procedure will use:
 
 
 
{|class="abilitiestable" border="0" cellspacing="0" cellpadding="0"
 
! Key !! Default !! Description
 
|-
 
| INDOOR_MSG_0
 
| No message.
 
| The message that is displayed to players in the area that are indoors if the random roll results in 0.  Additional messages would be defined in INDOOR_MSG_1, INDOOR_MSG_2, and so on.
 
|-
 
| OUTDOOR_MSG_0
 
| No message.
 
| The message that is displayed to players in the area that are outdoors if the random roll results in 0.  Additional messages would be defined in OUTDOOR_MSG_1, OUTDOOR_MSG_2, and so on.
 
|}
 
 
 
 
 
= Sample =
 
 
 
This sample has 4 random strings (including one empty string).
 
 
 
<pre>
 
setproc area 1 OUTDOOR_MSG_0 Message 0
 
setproc area 1 OUTDOOR_MSG_1 Message 1
 
setproc area 1 OUTDOOR_MSG_3 Message 3
 
setproc area 1 PROC_ENABLED 1
 
 
 
</pre>
 
 
 
Note that the MAX value for outdoor messages is 3, so the random roll will be from 0 to 3.  If 2 is rolled, there is no value, so nothing is displayed.  There are no strings defined for indoor players, so they will never receive a message from this procedure.
 
  
  
 
[[Category:Building]]
 
[[Category:Building]]
[[Category:Area Procedures]]
 

Latest revision as of 20:28, 28 January 2019

There are two different procedures that use this name that slightly differ: