Skripta koju koristim:City Lights [UP]
Detaljan opis problema:Mod je tu objavljen ali odmah na poÄetku sam naiÅ¡ao na bug, kad rentam vozilo piÅ¡e da je iznajmljeno ali ne mogu ga pokrenuti ni niÅ¡ta. ne renta se pomoću komande nego klikom na texttdraw. Kao da se ne ugasi do kraja kad kliknem rentaj. strelica ostane i nemogu pokrenut motor vozila ni niÅ¡ta..
Dio skripte:
public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
{
if(playertextid == rent7[playerid])
{
if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,"CL | "CRVENA"Moras se ulogovati da bi koristio ovu komandu!");
if(!IsPlayerInAnyVehicle(playerid)) return SCM(playerid,-1, ""SIVA"Morate biti u vozilu!");
if(GetPlayerState(playerid) != PLAYER_STATE_DRIVER) return SCM(playerid,-1, ""SIVA"Morate biti na mestu vozaca!");
if(Rentano[playerid] != 299) { SCM(playerid,-1,""SIVA"Vec imas rentano vozilo!"); RemovePlayerFromVehicle(playerid); TogglePlayerControllable(playerid, 1); return 1; }
foreach(Player, i)
{
if(Rentano[i] == GetPlayerVehicleID(playerid))
{
SCM(playerid,-1, ""ZELENA"[RENT]: "SIVA"To vozilo je vec rentano!");
RemovePlayerFromVehicle(playerid); TogglePlayerControllable(playerid, 1);
return 1;
}
}
if(BiciklaRent(GetPlayerVehicleID(playerid)))
{
if(PlayerInfo[playerid][pNovacDzep] < 30) { SCM(playerid,-1,""SIVA"Nemate dovoljno novca "ZELENA"(30$)"SIVA"!"); RemovePlayerFromVehicle(playerid); TogglePlayerControllable(playerid, 1); return 1; }
SCM(playerid,-1,""SPLAVA"[INFO]: "BELA"Rentali ste biciklo za "ZELENA"30$.");
g_NovacMinus(playerid,30);
FirmaNovac(93, 30);
}
if(MotoRent(GetPlayerVehicleID(playerid)))
{
if(PlayerInfo[playerid][pNovacDzep] < 80) { SCM(playerid,-1,""SIVA"Nemate dovoljno novca "ZELENA"(80$)"SIVA"!"); RemovePlayerFromVehicle(playerid); TogglePlayerControllable(playerid, 1); return 1; }
SCM(playerid,-1,""SPLAVA"[INFO]: "BELA"Rentali ste motor za "ZELENA"80$.");
g_NovacMinus(playerid,80);
FirmaNovac(92, 80);
}
if(AutaRent(GetPlayerVehicleID(playerid)))
{
if(PlayerInfo[playerid][pNovacDzep] < 120) { SCM(playerid,-1,""SIVA"Nemate dovoljno novca "ZELENA"(120$)"SIVA"!"); RemovePlayerFromVehicle(playerid); TogglePlayerControllable(playerid, 1); return 1; }
SCM(playerid,-1,""SPLAVA"[INFO]: "BELA"Rentali ste auta za "ZELENA"120$.");
g_NovacMinus(playerid,120);
FirmaNovac(91, 120);
}
Rentano[playerid] = GetPlayerVehicleID(playerid); TogglePlayerControllable(playerid, 1);
PlayerTextDrawHide(playerid,rent0[playerid]);
PlayerTextDrawHide(playerid,rent1[playerid]);
PlayerTextDrawHide(playerid,rent2[playerid]);
PlayerTextDrawHide(playerid,rent3[playerid]);
PlayerTextDrawHide(playerid,rent4[playerid]);
PlayerTextDrawHide(playerid,rent5[playerid]);
PlayerTextDrawHide(playerid,rent6[playerid]);
PlayerTextDrawHide(playerid,rent7[playerid]);
PlayerTextDrawHide(playerid,rent8[playerid]);
PlayerTextDrawHide(playerid,rent9[playerid]);
PlayerTextDrawHide(playerid,rent10[playerid]);
PlayerTextDrawHide(playerid,rent11[playerid]);
return 1;
}
else if(playertextid == rent8[playerid])
{
if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,"UP:RP | "CRVENA"Moras se ulogovati da bi koristio ovu komandu!");
if(!IsPlayerInAnyVehicle(playerid)) return SCM(playerid,-1,""SIVA"Niste u vozilu!");
if(Zavezan[playerid] == 1) return SCM(playerid,-1,""SIVA"Ne mozete koristiti komandu jer ste zavezani!");
if(IgracTazovan[playerid] == 1) return SCM(playerid,-1,""SIVA"Ne mozete koristiti komandu jer ste tazovani!");
if(StavljeneLisice[playerid] == 1) return SCM(playerid,-1,""SIVA"Ne mozete koristiti komandu jer imate lisice!");
RemovePlayerFromVehicle(playerid); TogglePlayerControllable(playerid, 1);
PlayerTextDrawHide(playerid,rent0[playerid]);
PlayerTextDrawHide(playerid,rent1[playerid]);
PlayerTextDrawHide(playerid,rent2[playerid]);
PlayerTextDrawHide(playerid,rent3[playerid]);
PlayerTextDrawHide(playerid,rent4[playerid]);
PlayerTextDrawHide(playerid,rent5[playerid]);
PlayerTextDrawHide(playerid,rent6[playerid]);
PlayerTextDrawHide(playerid,rent7[playerid]);
PlayerTextDrawHide(playerid,rent8[playerid]);
PlayerTextDrawHide(playerid,rent9[playerid]);
PlayerTextDrawHide(playerid,rent10[playerid]);
PlayerTextDrawHide(playerid,rent11[playerid]);
return 1;
}
if(BiciklaRent(vozilo))
{
if (Rentano[playerid] != vozilo)
{
TogglePlayerControllable(playerid, 0);
SelectTextDraw(playerid, 0xFFFFBB00FF);
PlayerTextDrawShow(playerid,rent0[playerid]);
PlayerTextDrawShow(playerid,rent1[playerid]);
PlayerTextDrawShow(playerid,rent2[playerid]);
PlayerTextDrawShow(playerid,rent3[playerid]);
PlayerTextDrawShow(playerid,rent4[playerid]);
PlayerTextDrawShow(playerid,rent5[playerid]);
PlayerTextDrawShow(playerid,rent6[playerid]);
PlayerTextDrawShow(playerid,rent7[playerid]);
PlayerTextDrawShow(playerid,rent8[playerid]);
PlayerTextDrawShow(playerid,rent9[playerid]);
PlayerTextDrawShow(playerid,rent10[playerid]);
PlayerTextDrawShow(playerid,rent11[playerid]);
PlayerTextDrawSetString(playerid,rent6[playerid],"M~w~ozete rentati ovo~n~biciklo");
}
}
if(MotoRent(vozilo))
{
if (Rentano[playerid] != vozilo)
{
TogglePlayerControllable(playerid, 0);
SelectTextDraw(playerid, 0xFFFFBB00FF);
PlayerTextDrawShow(playerid,rent0[playerid]);
PlayerTextDrawShow(playerid,rent1[playerid]);
PlayerTextDrawShow(playerid,rent2[playerid]);
PlayerTextDrawShow(playerid,rent3[playerid]);
PlayerTextDrawShow(playerid,rent4[playerid]);
PlayerTextDrawShow(playerid,rent5[playerid]);
PlayerTextDrawShow(playerid,rent6[playerid]);
PlayerTextDrawShow(playerid,rent7[playerid]);
PlayerTextDrawShow(playerid,rent8[playerid]);
PlayerTextDrawShow(playerid,rent9[playerid]);
PlayerTextDrawShow(playerid,rent10[playerid]);
PlayerTextDrawShow(playerid,rent11[playerid]);
PlayerTextDrawSetString(playerid,rent6[playerid],"M~w~ozete rentati ovaj~n~motor");
}
}
if(AutaRent(vozilo))
{
if (Rentano[playerid] != vozilo)
{
TogglePlayerControllable(playerid, 0);
SelectTextDraw(playerid, 0xFFFFBB00FF);
PlayerTextDrawShow(playerid,rent0[playerid]);
PlayerTextDrawShow(playerid,rent1[playerid]);
PlayerTextDrawShow(playerid,rent2[playerid]);
PlayerTextDrawShow(playerid,rent3[playerid]);
PlayerTextDrawShow(playerid,rent4[playerid]);
PlayerTextDrawShow(playerid,rent5[playerid]);
PlayerTextDrawShow(playerid,rent6[playerid]);
PlayerTextDrawShow(playerid,rent7[playerid]);
PlayerTextDrawShow(playerid,rent8[playerid]);
PlayerTextDrawShow(playerid,rent9[playerid]);
PlayerTextDrawShow(playerid,rent10[playerid]);
PlayerTextDrawShow(playerid,rent11[playerid]);
PlayerTextDrawSetString(playerid,rent6[playerid],"M~w~ozete rentati ovo~n~auto");
}
}
Neke slike/video za lakse dobivanje pomoci(neobavezno): http://i.imgur.com/s4DcIzP.png
Postavi dio za paljenje vozila.
riješio sam