Skripta koju koristim:BU R2
Detaljan opis problema:Ovako kada kucam /sellgun igracu se daje oruzije i odu materijali ali oruzije pise da je dato ali ga nema ...?! neznam zasto tako isto kada kucam preko Admin komande /givegun ID Oruzije ...igracu dam oruzije ali ga on nedobije....Takodjer kada igrac kuca /sellgun samo moze dobiti Palicu,Noz,M4 nista vise? zasto😕?
Dio skripte: // (Unknown)
Neke slike/video za lakse dobivanje pomoci(neobavezno): Slika Bug-a
[Pomoc] Oruzije+Slika
1,061
pregleda
21
postova
14. Apr. 2012.
14. Apr. 2012.
E vidis to je problem sto pise da je sve uredu i da bi trebalo raditi mozeli biti do toga da je zabranjeno putem neke komande da se ima to oruzije u rukama? nekontam! ☹️
14. Apr. 2012.
Adnan Lord wrote on April 14, 2012, 8:46 am:
E vidis to je problem sto pise da je sve uredu i da bi trebalo raditi mozeli biti do toga da je zabranjeno putem neke komande da se ima to oruzije u rukama? nekontam! ☹️
14. Apr. 2012.
if(strcmp(cmd,"/sellgun",true)==0 || strcmp(cmd,"/prodajoruzije",true)==0)
{
if(IsPlayerConnected(playerid))
{
if (PlayerInfo != 9)
{
SendClientMessage(playerid,COLOR_GREY," Niste Diler Oruzija !");
return 1;
}
new x_weapon,weapon,ammo,price;
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD1, "Koriscenje: /prodajoruzije [ID Igraca/Dio Imena] [ime oruzija]");
SendClientMessage(playerid, COLOR_GREY, "Oruzije: noz(50) palica(50) cvijece(25) sdpistolj(50) dezert(100)");
SendClientMessage(playerid, COLOR_GREY, "Oruzije: hekler(200) pumparica(200) kalas(500) m4(500) puska (500)");
return 1;
}
giveplayerid = ReturnUser(tmp);
if (IsPlayerConnected(giveplayerid))
{
if(PlayerInfo < 2)
{
SendClientMessage(playerid, COLOR_GREY, " Igrac mora biti minimum lvl 2! ");
return 1;
}
if(giveplayerid != INVALID_PLAYER_ID)
{
x_weapon = strtok(cmdtext, idx);
if(!strlen(x_weapon))
{
SendClientMessage(playerid, COLOR_GREEN, "________________________________________________");
SendClientMessage(playerid, COLOR_WHITE, "*** Prodaja Oruzija ***");
SendClientMessage(playerid, COLOR_GREY, "Koriscenje: /prodajoruzije [ID Igraca/Dio Imena] [ime oruzija]");
SendClientMessage(playerid, COLOR_GREY, "Oruzije: noz(50) palica(50) cvijece(25) sdpistolj(50) dezert(100)");
SendClientMessage(playerid, COLOR_GREY, "Oruzije: hekler(200) pumparica(200) kalas(500) m4(500) puska (500) snajper (1500)");
SendClientMessage(playerid, COLOR_GREEN, "________________________________________________");
return 1;
}
}
if(strcmp(x_weapon,"noz",true) == 0) { if(PlayerInfo > 49) { weapon = 4; price = 50; ammo = 1; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"palica",true) == 0) { if(PlayerInfo > 49) { weapon = 5; price = 50; ammo = 1; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"sdpistolj",true) == 0) { if(PlayerInfo > 49) { weapon = 23; price = 50; ammo = 50; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"cvijece",true) == 0) { if(PlayerInfo > 24) { weapon = 14; price = 25; ammo = 1; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"dezert",true) == 0) { if(PlayerInfo > 99) { weapon = 24; price = 100; ammo = 50; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"hekler",true) == 0) { if(!PlayerToPoint(15.0,playerid,1484.3933,-1731.2124,6.7213)) { SendClientMessage(playerid, COLOR_GREY, " Ovo oruzije mozete prodati samo na Crnom Trzistu !"); return 1; } if(PlayerInfo > 199) { weapon = 29; price = 200; ammo = 200; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"pumparica",true) == 0) { if(!PlayerToPoint(15.0,playerid,1484.3933,-1731.2124,6.7213)) { SendClientMessage(playerid, COLOR_GREY, " Ovo oruzije mozete prodati samo na Crnom Trzistu !"); return 1; } if(PlayerInfo > 199) { weapon = 25; price = 200; ammo = 50; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
//else if(strcmp(x_weapon,"spas12",true) == 0) { if(PlayerInfo > 599) { weapon = 27; price = 600; ammo = 50; } else { SendClientMessage(playerid,COLOR_GREY," Not enough Materials for that Weapon!"); return 1; } }
else if(strcmp(x_weapon,"kalas",true) == 0) { if(!PlayerToPoint(15.0,playerid,1484.3933,-1731.2124,6.7213)) { SendClientMessage(playerid, COLOR_GREY, " Ovo oruzije mozete prodati samo na Crnom Trzistu !"); return 1; } if(PlayerInfo > 499) { weapon = 30; price = 500; ammo = 250; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"m4",true) == 0) { if(!PlayerToPoint(15.0,playerid,1484.3933,-1731.2124,6.7213)) { SendClientMessage(playerid, COLOR_GREY, " Ovo oruzije mozete prodati samo na Crnom Trzistu !"); return 1; } if(PlayerInfo > 499) { weapon = 31; price = 500; ammo = 250; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"puska",true) == 0) { if(!PlayerToPoint(15.0,playerid,1484.3933,-1731.2124,6.7213)) { SendClientMessage(playerid, COLOR_GREY, " Ovo oruzije mozete prodati samo na Crnom Trzistu !"); return 1; } if(PlayerInfo > 499) { weapon = 33; price = 500; ammo = 50; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"snajper",true) == 0) { if(!PlayerToPoint(15.0,playerid,1484.3933,-1731.2124,6.7213)) { SendClientMessage(playerid, COLOR_GREY, " Ovo oruzije mozete prodati samo na Crnom Trzistu !"); return 1; } if(PlayerInfo > 1499) { weapon = 34; price = 1500; ammo = 50; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else { SendClientMessage(playerid,COLOR_GREY," Nepravilno ime oruzija!"); return 1; }
if (ProxDetectorS(5.0, playerid, giveplayerid))
{
/*if(giveplayerid == playerid)
{
SendClientMessage(playerid, COLOR_GRAD1, " You can not sell Guns to yourself!");
return 1;
}*/
if(PlayerInfo > 0)
{
new skill = 2 * PlayerInfo;
new mats = price / 100;
price -= (mats)*(skill);
}
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), " Dali ste %s-u %s sa %d municije, za %d materijala.", giveplayer,x_weapon, ammo, price);
PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
SendClientMessage(playerid, COLOR_GRAD1, string);
format(string, sizeof(string), " Primili ste %s sa %d municije od %s-a.", x_weapon, ammo, sendername);
SendClientMessage(giveplayerid, COLOR_GRAD1, string);
PlayerPlaySound(giveplayerid, 1052, 0.0, 0.0, 0.0);
new gunname;
GetWeaponName(weapon, gunname, sizeof(gunname));
format(string, sizeof(string), "* %s daje %s %s-u.", sendername, gunname,giveplayer);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
SafeGivePlayerWeapon(giveplayerid,weapon,ammo);
PlayerInfo -= price;
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " Predaleko ste.");
return 1;
}
}
else
{
format(string, sizeof(string), " %d nije aktivan igrac.", giveplayerid);
SendClientMessage(playerid, COLOR_GRAD1, string);
}
}
return 1;
}14. Apr. 2012.
if(strcmp(cmd,"/sellgun",true)==0 || strcmp(cmd,"/napravioruzije",true)==0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo == 6 || PlayerInfo == 5 || PlayerInfo == 15 || PlayerInfo == 16 || PlayerInfo == 6 || PlayerInfo == 5 || PlayerInfo == 15 || PlayerInfo == 16)
{
new x_weapon,weapon,ammo,price;
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_LIGHTRED, ": {FFFFFF}/sellgun [ID Igraca/Dio Imena] [ime oruzija]");
SendClientMessage(playerid, COLOR_LIGHTRED, ": {FFFFFF}noz(50) palica(50) sdpistolj(50) dezert(100) m4(500)");
SendClientMessage(playerid, COLOR_LIGHTRED, ": {FFFFFF}hekler(200) pumparica(200) puska (250) kalas(500) snajper (1500)");
return 1;
}
giveplayerid = ReturnUser(tmp);
if (IsPlayerConnected(giveplayerid))
{
if(PlayerInfo < 2)
{
SendClientMessage(playerid, COLOR_LIGHTRED, "{FFFFFF}Igrac mora biti minimum level 2! ");
return 1;
}
if(giveplayerid != INVALID_PLAYER_ID)
{
x_weapon = strtok(cmdtext, idx);
if(!strlen(x_weapon))
{
SendClientMessage(playerid, COLOR_LIGHTRED, ": {FFFFFF}/sellgun [ID Igraca/Dio Imena] [ime oruzija]");
SendClientMessage(playerid, COLOR_LIGHTRED, ": {FFFFFF}noz(50) palica(50) sdpistolj(50) dezert(100) m4(500)");
SendClientMessage(playerid, COLOR_LIGHTRED, ": {FFFFFF}hekler(200) pumparica(200) puska (250) kalas(500) snajper (1500)");
return 1;
}
}
if(strcmp(x_weapon,"noz",true) == 0) { if(PlayerInfo > 50) { weapon = 4; price = 50; ammo = 1; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"palica",true) == 0) { if(PlayerInfo > 50) { weapon = 5; price = 50; ammo = 1; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"sdpistolj",true) == 0) { if(PlayerInfo > 50) { weapon = 23; price = 50; ammo = 50; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"dezert",true) == 0) { if(PlayerInfo > 100) { weapon = 24; price = 100; ammo = 50; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"hekler",true) == 0) { if(PlayerInfo > 200) { weapon = 29; price = 200; ammo = 150; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"pumparica",true) == 0) { if(PlayerInfo > 200) { weapon = 25; price = 200; ammo = 100; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"kalas",true) == 0) { if(PlayerInfo > 500) { weapon = 30; price = 500; ammo = 200; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"m4",true) == 0) { if(PlayerInfo > 500) { weapon = 31; price = 500; ammo = 200; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"puska",true) == 0) { if(PlayerInfo > 250) { weapon = 33; price = 250; ammo = 60; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else if(strcmp(x_weapon,"snajper",true) == 0) { if(PlayerInfo > 500) { weapon = 34; price = 500; ammo = 40; } else { SendClientMessage(playerid,COLOR_GREY," Nemate dovoljno materijala za to oruzije!"); return 1; } }
else { SendClientMessage(playerid,COLOR_GREY,"Nepravilno ime oruzija!"); return 1; }
if (ProxDetectorS(5.0, playerid, giveplayerid))
{
if(PlayerInfo > 0)
{
new skill = 2 * PlayerInfo;
new mats = price / 100;
price -= (mats)*(skill);
}
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "Dali ste %s-u %s sa %d municije, za %d materijala.", giveplayer,x_weapon, ammo, price);
PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
SendClientMessage(playerid, COLOR_LIGHTRED, string);
format(string, sizeof(string), "Primili ste %s sa %d municije od %s-a.", x_weapon, ammo, sendername);
SendClientMessage(giveplayerid, COLOR_LIGHTRED, string);
PlayerPlaySound(giveplayerid, 1052, 0.0, 0.0, 0.0);
new gunname;
GetWeaponName(weapon, gunname, sizeof(gunname));
format(string, sizeof(string), "* %s daje %s %s-u.", sendername, gunname,giveplayer);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
SafeJBC_GivePlayerWeapon(giveplayerid,weapon,ammo);
PlayerInfo -= price;
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " Predaleko ste.");
return 1;
}
}
else
{
format(string, sizeof(string), " %d nije aktivan igrac.", giveplayerid);
SendClientMessage(playerid, COLOR_GRAD1, string);
}
}
else return SendClientMessage(playerid, COLOR_GRAD1, "Niste clan Mafije | Bande !"); }
return 1;
}14. Apr. 2012.
Ako se nevaram fali ili #define ili Forward? neznam daj help brzo majke ti moram ovo open!
Evo ga samo 1error!
Evo ga samo 1error!
error 017: undefined symbol "SafeJBC_GivePlayerWeapon"14. Apr. 2012.
Adnan Lord wrote on April 14, 2012, 9:26 am:
Ako se nevaram fali ili #define ili Forward? neznam daj help brzo majke ti moram ovo open!
Evo ga samo 1error!
Evo ga samo 1error!
error 017: undefined symbol "SafeJBC_GivePlayerWeapon"GivePlayerWeapon ili SafeGivePlayerWeapon Zavisi kako koristiš.. Vidi na npr komandi /buygun ...Shot Caller
Novi Član
90 / 100 XP
🌱Početnik(0)
145
Postovi:
35
Teme:
Pridružio se:Feb. 2011
14. Apr. 2012.
Vegas: Izbaci kamaru Errora kada promjenim ...
Johnny: Daj kako da uradim Define!? dont know!
Johnny: Daj kako da uradim Define!? dont know!
SafeJBC_GivePlayerWeapon(giveplayerid,weapon,ammo);Shot Caller
Novi Član
90 / 100 XP
🌱Početnik(0)
145
Postovi:
35
Teme:
Pridružio se:Feb. 2011
14. Apr. 2012.
New nace uradio sam #define ..stavi mi 6errora + nece da pokrene JBC , JB imam define ali neznam zasto nece cak sam i forward uradio nece! 😕 😕 😕 ☹️
Pokusati cu delete pa cu uci test moze biti da nije do komande 😠 😠 😠
Pokusati cu delete pa cu uci test moze biti da nije do komande 😠 😠 😠
Shot Caller
Novi Član
90 / 100 XP
🌱Početnik(0)
145
Postovi:
35
Teme:
Pridružio se:Feb. 2011
14. Apr. 2012.
Probaj da ovu komandu
/*SafeJBC_GivePlayerWeapon(giveplayerid,weapon,ammo);*/ ODTRANIS
/*SafeJBC_GivePlayerWeapon(giveplayerid,weapon,ammo);*/ ODTRANIS
14. Apr. 2012.
Johnny: odstranio sam radi sve lijepo ali nemogu da vjerujem ovo! 😕 😕 😕 😕 😕
(LINK CLICK) NEVJEROVATNO
--> Komanda radi
--> Ali opet ista stvar ☹️
(LINK CLICK) NEVJEROVATNO
--> Komanda radi
--> Ali opet ista stvar ☹️
14. Apr. 2012.
||¤ Johnny ¤|| wrote on April 14, 2012, 9:40 am:
Probaj na vrh skripte
new SafeJBC_GivePlayerWeapon
new SafeJBC_GivePlayerWeapon
WTF?
OMG?
STA?
Nemogu da verujem,varijabla za junkbuster je SafeJB(a ne SafeJBC)
U komandu gde ti je SafeJBC_GivePlayerWeapon stavi SafeJB_GivePlayerWeapon i mora raditi !!
Morate biti prijavljeni da biste odgovorili na ovu temu.
Prijava