home » builders » builder's lessons » level trigger flags
Lever trigger flags
The following triggers can be used on levers and buttons. For some of the triggers that open doors, you will need to make sure that you have TRIG_DOOR utilised. You can have more than one trigger on a lever or button. Just seperate them with a pipe | . Buttons should have the TRIG_UP and TRIG_AUTORETURN triggers set on them. Anything that is only meant to be pulled should have the TRIG_AUTORETURN trigger set.
TRIGGER | BIT VECTOR | COMMENT |
TRIG_NONE | 0 | Use 0 when there are no triggers |
TRIG_UP | 1 | Lever starts out in the up position |
TRIG_UNLOCK | 2 | This will set a newly created exit or existing one to unlocked |
TRIG_LOCK | 4 | This will set a newly crated exit or exiting one to locked |
TRIG_D_NORTH | 8 | Sets the exit to open to the north |
TRIG_D_SOUTH | 16 | Sets the exit to open to the south |
TRIG_D_EAST | 32 | Sets the exit to open to the east |
TRIG_D_WEST | 64 | Sets the exit to open to the west |
TRIG_D_UP | 128 | Sets the exit open up |
TRIG_D_DOWN | 256 | Sets the exit to open down |
TRIG_DOOR | 512 | This is required to make any of the triggers utilising exits work |
TRIG_CONTAINER | 1024 | This trigger is not used |
TRIG_OPEN | 2048 | This trigger opens any door that is generated with other triggers |
TRIG_CLOSE | 4096 | This trigger closes any door that is generated with other exit triggers |
TRIG_PASSAGE | 8192 | This trigger is needed to create a new exit. |
TRIG_OLOAD | 16384 | Loads up an object. Value1 is the Room. Value2 is the mob number. |
TRIG_MLOAD | 32768 | Loads up a mobile. Value1 is the Room. Value2 is the mob number. |
TRIG_TELEPORT | 65536 | Teleports lever puller or button pusher to set vnum |
TRIG_TELEPORTALL | 131072 | Teleports everyone in the room to set vnum |
TRIG_TELEPORTPLUS | 262144 | This trigger is not used |
TRIG_DEATH | 524288 | This trigger is not used |
TRIG_CAST | 1048576 | Casts a spell on lever/button pusher. Value1 needs to contain the spell number |
TRIG_FAKEBLADE | 2097152 | This trigger is not used |
TRIG_RANDFOUR | 4194304 | Randomises the existing exits of the vnum in value1 to NSEW. It will not add new exits, just change where the existing ones go. |
TRIG_RANDSIX | 8388608 | Randomises the existing exits of the vnum in value1 to NSEWDU. It will not add new exits, just change where the existing ones go. |
TRIG_TRAPDOOR | 16777216 | This trigger is not used |
TRIG_ANOTHEROOM | 33554432 | This trigger is not used |
TRIG_USEDIAL | 67108864 | This trigger is not used |
TRIG_ABSOLUTEVNUM | 134217728 | This trigger is not used |
TRIG_SHOWROOMDESC | 268435456 | Required in order to allow the teleported to know that they have been teleported |
TRIG_AUTORETURN | 536870912 | This will make the trigger go back to the original position |
TRIG_NOTRAP | 536870912 | Will bypass any traps on the exit if used. It allows for a trap to be on a door that will not trigger if the lever is used to open it instead of other means. |