ImageFuction[pawn]public OnPlayerEnterVehicle(playerid,vehicleid)
{
new szMsg[ 128 ];
if ( strcmp( VehicleInfo[ vehicleid ][ Owner ], "Sunshine Autos", true ) == 0 )
{
format( szMsg, sizeof( szMsg ), "VehicleID: %d - Cost - $%d ", vehicleid, VehicleInfo[ vehicleid ][ Price ] );
SendClientMessage( playerid, BLUE, szMsg );
}
else if ( strcmp( VehicleInfo[ vehicleid ][ Share ], "none", true ) == 0 )
{
format( szMsg, sizeof( szMsg ), "VehicleID: %d - Owner[%s]", vehicleid, VehicleInfo[ vehicleid ][ Owner ] );
SendClientMessage( playerid, GREEN, szMsg );
}
else
{
format( szMsg, sizeof( szMsg ), "VehicleID: %d - Owner[%s] - Shared[%s]", vehicleid, VehicleInfo[ vehicleid ][ Owner ], VehicleInfo[ vehicleid ][ Share ] );
SendClientMessage( playerid, ORANGE, szMsg );
}
return 1;
}[/pawn]
You put replace The public OnPlayerEnterVehicle , by my new better OnPlayerEnterVehicle.And sorry for my bad english
Car not buy
VehicleID: 1 - Cost : 40502$Car buy
VehicleID: 1 - Owner : .ElBoyzCar buy and shared
VehicleID: 1 - Owner : .ElBoyz - Shared : Aledark24En español[pawn]public OnPlayerEnterVehicle(playerid,vehicleid)
{
new szMsg[ 128 ];
if ( strcmp( VehicleInfo[ vehicleid ][ Owner ], "Sunshine Autos", true ) == 0 )
{
format( szMsg, sizeof( szMsg ), "VehiculoID: %d - Costo - $%d ", vehicleid, VehicleInfo[ vehicleid ][ Price ] );
SendClientMessage( playerid, BLUE, szMsg );
}
else if ( strcmp( VehicleInfo[ vehicleid ][ Share ], "none", true ) == 0 )
{
format( szMsg, sizeof( szMsg ), "VehiculoID: %d - Duenio[%s]", vehicleid, VehicleInfo[ vehicleid ][ Owner ] );
SendClientMessage( playerid, GREEN, szMsg );
}
else
{
format( szMsg, sizeof( szMsg ), "VehiculoID: %d - Duenio[%s] - Compartido[%s]", vehicleid, VehicleInfo[ vehicleid ][ Owner ], VehicleInfo[ vehicleid ][ Share ] );
SendClientMessage( playerid, ORANGE, szMsg );
}
return 1;
}[/pawn]