Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - D&D 5th Edition SRD

Notices

Reply
 
Thread Tools Display Modes
DeathSheep
Member
 
Join Date: Jun 2018
Posts: 83

Old November 17th, 2021, 03:46 PM
I have some nested If...Then statements, but when I try to compile, I get an If...Then mismatch error on line 11. If I pull out the nested If...Thens and put in some other logic, then everything works fine. Is there an issue with using nested statements?

Code:
    ~ If we're disabled, do nothing &
 
    doneif (tagis[Helper.Disable] = 1)

   ~ Assign chosen skill
   if (field[usrIndex].value = 0) then
      foreach pick in hero from BaseSkill where "thingid.skAcrobat"
        if (eachpick.tagis[Helper.Proficient] = 0) then
           perform eachpick.assign[Helper.Proficient]
        endif
  elseif (field[usrIndex].value = 1) then
      foreach pick in hero from BaseSkill where "thingid.skStealth"
        if (eachpick.tagis[Helper.Proficient] = 0) then 
          perform eachpick.assign[Helper.Proficient]
        endif
  endif
DeathSheep is offline   #1 Reply With Quote
DeathSheep
Member
 
Join Date: Jun 2018
Posts: 83

Old November 17th, 2021, 04:12 PM
Of course I was so focused on the if...then I didn't realize I hadn't closed the for loop.
DeathSheep is offline   #2 Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 05:32 AM.


Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.