Removed SKSE dependency from Ambrosia

This commit is contained in:
Eddoursul 2024-02-10 09:10:30 +01:00
parent 09a3cb142c
commit 4a4b550cb9
3 changed files with 18 additions and 16 deletions

BIN
Ambrosia vanilla.esp Normal file

Binary file not shown.

Binary file not shown.

View File

@ -1,29 +1,31 @@
Scriptname _00E_AmbrosiaEffect extends activemagiceffect
Event OnEffectStart(Actor akTarget, Actor akCaster)
float fMagnitude = - akTarget.GetActorValue("Mood")
akTarget.SetActorValue("Mood", 0)
fMagnitude = Self.GetMagnitude()
_00E_FS_ReduceArcaneFeverIMOD.Apply()
if akTarget.GetFormID() != 0x14
return
endif
_00E_FS_ReduceArcaneFeverIMOD.Apply()
_00E_FS_DecreaseArcaneFeverM.Play(akTarget)
If akTarget == Game.GetPlayer()
fCurrentAV = -1*(akTarget.GetActorValue("LastFlattered"))
If fCurrentAV <= fMagnitude
akTarget.ModActorValue("LastFlattered", fCurrentAV)
_00E_AlchAmbrosia_sArcaneFeverDecreased.Show(fCurrentAV, 0)
Else
akTarget.ModActorValue("LastFlattered", fMagnitude)
_00E_AlchAmbrosia_sArcaneFeverDecreased.Show(fMagnitude, -1*(akTarget.GetActorValue("LastFlattered")))
EndIf
float fCurrentAV = -1 * akTarget.GetActorValue("LastFlattered")
If fCurrentAV <= fMagnitude
akTarget.ModActorValue("LastFlattered", fCurrentAV)
_00E_AlchAmbrosia_sArcaneFeverDecreased.Show(fCurrentAV, 0)
Else
akTarget.ModActorValue("LastFlattered", fMagnitude)
_00E_AlchAmbrosia_sArcaneFeverDecreased.Show(fMagnitude, -1 * akTarget.GetActorValue("LastFlattered"))
EndIf
EndEvent
float fCurrentAV
float fMagnitude
Sound Property _00E_FS_DecreaseArcaneFeverM Auto
ImageSpaceModifier Property _00E_FS_ReduceArcaneFeverIMOD Auto
Message Property _00E_AlchAmbrosia_sArcaneFeverDecreased Auto
Message Property _00E_AlchAmbrosia_sArcaneFeverDecreased Auto