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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
GelRoos
Beginner


Joined: 12 Jun 2002
Posts: 13
Location: Canada

PostPosted: Sat Mar 08, 2003 5:04 pm   

Scripting help
 
Hey all,
This is my first time ever trying to write an advance script and I am kinda stuck on how to do something heres what i would like to do


Existing script:
brew heal
hold sceptre
give heal Togread
trance

I want to add and if then checky thingy to it right after the brew to determine if they passed or failed the brewing

brew heal
#if "You failed." then brew heal
#if "You brewed a heal." then continue with rest of script.
hold sceptre
give heal gelroos
trance

Not sure how to implement that hope someone can help me.

GelRoos


dam mobs always repoping
Reply with quote
megamog75
Enchanter


Joined: 20 Nov 2002
Posts: 627
Location: USA

PostPosted: Sat Mar 08, 2003 8:19 pm   
 
congrats on your first big script you have got it already!!!!!
look at what you wrote:
_____________________________________________
#if "You failed." then brew heal
#if "You brewed a heal." then continue with rest of script.
_____________________________________________
ok #IF works like this:
#if @var=anything {yes} {no}optional
so in your above statment
your script goes up to "brew heal" and stops
then you need a couple of #trig to finish it.
#trig {You failed.} {#var brew 1}
#trig {You brewed a heal.} {#var brew 0}
make a @var named brew
#alias brewagain {#if @brew=1 {brew heal;brewagain} {hold sceptre;give heal Togread;trance}}

then in your script when "brew heal" comes up put this as the next thing:
brewagain

this should work nicly for you
let me know if I can help futher....

megamog75
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion 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