Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » Finished MUD Scripts
zoli
Newbie


Joined: 12 Oct 2002
Posts: 2
Location: USA

PostPosted: Fri Aug 01, 2003 5:18 pm   

SpellTrans - SMAUG Based MUDs
 
Made and tested with ZMUD 6.4 dont know if it will work with others.
This script should work with any MUD that uses the SMAUG base
language for magic. There are 3 commands that go with it. type
sthelp
for help on them.

#CLASS {SpellTrans}
#ALIAS Translate {#loop %numitems( @magictran) { #var spell %replace( @spell, %item( @magictran, %i), {%subchar( %item( @magicwords, %i), "abcdefghijklmnopqrstuvwxyz", @magicABC)})};#var TransSpell %subchar( @spell, @magicABC, "abcdefghijklmnopqrstuvwxyz");#loop %numitems( @needfixed) {#var transspell %replace( @transspell, %item( @needfixed, %i), %item( @fixed, %i))}}
#ALIAS stadd {#additem NeedFixed %1;#additem Fixed %2}
#ALIAS atconnect {#MXP SpellTrans v@ver by <a "http://zoli.port5.com" "Zoli">Zoli</a>}
#ALIAS sthelp {#echo ~<color red>~</color>;#show ~<color ~#00ffff>-------------------------------------------------~</color>;#show ~<color cyan>SpellTrans~</color> ~<color ~#00ffaa>v~</color>~<color ~#00ff00>@ver~</color> ~<color cyan>by ~</color>~<color blue>Zoli~</color>;#show ~<color ~#00ffff>-------------------------------------------------~</color>;#show ~<color yellow>command stadd~</color> ~<color ~#ff00aa>~[~</color>~<color ~#00ff00>stadd ~<broken word> ~<fixed word>~</color>~<color ~#ff00aa>~]~</color>;#show ~<color yellow>example: ~</color>~<color ~#0000ff>stadd blaad blood~</color>;#show ~<color ~#ffffff>will change every occurance of ~</color>~<color ~#ff00aa>'~</color>~<color ~#00ff00>blaad~</color>~<color ~#ff00aa>' ~</color>~<color white>to ~</color>~<color ~#ff00aa>'~</color>~<color ~#00ff00>blood~</color>~<color ~#ff00aa>'~</color>;#show ~<color ~#00ffff>-------------------------------------------------~</color>;#show ~<color yellow>command stig~</color> ~<color ~#ff00aa>~[~</color>~<color ~#00ff00>stig ~<player of same class>~</color>~<color ~#ff00aa>~]~</color>;#show ~<color yellow>example: ~</color>~<color ~#0000ff>stig zoli~</color>;#show ~<color ~#ffffff>Will not translate what Zoli casts~</color>;#show ~<color ~#ff0000>~[Case Sensitive~]~</color>;#show ~<color ~#00ffff>-------------------------------------------------~</color>;klop;#gag 2}
#ALIAS stig {#additem ignore %1}
#VAR MagicABC {abqezyopuytrwiasdfghjzxnlk} {abqezyopuytrwiasdfghjzxnlk}
#VAR MagicWords {ar|au|bless|blind|bur|cu|de|en|light|lo|mor|move|ness|ning|per|ra|re|son|tect|tri|ven}
#VAR MagicTran {abra|kada|fido|nose|mosa|judi|oculo|unso|dies|hi|zak|sido|lacri|illa|duda|gru|candus|sabru|infra|cula|nofo}
#VAR TransSpell {woodlands sanctuary}
#VAR Spell {xaaeraieg gaiqhjafl} {gtui}
#VAR SPELLER {CASTERSomeoneMSGxaaeraieg gaiqhjabral}
#VAR toSub {Someone utters the words, 'woodlands sanctuary'.}
#VAR NeedFixed {waad|blaad|af |dragan|faurneys|abfect|lacate|bady|isalatian|offinity|farest|farce|ane|armar|ineis|knaw|lare|caracas|wisdam|haly|gnamen|stary|bone|pawer|saul|aak|eleen|chaas|dieine|weapan|lieing|paetry|daminus|cambat|galem|infusian|mafar|unraeel|coneersian|impraeed|embadiment|daar|dimensianal}
#VAR Fixed {wood|blood|of |dragon|journeys|object|locate|body|isolation|affinity|forest|force|one|armor|invis|know|lore|carocos|wisdom|holy|gnomen|story|bane|power|soul|oak|elven|chaos|divine|weapon|living|poetry|dominus|combat|golem|infusion|major|unravel|conversion|improved|embodiment|door|dimensional}
#VAR ignore {}
#VAR ver {1.3}
#TRIGGER {&Speller.Caster utters the words, '&Speller.Msg'~.} {#if !%ismember( @Speller.Caster, @ignore) {#var spell @speller.msg;Translate;#var toSub %concat( %1, " utters the words, '", @TransSpell, "'.");#sub @toSub}}
#CLASS 0
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » Finished MUD Scripts All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net