4
Fork 0

Gracefully disable some SKSE-dependent features

development
Eddoursul 3 months ago
parent 55865dc379
commit 90a5a2868e
  1. BIN
      scripts/SKSE_placeholder.pex
  2. BIN
      scripts/_00E_Func_ReferenceFormList.pex
  3. BIN
      scripts/_00E_SafeItemRemove.pex
  4. BIN
      scripts/_00E_UnlockSpellAlias.pex
  5. BIN
      scripts/_00e_autosavesystem_functions.pex
  6. BIN
      scripts/_00e_enderalmcm.pex
  7. BIN
      scripts/_00e_game_talentcontrolsc.pex
  8. BIN
      scripts/_00e_gui_actorhealthbar.pex
  9. BIN
      scripts/_sag_activ_newstatsscripts.pex
  10. BIN
      scripts/_sag_pc_statstrack_playerscript.pex
  11. 2
      source/scripts/SKSE_placeholder.psc
  12. 4
      source/scripts/_00E_Func_ReferenceFormList.psc
  13. 7
      source/scripts/_00E_SafeItemRemove.psc
  14. 6
      source/scripts/_00E_UnlockSpellAlias.psc
  15. 1
      source/scripts/_00e_autosavesystem_functions.psc
  16. 8
      source/scripts/_00e_enderalmcm.psc
  17. 19
      source/scripts/_00e_game_talentcontrolsc.psc
  18. 5
      source/scripts/_00e_gui_actorhealthbar.psc
  19. 7
      source/scripts/_sag_activ_newstatsscripts.psc
  20. 6
      source/scripts/_sag_pc_statstrack_playerscript.psc

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -13,7 +13,7 @@ int Function GetVersionMinor() global
endFunction
; get the beta version of SKSE
int Function GetVersionBeta()
int Function GetVersionBeta() global
return 0
endFunction

@ -5,7 +5,7 @@ Function Enable(FormList referenceList) Global
Int nItems = referenceList.GetSize()
Int i = 0
If nItems < 128 && nItems > 1
If nItems < 128 && nItems > 1 && SKSE.GetVersion() > 0
Form[] refArray = referenceList.ToArray()
While i < nItems
(refArray[i] as ObjectReference).EnableNoWait()
@ -25,7 +25,7 @@ Function Disable(FormList referenceList) Global
Int nItems = referenceList.GetSize()
Int i = 0
If nItems < 128 && nItems > 1
If nItems < 128 && nItems > 1 && SKSE.GetVersion() > 0
Form[] refArray = referenceList.ToArray()
While i < nItems
(refArray[i] as ObjectReference).DisableNoWait()

@ -6,10 +6,11 @@ Function RemoveAllItemsSafeVersion(ObjectReference TransferToLoc = NONE)
EndIf
RemoveItemsIncrementally(Gold001, TransferToLoc)
Form[] arrows = _00E_AllAmmos.ToArray()
Int nItems = _00E_AllAmmos.GetSize()
Int i = 0
While i < arrows.Length
RemoveItemsIncrementally(arrows[i], TransferToLoc)
While i < nItems
RemoveItemsIncrementally(_00E_AllAmmos.GetAt(i), TransferToLoc)
i += 1
EndWhile

@ -7,11 +7,13 @@ Int Property LOCK_LEVEL_EXPERT = 75 AutoReadOnly
Int Property LOCK_LEVEL_MASTER = 254 AutoReadOnly
event OnInit()
RegisterForModEvent("Enderal_UnlockSpellHit", "OnUnlockSpell")
OnPlayerLoadGame()
endevent
event OnPlayerLoadGame()
RegisterForModEvent("Enderal_UnlockSpellHit", "OnUnlockSpell")
if SKSE.GetVersion() > 0
RegisterForModEvent("Enderal_UnlockSpellHit", "OnUnlockSpell")
endif
endevent
Event OnUnlockSpell(string eventName, string strArg, float fSpellFormID, Form containerForm)

@ -29,6 +29,7 @@ Function UpdateAutoSaveInterval()
if SKSE.GetVersion() <= 0
UnregisterForUpdate()
Debug.Trace("NO SKSE: timed autosaves are disabled")
return
endif

@ -8,6 +8,14 @@ int function _GetScriptVersion() Global
return 1
endFunction
event OnGameReload()
if SKSE.GetVersion() == 0
Debug.Trace("NO SKSE: the Mod Configuration Menu is disabled")
return
endif
parent.OnGameReload()
endevent
Event OnPageReset(string page)
; adding options to rebind new key options: 1) Hero menu 2) meditation 3) Phasmalist summon apparition 4) Horseflute

@ -38,15 +38,20 @@ EndFunction
;=====================================================================================
Event OnInit()
If self == PlayerREF
GoToState("RealPlayer")
RegisterForActions()
EndIf
OnPlayerLoadGame()
EndEvent
Event OnPlayerLoadGame()
If self == PlayerREF ; A check just in case. Most likely this condition is always True
If self == PlayerREF && SKSE.GetVersion() > 0
if GetState() != "RealPlayer"
GoToState("RealPlayer")
endif
RegisterForActions()
else
Debug.Trace("NO SKSE: individual shout cooldowns are disabled")
if GetState() != "Disabled"
GoToState("Disabled")
endif
EndIf
EndEvent
@ -90,6 +95,10 @@ State RealPlayer
EndState
state Disabled
; Do nothing
endstate
;=====================================================================================
; PROPERTIES
;=====================================================================================

@ -111,6 +111,11 @@ endEvent
event OnGameReload()
if SKSE.GetVersion() == 0
Debug.Trace("NO SKSE: companion health bars are disabled")
return
endif
parent.OnGameReload()
If Game.GetModByName("SkyUI_SE.esp") == 255 || _00E_ActorHealthBarsEnabled.GetValue() == 0

@ -12,8 +12,13 @@ GlobalVariable Property ProphetDiceLostGold Auto
GlobalVariable Property _SAG_ProphDiceWonGold Auto
Event OnInit()
RegisterForMenu("Journal Menu")
if SKSE.GetVersion() > 0
RegisterForMenu("Journal Menu")
else
Debug.Trace("NO SKSE: Dice Jack stats display is disabled")
endif
EndEvent
Event OnPlayerLoadGame()
OnInit()
EndEvent

@ -13,7 +13,11 @@ String sLostBetsValue
Event OnInit()
RegisterForMenu("Journal Menu")
if SKSE.GetVersion() > 0
RegisterForMenu("Journal Menu")
else
Debug.Trace("NO SKSE: card game stats display is disabled")
endif
endEvent
Event OnPlayerLoadGame()

Loading…
Cancel
Save