Skye Posted July 3, 2018 Share Posted July 3, 2018 I'm trying to make my life easier, so I was wondering if anyone knows of a clever trigger that would allow me to determine if SoD is installed while in-game. I know I can do it during mod installation, but I'd prefer to avoid having to override my triggers while I'm compiling the scripts. Quote Link to comment
Endurium Posted July 4, 2018 Share Posted July 4, 2018 (edited) Try this: AreaCheckObject("bd0120","bdporios") Should return True if both the area "bd0120" and creature in that area "bdporios" exist; they are SoD specific (the starting area). If SoD is not installed neither of them will exist and the trigger should return False (and the script compiler may throw warnings that resources don't exist). Edited July 4, 2018 by Endurium Quote Link to comment
argent77 Posted July 4, 2018 Share Posted July 4, 2018 Try this: AreaCheckObject("bd0120","bdporios") Should return True if both the area "bd0120" and creature in that area "bdporios" exist; they are SoD specific (the starting area). If SoD is not installed neither of them will exist and the trigger should return False (and the script compiler may throw warnings that resources don't exist). It didn't work in my tests. From what I've seen in existing scripts, this trigger is only used to check for creatures in the same area. An idea that *might* work (haven't tested yet): - spawn a SoD-specific creature (preferably one without assigned scripts) - use ActionOverride to execute a simple script action from the spawned creature (e.g. setting a variable) - despawn the creature - check if the variable has been set Quote Link to comment
Jarno Mikkola Posted July 4, 2018 Share Posted July 4, 2018 (edited) An idea that *might* work (haven't tested yet): - spawn a SoD-specific creature (preferably one without assigned scripts) - use ActionOverride to execute a simple script action from the spawned creature (e.g. setting a variable) - despawn the creature - check if the variable has been set Or you could use simple, if game SoD in weidu, append baldur.bcs via set global x to z, and check for global x is z there after. But, that's like ... Edited July 4, 2018 by Jarno Mikkola Quote Link to comment
Endurium Posted July 4, 2018 Share Posted July 4, 2018 (edited) It's a shame Beamdog didn't add a HasCampaign trigger to go with their HasDLC trigger (which checks DLC companions) I suspected AreaCheckObject might not work but after seeing it in Baldur.bcs I figured maybe... alas. Jarno's idea works best if you're installing with WeiDU anyway. No need to override triggers if you've got a global variable you can check at any time, from any place. Edited July 4, 2018 by Endurium Quote Link to comment
Skye Posted July 4, 2018 Author Share Posted July 4, 2018 Yeah, that was my next idea as well. It's better than editing my triggers, I guess. Quote Link to comment
Avenger Posted July 4, 2018 Share Posted July 4, 2018 I don't know if this helps. On windows, SetPrivateProfileString('DLC','dlcname','0') disables a dlc (HasDLC('dlcname') will return false). Sadly this won't work on tablets or linux. You can even use this cmd in the console. (without the leading C: prefix) Quote Link to comment
Endurium Posted July 5, 2018 Share Posted July 5, 2018 Can't hurt for her to try but I don't know if it will help because the game doesn't classify SoD or BP as DLC, but rather Campaigns From BGEE.LUA with SoD installed: Infinity_AddDLC( 'dorn', 'DLCDN', 31092, 31093, 'BGEE_IOS_DORN', 'baldursgate_android_dorn' ) Infinity_AddDLC( 'neera', 'DLCNE', 31090, 31091, 'BGEE_IOS_NEERA', 'baldursgate_android_neera' ) Infinity_AddDLC( 'manley', 'DLCP1', 31094, 31095, 'BGEE_IOS_PORTRAITPACK1', 'baldursgate_android_portraitpack1' ) Infinity_AddDLC( 'voice', 'DLCV1', 31096, 31097, 'BGEE_IOS_VOICEPACK1', 'baldursgate_android_voicepack1' ) ... START_CAMPAIGN_BG = 1, START_CAMPAIGN_BP = 2, START_CAMPAIGN_SOD = 3, Also when Sarevok dies and SoD is installed, the cutscene executes a MoveToCampaign("SoD") action referring to Campaign.2da which has all the necessary map/resource switches. All uses of HasDLC() in script refer to the BeamDog companions. Quote Link to comment
Ardanis Posted July 5, 2018 Share Posted July 5, 2018 Pretty sure HasDLC("SOD") is supposed to do what it says on the tin. Quote Link to comment
Avenger Posted July 6, 2018 Share Posted July 6, 2018 (edited) Pretty sure HasDLC("SOD") is supposed to do what it says on the tin. Sadly no. HasDLC("nosuchthis") returns true. You need to have a DLC variable set to 0 to actually get any negative result. And that's what you can do with SetPrivateProfileString('DLC','dlcname','0') Edited July 6, 2018 by Avenger Quote Link to comment
Recommended Posts
Join the conversation
You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.