27.03.2011, 15:08
Here is FS i want to make a park command like the carownerships when you type /v park your car will stay there
really need this if there anyone to help me to make this command if is possible.
really need this if there anyone to help me to make this command if is possible.
pawn Код:
// This is a comment
// uncomment the line below if you want to write a filterscript
//#define FILTERSCRIPT
#include <a_samp>
new Daniel;
#if defined FILTERSCRIPT
public OnFilterScriptInit()
{
print("\n--------------------------------------");
print(" Blank Filterscript by your name here");
print("--------------------------------------\n");
return 1;
}
#else
main()
{
print("\n----------------------------------");
print(" Blank Gamemode by your name here");
print("----------------------------------\n");
}
#endif
public OnFilterScriptInit()
{
Daniel = AddStaticVehicle(451,1890.1632,1989.1708,13.4920,179.9223,6,6);
}
public OnPlayerDisconnect(playerid, reason)
{
return 1;
}
public OnPlayerStateChange(playerid, newstate, oldstate)
{
new PlayerName[24];
GetPlayerName(playerid, PlayerName, sizeof(PlayerName));
if(newstate == PLAYER_STATE_DRIVER)
{
new Vehicle = GetPlayerVehicleID(playerid);
if(Vehicle == Daniel)
{
if(strcmp(PlayerName,"Daniel_Klaic",true)) //Provjerava dali je igrac Daniel_Klaic
{
RemovePlayerFromVehicle(playerid); //Izbacuje igraca iz auta,ako nije Daniel_Klaic
SendClientMessage(playerid, 0x33AA33AA, "Ovo vozilo moze voziti jedino Daniel_Klaic"); //Izbacuje poruku
}
}
}
return 1;
}