Help error
#1

I get this error when i compile it...
I'm use Just Roleplay Script

Код:
error 017: undefined symbol "YSI_gSwheelmodels"
error 017: undefined symbol "YSI_gAwheelmodels"
warning 215: expression has no effect
error 001: expected token: ";", but found "]"
fatal error 107: too many error messages on one line
pawn Код:
iswheelmodel(modelid) {

    new wheelmodels[17] = {1025,1073,1074,1075,1076,1077,1078,1079,1080,1081,1082,1083,1084,1085,1096,1097,1098};

    foreach(wheelmodels, I) {

        if (modelid == wheelmodels[I])
            return true;

    }

    return false;
}
Help please +Rep if you help
Reply
#2

Please can you tell me which line is getting errors?
Reply
#3

Код:
 49381 lines - 	foreach(wheelmodels, I) {
Reply
#4

pawn Код:
stock iswheelmodel(modelid) {
    new wheelmodels[17] = {1025,1073,1074,1075,1076,1077,1078,1079,1080,1081,1082,1083,1084,1085,1096,1097,1098};
   
    for(new i = 0; i < sizeof(wheelmodels); ++i) {
        if (modelid == wheelmodels[i]) return true;
    }
    return false;
}
Reply
#5

Код:
C:\Documents and Settings\Winxp\Desktop\JustRP Publish\rp.pwn(49391) : error 017: undefined symbol "I"
pawn Код:
stock IllegalCarNitroIde(carmodel) {

    new illegalvehs[29] = { 581, 523, 462, 521, 463, 522, 461, 448, 468, 586, 509, 481, 510, 472, 473, 493, 595, 484, 430, 453, 452, 446, 454, 590, 569, 537, 538, 570, 449 };
   
    for(new i = 0; i < sizeof(illegalvehs); ++i) {
        if (carmodel == illegalvehs[I]) return true; //this line
    }
    return false;
}
Reply
#6

Capital I, change to normal i.

pawn Код:
stock IllegalCarNitroIde(carmodel) {

    new illegalvehs[29] = { 581, 523, 462, 521, 463, 522, 461, 448, 468, 586, 509, 481, 510, 472, 473, 493, 595, 484, 430, 453, 452, 446, 454, 590, 569, 537, 538, 570, 449 };
   
    for(new i = 0; i < sizeof(illegalvehs); ++i) {
        if (carmodel == illegalvehs[I]) return true; //this line
    }
    return false;
}
Reply
#7

Thanks to PaulDinam & kamzaf. +Rep for help
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)