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
RobMacAF
Apprentice


Joined: 09 Jun 2002
Posts: 186
Location: USA

PostPosted: Sat Jan 11, 2003 3:50 pm   

Capturing input from the next line
 
Ok, I have decided to change my thinking. I want to make a trigger that will do this:

Etrina's injuries include...
Wounds to the HEAD:
Fresh External: light scratches -- negligible
Scars External: slight discoloration -- negligible
Scars Internal: minor internal scarring -- negligible
Wounds to the NECK:
Scars External: slight discoloration -- negligible
Fresh Internal: slightly tender -- insignificant
Scars Internal: minor internal scarring -- insignificant

The Trigger is injuries include
Then I want it to check for Wounds to the Head:
if it is there I want it to set HeadWounds to 1
It then goes down one line and checks for Fresh External if that is there it set HeadFresh to one.
Then it checks for Scars External if it finds it then it sets HeadScars to 1
Then it checks for Fresh Internal if it finds that then it sets HeadInternal to 1
Then it checks for Scars Internal if it finds that then it sets HeadInternalScars to 1

If it doesn't find one or more of those then it will set that Var to 0

then it looks for Wounds to the NECK:
if that is there then it looks for the same variables as for the head but with NeckScar, NeckInternal, etc.

It would then go through and do this with
Wounds to the HEAD:
Wounds to the NECK:
Wounds to the RIGHT ARM:
Wounds to the LEFT ARM:
Wounds to the RIGHT LEG:
Wounds to the LEFT LEG:
Wounds to the RIGHT HAND:
Wounds to the LEFT HAND:
Wounds to the CHEST:
Wounds to the ABDOMEN:
Wounds to the BACK:
Wounds to the RIGHT EYE:
Wounds to the LEFT EYE:
Wounds to the SKIN:

It would check through all those in order and look for each of those variables.
When it is done it would then start another thing that would open a WOUNDS window
And say Head-then it would list any of the head variables that got a 1 next to it
And then Neck-etc
etc-etc
etc-etc

How hard would this be to do? I was thinking making a trigger for the head, it checks for all the variables for the head, then after it looks for all 4 it fires the neck trigger which then looks for them which after looking for its 4 will then fire the next one, etc, etc
Reply with quote
Charbal
GURU


Joined: 15 Jun 2001
Posts: 654
Location: USA

PostPosted: Sat Jan 11, 2003 6:17 pm   
 
This should work as the start of a script for you:

(untested)

#TRIGGER {Wounds to the (*):} {#VAR BodyPart %replace("%1", " ", "");#VAR @{BodyPart}Wounds 1;#VAR @{BodyPart}Fresh 0;#VAR @{BodyPart}Scars 0;#VAR @{BodyPart}Internal 0;#VAR @{BodyPart}InternalScars 0;#WINDOW Wounds "%1 Wounds:"}
#TRIGGER {Fresh External:} {#VAR @{BodyPart}Fresh 1;#WINDOW Wounds "Fresh External"}
#TRIGGER {Scars External:} {#VAR @{BodyPart}Scars 1;#WINDOW Wounds "Scars"}
#TRIGGER {Fresh Internal:} {#VAR @{BodyPart}Internal 1;#WINDOW Wounds "Internal"}
#TRIGGER {Scars Internal:} {#VAR @{BodyPart}InternalScars 1;#WINDOW Wounds "Internal Scars"}

It will store all the relevant information in variables without spaces in the names (for example, LEFTEYEWounds or RIGHTHANDInternalScars). It will also put things in the Wounds window as it captures them (instead of looping through the variables afterwards).



 - Charbal
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