error 001: expected token: ")", but found "-identifier-"
#1

:S

pawn Код:
stock UpdateHouseInterior(houseID)
{
    if(houseID == INVALID_HOUSE_ID) return 0;
    if(IsValidDynamicObject(HInfo[houseID][HouseInteriorObject])
        DestroyDynamicObject(HInfo[houseID][HouseInteriorObject]); // Error here
    if(IsValidDynamicPickup(HInfo[houseID][WarDrobePickup])
        DestroyDynamicPickup(HInfo[houseID][WarDrobePickup]); // error here
    switch(HInfo[houseID][HouseInterior])
    {
        case 0:
        {
            HInfo[houseID][HouseInteriorObject] = CreateDynamicObject(15042, 2273.83179, 1014.40369, 80.55810,   0.00000, 0.00000, 0.00000, (houseID+1), (houseID+1));
            HInfo[houseID][WarDrobePickup] = CreateDynamicPickup(1275, 1, HInfo[houseID][WarDrobe][0], HInfo[houseID][WarDrobe][2], HInfo[houseID][WarDrobe][2], (houseID+1), (houseID+1));
        }
    }
    return 1;
}
Код:
C:\Users\Brandon\Desktop\Roleplay Server\gamemodes\M-RPv1.pwn(402) : error 001: expected token: ")", but found "-identifier-"
C:\Users\Brandon\Desktop\Roleplay Server\gamemodes\M-RPv1.pwn(404) : error 001: expected token: ")", but found "-identifier-"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
Reply
#2

Your missing the ")" at the end of the statements above the errors

if(IsValidDynamicPickup(HInfo[houseID][WarDrobePickup])
Reply
#3

I didn't even see that :@ fml
Reply
#4

PHP код:
if(houseID == INVALID_HOUSE_ID) return 0;
    if(  
IsValidDynamicObject  (  HInfo[houseID][HouseInteriorObject] ) )
        
DestroyDynamicObject(HInfo[houseID][HouseInteriorObject]); 
    if( 
IsValidDynamicPickupHInfo[houseID][WarDrobePickup] ) )
        
DestroyDynamicPickup(HInfo[houseID][WarDrobePickup]); 
Reply
#5

You really need to look up to the whole line, if the brackets are closed. Thereby when you are just editing something and using different methods you are enable to forgot, that you need to close this, and you are asking yourself if you did not already close it, that is weird moment but you have to look up for that in future.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)