Bei den New's:
new DeinCar[2];
OnGameModeInit()
DeinCar[0] = AddStaticVehicle(bla);
DeinCar[1] = AddStaticVehicle(bla);
OnPlayerStateChange
if(newstate == PLAYER_STATE_DRIVER)
{
new Fahrzeug = GetPlayerVehicleID(playerid);
new name[32];
GetPlayerName(playerid,name,128);
for(new i = 0; i < sizeof(DeinCar); i++)
{
if(Fahrzeug == DeinCar[i])
{
if(strcmp(name, "NAME", true) == 0)
{
return SendClientMessage(playerid,COLOR_WHITE,"Willkommen NAME!");
}
else
{
RemovePlayerFromVehicle(playerid);
SendClientMessage(playerid,COLOR_GREY,"Du bist nicht NAME!");
}
}
}
}
So dürfte es eigentlich funktionieren..
Ist ungetestet!
Mfg, Hardcore