Need Code
#6

Hello!

First you have to write the code in the following way:
PHP код:
public OnPlayerStateChange(playerid,newstate,oldstate)
{
    new 
Vozilo GetPlayerVehicleID(playerid);
    if(
newstate == PLAYER_STATE_DRIVER && Vozilo == Rent[0] || Vozilo == Rent[1] || Vozilo == Rent[2] || Vozilo == Rent[3] || Vozilo == Rent[4] || Vozilo == Rent[5] || Vozilo == Rent[6] || Vozilo == Rent[7])
    {
        if(
Rentano[playerid] != 0)return SendClientMessage(playerid,-1,""COLOR_CRVENA"Greska:{FFFFFF} Vozilo je vec iznajmljeno"),RemovePlayerFromVehicle(playerid);
        
ShowPlayerDialog(playerid,DIALOG_RENT,DIALOG_STYLE_LIST,""COLOR_ZUTA"Rent Vozila","{FFFFFF} ** "COLOR_SIVA"5 {FFFFFF}minuta\n** "COLOR_SIVA"15 {FFFFFF} minuta\n** "COLOR_SIVA"30 {FFFFFF} minuta","Iznajmi","Izlaz");
         
TogglePlayerControllable(playerid,0);
    }
    return 
1;

So, if it doesn't do you should us send the code where you use Rentano[playerid], but where are you set the value?

Mencent
Reply


Messages In This Thread
Need Code - by NoDi522 - 09.04.2015, 10:00
Re: Need Code - by JeaSon - 09.04.2015, 10:05
Re: Need Code - by NoDi522 - 09.04.2015, 10:10
Re: Need Code - by NoDi522 - 09.04.2015, 11:09
Re: Need Code - by NoDi522 - 09.04.2015, 12:41
AW: Need Code - by Mencent - 09.04.2015, 12:51
Re: Need Code - by NoDi522 - 09.04.2015, 12:54
Re: Need Code - by [ABK]Antonio - 09.04.2015, 12:58
Re: Need Code - by NoDi522 - 09.04.2015, 13:00
Re: Need Code - by R0 - 09.04.2015, 13:10

Forum Jump:


Users browsing this thread: 1 Guest(s)