Cast Facing (script)

From Elanthipedia
Revision as of 08:11, 18 March 2009 by Maintenance script (talk | contribs) (Created page with 'Category:Scripts This script determines what you are facing and casts your prepped spell on that target. It can handle PCs as well as critters. This script is Stormfront o...')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


This script determines what you are facing and casts your prepped spell on that target.

It can handle PCs as well as critters.

This script is Stormfront only.

setvariable castTarget 
tPreamble:
matchre tLoopCritter /^You \(.*\) are (facing|behind) a /
matchre tLoopPerson /^You \(.*\) are (facing|behind) /
put assess
matchwait

tLoopPerson:
setvariable tokenEnd tEnd
goto tLoop

tLoopCritter:
setvariable tokenEnd tsp
goto tLoop


tLoop:
matchre tA /^A/i
matchre tB /^B/i
matchre tC /^C/i
matchre tD /^D/i
matchre tE /^E/i
matchre tF /^F/i
matchre tG /^G/i
matchre tH /^H/i
matchre tI /^I/i
matchre tJ /^J/i
matchre tK /^K/i
matchre tL /^L/i
matchre tM /^M/i
matchre tN /^N/i
matchre tO /^O/i
matchre tP /^P/i
matchre tQ /^Q/i
matchre tR /^R/i
matchre tS /^S/i
matchre tT /^T/i
matchre tU /^U/i
matchre tV /^V/i
matchre tW /^W/i
matchre tX /^X/i
matchre tY /^Y/i
matchre tZ /^Z/i
matchre %tokenEnd% /^\s/
matchre tapo /^'/
matchre tdash /^-/
matchre tparens /^\(/
matchwait

tsp:
setvariable castTarget %castTarget% 
goto tLoop

tapo:
setvariable castTarget %castTarget%'
goto tLoop

tdash:
setvariable castTarget %castTarget%-
goto tLoop

tA:
setvariable castTarget %castTarget%a
goto tLoop

tB:
setvariable castTarget %castTarget%b
goto tLoop

tC:
setvariable castTarget %castTarget%c
goto tLoop

tD:
setvariable castTarget %castTarget%d
goto tLoop

tE:
setvariable castTarget %castTarget%e
goto tLoop

tF:
setvariable castTarget %castTarget%f
goto tLoop

tG:
setvariable castTarget %castTarget%g
goto tLoop

tH:
setvariable castTarget %castTarget%h
goto tLoop

tI:
setvariable castTarget %castTarget%i
goto tLoop

tJ:
setvariable castTarget %castTarget%j
goto tLoop

tK:
setvariable castTarget %castTarget%k
goto tLoop

tL:
setvariable castTarget %castTarget%l
goto tLoop

tM:
setvariable castTarget %castTarget%m
goto tLoop

tN:
setvariable castTarget %castTarget%n
goto tLoop

tO:
setvariable castTarget %castTarget%o
goto tLoop

tP:
setvariable castTarget %castTarget%p
goto tLoop

tQ:
setvariable castTarget %castTarget%q
goto tLoop

tR:
setvariable castTarget %castTarget%r
goto tLoop

tS:
setvariable castTarget %castTarget%s
goto tLoop

tT:
setvariable castTarget %castTarget%t
goto tLoop

tU:
setvariable castTarget %castTarget%u
goto tLoop

tV:
setvariable castTarget %castTarget%v
goto tLoop

tW:
setvariable castTarget %castTarget%w
goto tLoop

tX:
setvariable castTarget %castTarget%x
goto tLoop

tY:
setvariable castTarget %castTarget%y
goto tLoop

tZ:
setvariable castTarget %castTarget%z
goto tLoop

tparens:
matchre tTenth /^10/
matchre tNinth /^9/
matchre tEighth /^8/
matchre tSeventh /^7/
matchre tSixth /^6/
matchre tFifth /^5/
matchre tFourth /^4/
matchre tThird /^3/
matchre tSecond /^2/
matchre tFirst /^1/
matchwait

tFirst:
setvariable castTarget first %castTarget%
goto tEnd
tSecond:
setvariable castTarget second %castTarget%
goto tEnd
tThird:
setvariable castTarget third %castTarget%
goto tEnd
tFourth:
setvariable castTarget fourth %castTarget%
goto tEnd
tFifth:
setvariable castTarget fifth %castTarget%
goto tEnd
tSixth:
setvariable castTarget sixth %castTarget%
goto tEnd
tSeventh:
setvariable castTarget seventh %castTarget%
goto tEnd
tEighth:
setvariable castTarget eighth %castTarget%
goto tEnd
tNinth:
setvariable castTarget ninth %castTarget%
goto tEnd
tTenth:
setvariable castTarget tenth %castTarget%
goto tEnd


tEnd:
put cast %castTarget%