24 lines
657 B
Plaintext
24 lines
657 B
Plaintext
|
Scriptname _00E_Ability_ManabarrierActorTrigger extends ObjectReference
|
||
|
|
||
|
import _00E_Ability_ElementalShieldScript
|
||
|
|
||
|
Faction Property PlayerFriendsFaction Auto
|
||
|
ObjectReference Property Manabarrier Auto
|
||
|
Actor Property TriggerActor Auto
|
||
|
Spell Property _00E_Ability_Manabarrier_Push Auto
|
||
|
Actor Property PlayerREF Auto
|
||
|
|
||
|
Event OnTriggerEnter(ObjectReference akActionRef)
|
||
|
|
||
|
akActionRef = TriggerActor
|
||
|
|
||
|
bool Enemy = TriggerActor.IsInFaction(PlayerFriendsFaction)
|
||
|
|
||
|
if Enemy == False
|
||
|
Debug.Notification("Enemy!")
|
||
|
_00E_Ability_Manabarrier_Push.RemoteCast(Manabarrier, PlayerREF, TriggerActor)
|
||
|
elseif Enemy == True
|
||
|
Debug.Notification("Friend!")
|
||
|
|
||
|
endif
|
||
|
EndEvent
|