Jump to content

"ToBEx" as an installation condition


temnix

Recommended Posts

One of the items I'm working on has a property which, according to Near Infinity, only applies if the mod is installed on an Enhanced Edition or ToB Extender - "Toggle critical hits." I have never used ToBEx for anything, because I play EE versions, but I try to make my items compatible with the "classic" engine - Shadows of Amn and its reverse application, Tutu. Well, it is easy to put in a check for SoA and Tutu, for ToB as well, and install a less sophisticated version of the item, but how can I write in a condition for ToBEx? It's not one of the GAME_IS constants, and though I could simply check this box in both versions, there is no harm in that, only the games where this property does anything (ToBEx and EE) should mention it in the item description.

Link to comment

Rather than have a condition for ToBEx you should just include it in your modification for non-EE.

This is from my own Tweaks:

////////////////////////
/// Include ToBEX ///
///////////////////////

OUTER_SPRINT ~TOBEX_MOD_DIRECTORY~ ~stweaks~
LOAD_TRA ~stweaks/tobex_redist/tobex.tra~
INCLUDE ~stweaks/tobex_redist/tobex.tpa~
COPY ~tobex_ini/tobexcore.ini~ ~tobex_ini/tobexcore.ini~
  REPLACE_TEXTUALLY ~Expanded Triggers=0~ ~Expanded Triggers=1~
  REPLACE_TEXTUALLY ~Enable PickpocketFailed Trigger=0~ ~Enable PickpocketFailed Trigger=1~
COPY ~tobex_ini/tobextweak.ini~ ~tobex_ini/tobextweak.ini~
  REPLACE_TEXTUALLY ~Engine:Disable Silence On Charm=0~ ~Engine:Disable Silence On Charm=1~
BUT_ONLY

 

Edited by Salk
Link to comment

@temnix Just as any other component of a mod:

REQUIRE_PREDICTATE MOD_IS_INSTALLED ~TobEx.tp2~ ~100~ ~ToBEx required~

This will check if ToBEx core component is installed and all other components require core component so you can check the single one.

Link to comment

So it's a mod. I thought it was some kind of special program. All right, thanks. The condition FILE_EXISTS ~tobex_ini/tobexcore.ini should do it.

Edited by temnix
Link to comment

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...