Duple plate

Započeo â–‘Yâ–‘aâ–‘nâ–‘nâ–‘iâ–‘câ–‘kâ–‘, Februar 04, 2018, 21:42:19 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 3 gostiju pregledaju ovu temu.

Detaljan opis problema: Napravio sam sistem duplih plata ali igracu ne daji nista od plate, dok u firmi dode 10k
Dio skripte:
if(mehanicarhappyjob == 1)
			{
			    new plata = 5000;
				new bonus = random(50);
				SCM(playerid, NARANCASTA,"Happy job: {FFFFFF}Posto je ukljucen Happy Job za posao kosac trave dobili ste duplu platu!");
				if(PI[playerid][pFirma] == 8) { Plata(playerid, plata/2, bonus/2); }
				else { Plata(playerid, plata, bonus); }
				PI[playerid][pMehanicarOdvoz] = 360;
				DisablePlayerCheckpoint(playerid);
				JFirmaPlus(8, plata/2);
			}
			if(IsTrailerAttachedToVehicle(hvID))
			{
				h_DisablePlayerCheckpoint(playerid);
		     	new plata = 6500;
		       	new bonus = random(50);
	            SCMF(playerid, SVETLOZUTA, "(POSAO) {FFFFFF}Zaradili ste $%d od ovog automobila!", plata+bonus);
	            PlataNovacPlus(playerid, plata+bonus);
	       		JFirmaPlus(8, plata/2);
	       		MayorInfo[1][Budzet] += 5;
		        PI[playerid][pMehanicarOdvoz] = 360;
		        SetVehicleToRespawn(GetVehicleTrailer(GetPlayerVehicleID(playerid)));

Neke slike/video za lakse dobivanje pomoci(neobavezno): ne dobijam nista izbaci mi td da sam dobio platu a nisam
Respect to Muma187, Sivir, Ino420, Tosic, Shomy Script, σgí, [CG]Johnny, [WG]Danny
Alfa Gaming Community Owner & Skripter
Alfa Gaming mod edit:100%

Citat: [AG]Bajric poslato Februar 04, 2018, 21:42:19 POSLE PODNE
Detaljan opis problema: Napravio sam sistem duplih plata ali igracu ne daji nista od plate, dok u firmi dode 10k
Dio skripte:
if(mehanicarhappyjob == 1)
			{
			    new plata = 5000;
				new bonus = random(50);
				SCM(playerid, NARANCASTA,"Happy job: {FFFFFF}Posto je ukljucen Happy Job za posao kosac trave dobili ste duplu platu!");
				if(PI[playerid][pFirma] == 8) { Plata(playerid, plata/2, bonus/2); }
				else { Plata(playerid, plata, bonus); }
				PI[playerid][pMehanicarOdvoz] = 360;
				DisablePlayerCheckpoint(playerid);
				JFirmaPlus(8, plata/2);
			}
			if(IsTrailerAttachedToVehicle(hvID))
			{
				h_DisablePlayerCheckpoint(playerid);
		     	new plata = 6500;
		       	new bonus = random(50);
	            SCMF(playerid, SVETLOZUTA, "(POSAO) {FFFFFF}Zaradili ste $%d od ovog automobila!", plata+bonus);
	            PlataNovacPlus(playerid, plata+bonus);
	       		JFirmaPlus(8, plata/2);
	       		MayorInfo[1][Budzet] += 5;
		        PI[playerid][pMehanicarOdvoz] = 360;
		        SetVehicleToRespawn(GetVehicleTrailer(GetPlayerVehicleID(playerid)));

Neke slike/video za lakse dobivanje pomoci(neobavezno): ne dobijam nista izbaci mi td da sam dobio platu a nisam

if(PI[playerid][pFirma] == 8) { Plata(playerid, plata/2, bonus/2); }
dodaj jos jedno plata/2 i probaj
if(PI[playerid][pFirma] == 8) { Plata(playerid, plata/2, bonus/2, plata/2); }
ako ne radi stavis
new plata/3 = plata/2
To mi je jedino palo na pamet

if(mehanicarhappyjob == 1)
			{
			    new plata = 5000;
				new bonus = random(50);
				SCM(playerid, NARANCASTA,"Happy job: {FFFFFF}Posto je ukljucen Happy Job za posao kosac trave dobili ste duplu platu!");
				if(PI[playerid][pFirma] == 8 || PI[playerid][pZaposljen] == 8) { Plata(playerid, plata/2, bonus/2); }
				else { Plata(playerid, plata, bonus); }
				PI[playerid][pMehanicarOdvoz] = 360;
				DisablePlayerCheckpoint(playerid);
				JFirmaPlus(8, plata/2);
			}
			if(IsTrailerAttachedToVehicle(hvID))
			{
				h_DisablePlayerCheckpoint(playerid);
		     	new plata = 6500;
		       	new bonus = random(50);
	            SCMF(playerid, SVETLOZUTA, "(POSAO) {FFFFFF}Zaradili ste $%d od ovog automobila!", plata+bonus);
	            PlataNovacPlus(playerid, plata+bonus);
	       		JFirmaPlus(8, plata/2);
	       		MayorInfo[1][Budzet] += 5;
		        PI[playerid][pMehanicarOdvoz] = 360;
		        SetVehicleToRespawn(GetVehicleTrailer(GetPlayerVehicleID(playerid)));


I stavi tvoje varijable

Najjednostavniji nacin za duple place ti je:

if(happyjob == 1) plata = plata*2;

poslije sto si definirao new plata

znaci:

new plata = 5000;
if(happyjob == 1) plata = plata*2;

rjesio sam johny uzeo sam ovaj svoj nacin i radi mi
Respect to Muma187, Sivir, Ino420, Tosic, Shomy Script, σgí, [CG]Johnny, [WG]Danny
Alfa Gaming Community Owner & Skripter
Alfa Gaming mod edit:100%

Citat: [CG] Johnny poslato Februar 05, 2018, 19:43:39 POSLE PODNE
Najjednostavniji nacin za duple place ti je:

if(happyjob == 1) plata = plata*2;

poslije sto si definirao new plata

znaci:

new plata = 5000;
if(happyjob == 1) plata = plata*2;

sry za dp uzeo sam tvoj sistem mnogo je laksi i radi hvala ti :P @[CG]Johnny
Respect to Muma187, Sivir, Ino420, Tosic, Shomy Script, σgí, [CG]Johnny, [WG]Danny
Alfa Gaming Community Owner & Skripter
Alfa Gaming mod edit:100%