Lil problem with if
#2

It'll have something to do with the mixing of && and || on an if statement.

Maybe try breaking them up a bit.

if((VehInfo[somecar][VehFaction] != 0 && VehInfo[somecar][VehFaction] == AccInfo[playerid][PlayerFaction])|| VehInfo[somecar][VehFaction] == 0)


Not saying it'll work in the slightest, but it's always trouble with && and ||. You have to get that crap all perfect.

Another test maybe, is to make, before the if statement, a debug printf to the log, showing what the values actually are, when you are using this.

Use format, to make a string, and print the whole line out using printf.



Could also be beneficial to do individual if statements, if this won't work.
Reply


Messages In This Thread
Lil problem with if - by Squirrel - 18.01.2016, 01:43
Re: Lil problem with if - by Sew_Sumi - 18.01.2016, 02:54
Re: Lil problem with if - by Squirrel - 18.01.2016, 15:30

Forum Jump:


Users browsing this thread: 1 Guest(s)