Problem... - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Problem... (
/showthread.php?tid=170379)
Problem... -
Gabb0411 - 22.08.2010
Hello , i have a little problem with my /rentboat. So , when i want to rent , i must be at the biz entrance.
If a boat is rented , and someone already wants to rent the boat , i want to say : "Someone already rents this boat"
Код:
if(listitem == 0)
{
if(SBizzInfo[16][sbProducts] == 0)
{
GameTextForPlayer(playerid, "~r~Out Of Stock", 5000, 1);
return 1;
}
if(PlayerInfo[playerid][pPbiskey] == 12)
{
GameTextForPlayer(playerid, "~w~No charge for the boss", 5000, 3);
TogglePlayerControllable(playerid, 1);
return 1;
}
if (GetPlayerMoney(playerid) < 35000)
{
SendClientMessage(playerid, COLOR_GRAD2, " You dont have that much cash !");
return 1;
}
if(HireCar[playerid] != 299)
{
gCarLock[HireCar[playerid]] = 0;
UnLockCar(HireCar[playerid]);
}
for(new i=0; i<MAX_PLAYERS; i++)
{
i already tried with GetPlayerVehicleID, it doesn't works---- if(HireCar[i] == HireCar[playerid])
{
SendClientMessage(playerid, COLOR_GREY, " Someone already rents this yacht !");
return 1;
}
}