So I have a script set up for my mod that should (theoretically) contain a global function that, when called, will set a few vars IF you have SKSE, and if you don't, pop up a messagebox informing you. Right now it's very simple, just if you have SKSE or not. I'll add the specific GetMinorVersion, etc. later. However, right now the popup shows EVERYTIME the player loads the game (I have an alias script calling this global function). I HAVE SKSE version 1.7.1, with the little notification in the bottom left corner of the menu and everything. So it's probably a scripting issue...
Script containing global function - has some extra stuff as well, on a control quest that is start game enabled
Scriptname IQControlQuestScript extends Quest {Governs the globally used functions and properties for ImmersiveQuests.}GlobalVariable Property HasSKSE Auto {For use with quest conditions. Equal to SKtikstallCheck.}GlobalVariable Property PlayerWeight AutoEvent OnInit() RegisterForSingleUpdate(0.1)EndEventEvent OnUpdate() HasSKSE.SetValue(SKtikstallCheck()) If IQControlQuestScript.SKtikstallCheck() ;SKSE installed PlayerWeight.SetValue(GetPCWeight()) Else Debug.MessageBox("You don't have SKSE installed. Parts of Immersive Quests will not work properly without it.") EndIfEndEventInt Function SKtikstallCheck() Global Float SKSEVer = SKSE.GetVersion() If SKSEVer > 0.00 ;SKSE installed Return 1 Else ;SKSE not installed Return 0 EndIfEndFunctionFloat Function GetPCWeight() Global Return Game.GetPlayer().GetActorBase().GetWeight()EndFunctionFunction FailAllObjectivesixcept(Quest kQuest, Int Exception, Int HighestObj) Global Int Counter = 0 While (Counter < HighestObj) If (Counter != Exception) kQuest.SetObjectiveCompleted(Counter, false) EndIf Counter += 1 EndWhileEndFunction
Player alias script - on the same script:
Scriptname IQControlPlayerAlias extends ReferenceAlias {Does stuff when the player loads the game.}GlobalVariable Property HasSKSE Auto {For use with quest conditions. Equal to SKtikstallCheck.}Event OnPlayerLoadGame() HasSKSE.SetValue(IQControlQuestScript.SKtikstallCheck()) If HasSKSE.Value =http://forums.bethsoft.com/topic/1509171-skse-version-check-issue/= 0 ;SKSE installed Else Debug.MessageBox("You don't have SKSE installed. Parts of Immersive Quests will not work properly without it.") EndIfEndEvent
Also, I'll add a real message at some point not just the debug. For now, I'm just testing.