06.07.2015, 18:45
(
Последний раз редактировалось Sc0pion; 07.07.2015 в 22:43.
)
Fixed!
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
if(!ispassenger)
{
//new id = GetPlayerVehicleID(playerid); This is already defined in the callback, 'vehicleid' (remove this line)
if(IsValidVehicle(vehicleid) && VehicleCreated[vehicleid] == VEHICLE_PLAYER) // So i changed all 'id' to 'vehicleid'
{
new msg[45+MAX_PLAYER_NAME]; // This string will never be 256 cells big, so i changed it according to actual size.
format(msg, sizeof(msg), "[ NOTIFICATION: This vehicle belongs to %s. ]", VehicleOwner[vehicleid]);
SendClientMessage(playerid, COLOR_PURPLE, msg);
}
}
return 1;
}