4
Fork 0

Improved killmove switching in effect scripts

development
Eddoursul 3 months ago
parent 59698590b4
commit 7a86fcfb42
  1. BIN
      scripts/_00E_KillMove.pex
  2. BIN
      scripts/_00e_a1_arcticwindsc.pex
  3. BIN
      scripts/_00e_a2_eyeofthestormsc.pex
  4. BIN
      scripts/_00e_a2_eyeofthestormselfsc.pex
  5. BIN
      scripts/_00e_a2_welloflifescript.pex
  6. BIN
      scripts/_00e_disablekillmovessc.pex
  7. BIN
      scripts/_00e_ephandler.pex
  8. BIN
      scripts/_00e_nq_g_07_functions.pex
  9. BIN
      scripts/sf_nq_g_07dijaam_sc02_kontor_00147062.pex
  10. 35
      source/scripts/_00E_KillMove.psc
  11. 12
      source/scripts/_00e_a1_arcticwindsc.psc
  12. 5
      source/scripts/_00e_a2_eyeofthestormsc.psc
  13. 8
      source/scripts/_00e_a2_eyeofthestormselfsc.psc
  14. 9
      source/scripts/_00e_a2_welloflifescript.psc
  15. 12
      source/scripts/_00e_disablekillmovessc.psc
  16. 2
      source/scripts/_00e_ephandler.psc
  17. 12
      source/scripts/_00e_nq_g_07_functions.psc
  18. 2
      source/scripts/sf_nq_g_07dijaam_sc02_kontor_00147062.psc

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -0,0 +1,35 @@
Scriptname _00E_KillMove Hidden
int Function Off() Global
GlobalVariable KillMove = Game.GetForm(0x100F19) as GlobalVariable
int iPrevValue = KillMove.GetValue() as int
KillMove.SetValue(0 as float)
Utility.SetINIBool("bVATSDisable:VATS", true)
return iPrevValue
EndFunction
int Function On() Global
GlobalVariable KillMove = Game.GetForm(0x100F19) as GlobalVariable
int iPrevValue = KillMove.GetValue() as int
KillMove.SetValue(1 as float)
Utility.SetINIBool("bVATSDisable:VATS", false)
return iPrevValue
EndFunction
int function SetValue(bool bValue) Global
if bValue
return On()
else
return Off()
endif
endfunction

@ -8,12 +8,11 @@ Import _00E_TalentLibrary
Event onEffectStart(Actor akTarget, Actor akCaster)
if ((akTarget.GetLevel() - (PlayerLevel.GetValueInt())) > 4) || (akTarget.HasKeyword(MagicNoFreeze)) ; Debug only!
_00E_A1_ArcticWind_sEnemyTooPowerful.Show()
Else
akTarget.AddSpell(_00E_A1_ArcticWindFrozenAb)
KillMove.SetValueInt(0)
akTarget.AddSpell(_00E_A1_ArcticWindFrozenAb)
iKillMove = _00E_KillMove.Off()
EndIf
EndEvent
@ -21,9 +20,7 @@ EndEvent
Event OnEffectFinish(Actor akTarget, Actor akCaster)
akTarget.RemoveSpell(_00E_A1_ArcticWindFrozenAb)
If Utility.GetINIBool("bVATSDisable:VATS") == 0
KillMove.SetValueInt(1)
EndIf
_00E_KillMove.SetValue(iKillMove)
EndEvent
@ -32,6 +29,8 @@ EndEvent
; PROPERTIES
;=====================================================================================
int iKillMove
Actor Property PlayerREF Auto
Spell Property _00E_A1_ArcticWindFrozenAb Auto
@ -43,4 +42,3 @@ GlobalVariable Property KillMove Auto
Keyword Property MagicNoFreeze Auto
GlobalVariable Property PlayerLevel Auto

@ -21,8 +21,7 @@ Event OnEffectStart(Actor akTarget, Actor akCaster)
fDurationFailsave = _00E_A2_EyeOfTheStormSP.GetNthEffectDuration(iDurationIndex)
iSound = MAGShoutSlowTimeActive02LP.Play(PlayerREF)
PlayerREF.PlaceAtMe(_00E_A2_EyeOfTheStormFailsaveExp, 1)
iKillMoveConfig = KillMove.GetValueInt()
KillMove.SetValueInt(0)
iKillMoveConfig = _00E_KillMove.Off()
akCaster.AddSpell(_00E_A2_EyeOfTheStormAb, False)
RegisterForSingleUpdate(fDurationFailsave)
@ -41,7 +40,7 @@ Event OnEffectFinish(Actor akTarget, Actor akCaster)
if (PlayerREF.HasSpell(_00E_A2_EyeOfTheStormAb))
Sound.StopInstance(iSound)
KillMove.SetValueInt(iKillMoveConfig)
_00E_KillMove.SetValue(iKillMoveConfig)
akCaster.RemoveSpell(_00E_A2_EyeOfTheStormAb)
endif

@ -8,7 +8,7 @@ Import _00E_TalentLibrary
Event OnEffectStart(Actor Target, Actor Caster)
KillMove.SetValueInt(0)
iKillMove = _00E_KillMove.Off()
AudioCategoryPausedDuringMenu.Mute()
_00E_A2_EyeOfTheStormIMOD.Apply()
@ -17,9 +17,7 @@ EndEvent
Event OnEffectFinish(Actor akTarget, Actor akCaster)
If Utility.GetINIBool("bVATSDisable:VATS") == 0
KillMove.SetValueInt(1)
EndIf
_00E_KillMove.SetValue(iKillMove)
_00E_A2_EyeOfTheStormIMOD.Remove()
AudioCategoryPausedDuringMenu.UnMute()
@ -30,6 +28,8 @@ EndEvent
; PROPERTIES
;=====================================================================================
int iKillMove
ImagespaceModifier Property _00E_A2_EyeOfTheStormIMOD Auto
Actor Property PlayerREF Auto

@ -17,7 +17,7 @@ EndEvent
Event OnEffectStart(Actor akTarget, Actor akCaster)
KillMove.SetValue(0)
iKillMove = _00E_KillMove.Off()
MAGPowerRacialHitskinM.Play(PlayerREF)
AudioCategorySFXDeath.Mute()
PlayerREF.GetActorBase().SetEssential(True)
@ -29,14 +29,10 @@ Event OnEffectFinish(Actor akTarget, Actor akCaster)
AudioCategorySFXDeath.UnMute()
PlayerREF.GetActorBase().SetEssential(False)
UnregisterForUpdate()
_00E_KillMove.SetValue(iKillMove)
EndEvent
Event OnUpdate()
EndEvent
;=====================================================================================
; FUNCTIONS
@ -100,6 +96,7 @@ EndFunction
; PROPERTIES
;=====================================================================================
int iKillMove
float iTriggerHealthPercentage
Explosion Property _00E_A2_WellOfLifeExplosionVisual Auto

@ -2,20 +2,18 @@ Scriptname _00E_DisableKillMovesSC extends ObjectReference
Event OnTriggerEnter(ObjectReference akActionRef)
if akActionRef == Game.GetPlayer()
KillMove.SetValueInt(0)
if akActionRef == Game.GetForm(0x14)
iKillMove = _00E_KillMove.Off()
EndIf
EndEvent
Event OnTriggerLeave(ObjectReference akActionRef)
if akActionRef == Game.GetPlayer()
If Utility.GetINIBool("bVATSDisable:VATS") == 0
KillMove.SetValueInt(1)
EndIf
if akActionRef == Game.GetForm(0x14)
_00E_KillMove.SetValue(iKillMove)
EndIf
EndEvent
GlobalVariable Property KillMove Auto
int iKillMove

@ -1,4 +1,4 @@
Scriptname _00E_EPHandler
Scriptname _00E_EPHandler Hidden
Function GiveEP(int ToGive) Global

@ -449,18 +449,6 @@ Function DijaamAttackPlayer()
EndFunction
Function ToggleKillmoves()
if KillMove.GetValue() == 1
bKillMovesDeactivated = true
KillMove.SetValue(0)
ElseIf KillMove.GetValue() == 0 && bKillMovesDeactivated == true
bKillMovesDeactivated = false
KillMove.SetValue(1)
EndIf
EndFunction
Function DijaamLeave()
FadeToBlackIMOD.Apply()

@ -23,7 +23,7 @@ EndFunction
;BEGIN FRAGMENT Fragment_7
Function Fragment_7()
;BEGIN CODE
NQ_G_07.ToggleKillmoves()
; 2.1: toggling killmove removed
;END CODE
EndFunction
;END FRAGMENT

Loading…
Cancel
Save