Difference between revisions of "LeverPull(Script)"

From CoffeeMud Wiki
Jump to navigation Jump to search
 
Line 91: Line 91:
 
=Notes=
 
=Notes=
 
*To avoid thieves picking this lock, you may wish to make the door level exceedingly high.
 
*To avoid thieves picking this lock, you may wish to make the door level exceedingly high.
 +
 +
[[Category:Orleron(Scripter)]]

Latest revision as of 14:55, 17 September 2024

CoffeeMUD
Administrator                                                  Builder                                                              Player
=CoffeeMUD Builder Information=
Basics Praetor     Player Support     Commands     Zapper Masks Advanced Races     Classes     Abilities     Socials     Scripting    
Building Behaviors     Properties     Areas     Rooms     Exits     Items     Mobs Systems Achievements     Crafting     Help Info     Ships     Planes of Existence     Quests     Triumphs    

Lever Pull

This script requires the player to pull 4 separate levers to unlock a specific door.

Lever Pull


act_prog pulls
mpsetvar $a room $d

if VAR($a room == 'Southwestern Chamber of The Triple Coin Temple')
mploadvar $a swlever
if VAR($a swlever == '0')
mpsetvar $a swlever 1
mpsavevar $a swlever
mpecho *click*
mpecho Mechanical noises emanate from the floor.
else
mpecho This lever is already locked into the open position.
endif
endif

if VAR($a room == 'Northwestern Chamber of The Triple Coin Temple')
mploadvar $a nwlever
if VAR($a nwlever == '0')
mpsetvar $a nwlever 1
mpsavevar $a nwlever
mpecho *click*
mpecho Mechanical noises emanate from the floor.
else
mpecho This lever is already locked into the open position.
endif
endif

if VAR($a room == 'Southeastern Chamber of The Triple Coin Temple')
mploadvar $a selever
if VAR($a selever == '0')
mpsetvar $a selever 1
mpsavevar $a selever
mpecho *click*
mpecho Mechanical noises emanate from the floor.
else
mpecho This lever is already locked into the open position.
endif
endif

if VAR($a room == 'Northeastern Chamber of The Triple Coin Temple')
mploadvar $a nelever
if VAR($a nelever == '0')
mpsetvar $a nelever 1
mpsavevar $a nelever
mpecho *click*
mpecho Mechanical noises emanate from the floor.
else
mpecho This lever is already locked into the open position.
endif
endif

mploadvar $a swlever
mploadvar $a selever
mploadvar $a nelever
mploadvar $a nwlever

if VAR($a swlever == '1') and VAR($a selever == '1') and VAR($a nelever == '1') and VAR($a nwlever == '1')
mploadvar $a vaultopened

if VAR($a vaultopened == '')
mpecho Sounds of gears rumbling and metal sliding come from somewhere nearby.
mpat TripleCoinTemple#12 mpunlock circular
mpsetvar $a vaultopened 1
mpsavevar $a vaultopened
mpalarm 400 mpsetvar $a swlever 0
mpalarm 400 mpsetvar $a selever 0
mpalarm 400 mpsetvar $a nelever 0
mpalarm 400 mpsetvar $a nwlever 0
mpalarm 400 mpsetvar $a vaultopened ''
mpalarm 400 mpsavevar $a swlever
mpalarm 400 mpsavevar $a selever
mpalarm 400 mpsavevar $a nelever
mpalarm 400 mpsavevar $a nwlever
mpalarm 400 mpsavevar $a vaultopened
mpalarm 400 mpat TripleCoinTemple#12 mplock circular
endif
endif

~

Notes

  • To avoid thieves picking this lock, you may wish to make the door level exceedingly high.