scriptName
DefaultCastAtLinkOnTriggerSCRIPT extends objectReference
{Configurable Custom
Script. Be default: when triggered, it
will cast the spell from a linked ref at the triggering actor}
Message Property
Effect Auto ; uncheck Message Box
bool property playerOnly auto
{if true, only works on the player}
bool property doOnce auto
{fire multiple times?}
float property delayBetween auto
{seconds to wait between shots. Only relevant if doOnce == false}
spell property mySpell auto
{spell to cast onTriggerEnter}
auto STATE active
EVENT
onTriggerEnter(ObjectReference actronaut)
if
playerOnly == true && actronaut == game.getPlayer() || playerOnly ==
false
mySpell.Cast(getLinkedRef(),
actronaut)
Effect.Show()
gotoState
("inactive") ; don't cast
subsequent spells until told to do so
if
doOnce == true
;
and don't come back!
else
utility.wait(delayBetween)
gotoState("active")
endif
endif
endEVENT
endSTATE
STATE inactive
;
nothing happens here.
endSTATE
; defaultCastAtLinkOnTriggerSCRIPT
This script will cast
the specified spell from the trigger's linked ref at the triggering actor. This
only works for triggerboxes! I.e. a trap that casts spells at you from a stone
(linked ref, any static item) when you enter the area.
If doOnce is not
checked it will cast multiple times or every time you enter it.
Add a static item in the pool (item like a block
in the perimeter of the pool or stone parts) with a reference on top, on the
Trigger Box select Linked Ref with the Cell it appears in and the Reference
of the object on the perimeter of the pool to cast the spell from.
This is used for a Healing
Pool effect. (Kemt Mod by M7).
M7 2017.
No comments:
Post a Comment