Author Topic: Checking for multiple subcomponents with MOD_IS_INSTALLED  (Read 1139 times)

Offline Andrea C.

  • Planewalker
  • *****
  • Posts: 80
  • Gender: Male
Hello.

I'm adding a MOD_IS_INSTALLED check to my installer so that a specific subset of Siege of Dragonspear helmets gets patched only if a previous component of my mod is installed. The catch is that said component comes with two subcomponents that use different DESIGNATED numbers (20 and 21 respectively), both of which satisfy my requirements for patching the helmets.

So my question is: Is it possible to make MOD_IS_INSTALLED check for both subcomponents 20 and 21 simultaneously?

Currently my code is

Code: [Select]
(helmet patching stuff)

ACTION_IF (MOD_IS_INSTALLED ~setup-animod.tp2~ ~20~) THEN BEGIN

(Siege of Dragonspear helmet patching stuff)

END

Or alternatively I could use the same DESIGNATED number for both components (though that doesn't strike me as a particularly great idea)?

Offline Argent77

  • Planewalker
  • *****
  • Posts: 187
Re: Checking for multiple subcomponents with MOD_IS_INSTALLED
« Reply #1 on: June 11, 2017, 07:57:39 AM »
Try this:
Code: [Select]
ACTION_IF (MOD_IS_INSTALLED ~setup-animod.tp2~ 20) OR
          (MOD_IS_INSTALLED ~setup-animod.tp2~ 21) THEN BEGIN

(Siege of Dragonspear helmet patching stuff)

END

(Replace "OR" with "AND" if both components have to be installed at the same time.)

 

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.

Name: Email:
Verification:
Type the letters shown in the picture
Listen to the letters / Request another image
Type the letters shown in the picture:
What color is grass?:
What is the seventh word in this sentence?:
What is five minus two (use the full word)?: