tox2ik Posted June 27, 2012 Share Posted June 27, 2012 I want certain parts of my script not to fail even if SKSE is not installed. Is there a safe and easy way to check if it is installed? What about using import? If I say import StringUtil, but the script is not actually there on the target system. Is there a way to prevent the whole script from crashing in this scenario? Link to comment Share on other sites More sharing options...
fg109 Posted June 27, 2012 Share Posted June 27, 2012 (edited) You can try something like this: Bool Function GetSKSEInstalled() bool installed = false if (SKSE.GetVersion()) ;if your script made it to here, SKSE is installed ;otherwise, it would throw an error in the script log ;and the if condition would have failed installed = true endif return installed EndFunction Edited June 27, 2012 by fg109 Link to comment Share on other sites More sharing options...
tox2ik Posted June 27, 2012 Author Share Posted June 27, 2012 (edited) That's "calling a method on an unknown script" on a system where skse is not installed.One would think they'd at least throw in a global named SKSEVERSION or somehting. Edited June 27, 2012 by tox2ik Link to comment Share on other sites More sharing options...
Recommended Posts