SA-MP Forums Archive
Rent Cars 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: Rent Cars Problem (/showthread.php?tid=235304)



Rent Cars Problem - pantelimonfl - 05.03.2011

I have this code.

pawn Code:
public IsARentBike(carid)
{
    for(new i = 0; i <MAX_VEHICLES; i++)
    {
        if(CarInfo[i][cFaction] == 20)  return 1;
    }
    return 0;
}
and this
pawn Code:
if(IsARentBike(newcar))
        {
            if (HireCar[playerid] != newcar)
            {
                format(string, sizeof(string), "~w~You can Rent this bike~n~Cost:~g~$%d~n~~w~To rent type ~g~/rentbike~w~~n~to get out type ~r~/exit",SBizzInfo[0][sbEntranceCost]);
                TogglePlayerControllable(playerid, 0);
                GameTextForPlayer(playerid, string, 5000, 3);
            }
        }
I tried even with newcar == 30 (carid) but it doesn't work.
The cars are loaded from cfg file.


Re: Rent Cars Problem - bijoyekuza - 05.03.2011

its taken from Raven's roleplay...
Where did you added those codes?



Re: Rent Cars Problem - pantelimonfl - 05.03.2011

Are you sure? I don't use ravens. I use a massive edit of gtarp


Re: Rent Cars Problem - pantelimonfl - 05.03.2011

Bump.


Re: Rent Cars Problem - pantelimonfl - 06.03.2011

Bump.