Working Shadow Dancer: if a weak enemy is killed under the Psychosis effect, it's reanimated to fight on player's side for 60 seconds

This commit is contained in:
Eddoursul 2022-08-16 16:42:43 +02:00
parent b13efe44df
commit 7843a8b161
3 changed files with 42 additions and 0 deletions

BIN
Shadow Dancer fix.esp Normal file

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,42 @@
Scriptname _00E_ShadowDancerReviveEffect extends ObjectReference
auto state Init
event OnContainerChanged(ObjectReference akNewContainer, ObjectReference akOldContainer)
GotoState("DoNothing")
if ! akNewContainer
Disable()
Delete()
return
endif
akNewContainer.RemoveItem(_00E_SE_ShadowDancerTokenItem, akNewContainer.GetItemCount(_00E_SE_ShadowDancerTokenItem), true)
Actor aTarget = akNewContainer as Actor
if ! aTarget || aTarget == PlayerRef
return
endif
Utility.wait(2.2)
_00E_SE_ShadowDancerReviveSpell.Cast(PlayerRef, aTarget)
aTarget.SetActorValue("Variable05", 77)
aTarget.SetActorValue("Aggression", 0)
aTarget.SetRelationshipRank(PlayerRef, 3)
endevent
endstate
state DoNothing
endstate
Spell Property _00E_SE_ShadowDancerReviveSpell Auto
Actor Property PlayerRef Auto
MiscObject Property _00E_SE_ShadowDancerTokenItem Auto