Quote:
Originally Posted by 69Playa
pawn Code:
public CheckOwner(playerid) { if(IsPlayerConnected(playerid)) { for(new i = 1; i < sizeof(CarInfo); i++) { new playername[MAX_PLAYER_NAME]; GetPlayerName(playerid,playername,sizeof(playername)); if(strcmp(playername,CarInfo[i][vOwner],true)==0) { PlayerInfo[playerid][pVehicle] = 1; return i; } else { PlayerInfo[playerid][pVehicle] = 0; return i; } } } return 1; }
You should use 'else' and not this:
pawn Code:
else if(strcmp(playername,CarInfo[i][vOwner],false)==0) { PlayerInfo[playerid][pVehicle] = 0; return i; }
That checks if the player's name IS the owner of the vehicle again!
|
Didn't work mate... and PrawkC, if you're not helping, then get out.