Help with some lines. - 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: Help with some lines. (
/showthread.php?tid=119703)
Help with some lines. -
WardenCS - 09.01.2010
Hey,i have problem,i want to make if you are donaterank 1 atleast,you can own 3 vehicles,but when your donaterank is 0 you can only buy 1 car,heres the lines from it,but it wont work...
pawn Код:
else if(strcmp(x_nr,"buy",true) == 0)
{
if(IsAnOwnableCar(idcar))
{
if(PlayerInfo[playerid][pLevel] < 3)
{
SendClientMessage(playerid, COLOR_GREY, "You need to be level 3 to buy a vehicle!");
return 1;
}
if(PlayerInfo[playerid][pDonateRank] == 0)
{
if(PlayerInfo[playerid][pPcarkey] == 999)
{
}
else
{
SendClientMessage(playerid, COLOR_GREY, " You already own Vehicle");
}
return 1;
}
if(PlayerInfo[playerid][pDonateRank] != 0)
{
if(PlayerInfo[playerid][pPcarkey2] == 999)
{
}
else if(PlayerInfo[playerid][pPcarkey3] == 999)
{
}
else
{
SendClientMessage(playerid, COLOR_GREY, " You already own 3 vehicles");
}
return 1;
}
if(CarInfo[idcar][cOwned]==1)
{
SendClientMessage(playerid, COLOR_GREY, "Someone already owns this car");
return 1;
}
if(GetPlayerMoney(playerid) >= CarInfo[idcar][cValue])
{
if(PlayerInfo[playerid][pDonateRank] == 0)
{
if(PlayerInfo[playerid][pPcarkey] == 999)
{
if(PlayerInfo[playerid][pDonateRank] == 0)
{
PlayerInfo[playerid][pPcarkey] = idcar;
}
if(PlayerInfo[playerid][pPcarkey2] == 999)
{
PlayerInfo[playerid][pPcarkey2] = idcar;
}
else if(PlayerInfo[playerid][pPcarkey3] == 999)
{
PlayerInfo[playerid][pPcarkey3] = idcar;
}
else
{
}
}
return 1;
}
CarInfo[idcar][cOwned] = 1;
GetPlayerName(playerid, sendername, sizeof(sendername));
strmid(CarInfo[idcar][cOwner], sendername, 0, strlen(sendername), 999);
SafeGivePlayerMoney(playerid,-CarInfo[idcar][cValue]);
PlayerPlayMusic(playerid);
GameTextForPlayer(playerid, "~w~Congratulations~n~Don't forget to /v park it!", 5000, 3);
SendClientMessage(playerid, COLOR_GRAD2, "Congratulations on your new purchase!");
SendClientMessage(playerid, COLOR_GRAD2, "Type /vehiclehelp to view the vehicle manual!");
SendClientMessage(playerid, COLOR_YELLOW2, "You can start the engine up now !");
gEngine[playerid] = 0;
engineOn[GetPlayerVehicleID(playerid)] = false;
DateProp(playerid);
OnPropUpdate();
OnPlayerUpdate(playerid);
return 1;
}
else
{
SendClientMessage(playerid, COLOR_GREY, " You don't have enough cash with you ! ");
return 1;
}
}
}
else
{
SendClientMessage(playerid, COLOR_WHITE, "HINT: (/v)ehicle [name]");
SendClientMessage(playerid, COLOR_WHITE, "Available names: park, lock(1-3), sell, sellto, color");
return 1;
}
Re: Help with some lines. -
WardenCS - 09.01.2010
BUMP!
Re: Help with some lines. -
WardenCS - 09.01.2010
aww cmon anybody?
Re: Help with some lines. -
KnooL - 09.01.2010
Don't bump within 12 hours.
Re: Help with some lines. -
WardenCS - 09.01.2010
but it was at 5 page cmoon nobody wont check it :S
any help?
btw i thought i can bump after 5 hrs lool
Re: Help with some lines. -
WardenCS - 10.01.2010
BUMP!
Re: Help with some lines. -
WardenCS - 11.01.2010
aww cmon BUMP!