JNGP - Problem with multiple if/then/else

Status
Not open for further replies.
Level 9
Joined
May 31, 2010
Messages
366
Hey, i'm using JNGP to create maps, sadly i'm not able to juse JASS so i have to use GUI for triggering.
I wrote a long trigger if wultiple if then else functions stacked together
(i was taking a substring which was filled with the first letter of the players name and had then to check what letter/number/symbol it is and then giving me back an defined integer. so i had to use ~40 stacked if/then/else functions - they had to be stacked cuz if i found no matching letter/number/symbol i had to get a default integer back)
when i then wanted to test it and saved it the JNGP gave me an error which said something like " expected 'takes' " and showed me the last part of the if/then/else chain i tried to remove the last 10 parts but the outcome was the same i tried deleting more and at about the 10th if/then/else function it saved normally without problems
why does it do that? and how to work arround if there is no fix for that?

to prevent some things:
i checked from A to Z and stored integers from 00 to 25 which gave me an error
after i deleted more parts i was checking from A to F and the integers where from 00 to 05 and it worked

they where just copy/pasted so i did nothing diffrent on later functions

pls help! :D
 
what?
if your usng GUI than you wont get any errors. are you using custom scripts? expected "takes" is usually an indicator that you forgot a "call"

also the max if/then/else size might be 32, not so sure about that. why are you chaining if statements together? don't. use Custom Script: return
 
no i don't use custom script thats why i don't understand it? o.O

UMSWE is enabled - des this cause the error?

i found a work arround to solve my problem in this case but i don't want it to gave me out errors when i need to stack multiple if/then/else functions

so still looking for the reason why it does that^^

but thx for your replys :D
 
Status
Not open for further replies.
Back
Top