Problem with Skill Arms Dealer
#1

I did the Arms Dealer skill system but I have problems in order

I wanted to make the skill a 500k to pay for materials iarl 1k 2 2k for 1000 of skills and materials so
But it does not work, it takes only a skill for the skill even if there are two
I want to take the skill one one particular program, and so on up to five skill

Quote:

if(strcmp(cmd,"/materials",true)==0)
{
if(IsPlayerConnected(playerid))
{
if (PlayerInfo[playerid][pJob] != 9)
{
SendClientMessage(playerid,COLOR_SG_GRAD2," ** You are not a Arms Dealer.");
return 1;
}
new x_nr[256];
x_nr = strtok(cmdtext, idx);
if(!strlen(x_nr)) {
SendClientMessage(playerid, COLOR_SG_SYNTAX, "Syntax: /materials [name]");
SendClientMessage(playerid, COLOR_CRS3, "Disponibile: Get, Deliver.");
return 1;
}
if(strcmp(x_nr,"get",true) == 0)
{
if(PlayerToPoint(3.0,playerid,2770.5027,-1628.2980,12.1775))
{
if(PlayerInfo[playerid][pMatsLic] > 0)
{
if(MatsHolding[playerid] >= 10)
{
SendClientMessage(playerid, COLOR_GREY, "** Nu poti lua decat un pachet.");
return 1;
}
new level = PlayerInfo[playerid][pJackSkill];
if(level >= 0 && level <= 50)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai luat 10 Pachete de Materiale cu 1.000$!");
GivePlayerCash(playerid, -1000);
MatsHolding[playerid] = 10;
}
else if(level >= 51 && level <= 100)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai luat 20 Pachete de Materiale cu 2.000$!");
GivePlayerCash(playerid, -2000);
MatsHolding[playerid] = 20;
}
else if(level >= 101 && level <= 200)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai luat 30 Pachete de Materiale cu 3.000$!");
GivePlayerCash(playerid, -3000);
MatsHolding[playerid] = 30;
}
else if(level >= 201 && level <= 400)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai luat 40 Pachete de Materiale cu 4.000$!");
GivePlayerCash(playerid, -4000);
MatsHolding[playerid] = 40;
}
else if(level >= 401)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai luat 50 Pachete de Materiale cu 5.000$!");
GivePlayerCash(playerid, -5000);
MatsHolding[playerid] = 50;
}
}
else
{
SendClientMessage(playerid, COLOR_SG_MATS, "** Nu detii licenta de Materiale.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_SG_MATS, "** You are not at the Materials Package Building in Los Santos !");
return 1;
}
}
else if(strcmp(x_nr,"deliver",true) == 0)
{
if(PlayerToPoint(3.0,playerid,1712.9625,913.9552,1 0.8203))
{
if(PlayerInfo[playerid][pMatsLic] > 0)
{
if(MatsHolding[playerid] > 0)
{
new level = PlayerInfo[playerid][pJackSkill];
if(level >= 0 && level <= 50)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai primit 500 Materiale pentru 1.000$ !");
PlayerInfo[playerid][pMats] += 500;
MatsHolding[playerid] = 0;
PlayerInfo[playerid][pArmsSkill] ++;
if(PlayerInfo[DrugOffer[playerid]][pArmsSkill] == 50)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 2."); }
else if(PlayerInfo[playerid][pArmsSkill] == 100)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 3."); }
else if(PlayerInfo[playerid][pArmsSkill] == 200)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 4."); }
else if(PlayerInfo[playerid][pArmsSkill] == 400)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 5."); }
}
else if(level >= 51 && level <= 100)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai primit 500 Materiale pentru 2.000$ !");
PlayerInfo[playerid][pMats] += 1000;
MatsHolding[playerid] = 0;
PlayerInfo[playerid][pArmsSkill] ++;
if(PlayerInfo[DrugOffer[playerid]][pArmsSkill] == 50)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 2."); }
else if(PlayerInfo[playerid][pArmsSkill] == 100)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 3."); }
else if(PlayerInfo[playerid][pArmsSkill] == 200)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 4."); }
else if(PlayerInfo[playerid][pArmsSkill] == 400)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 5."); }
}
else if(level >= 101 && level <= 200)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai primit 500 Materiale pentru 3.000$ !");
PlayerInfo[playerid][pMats] += 1500;
MatsHolding[playerid] = 0;
PlayerInfo[playerid][pArmsSkill] ++;
if(PlayerInfo[DrugOffer[playerid]][pArmsSkill] == 50)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 2."); }
else if(PlayerInfo[playerid][pArmsSkill] == 100)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 3."); }
else if(PlayerInfo[playerid][pArmsSkill] == 200)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 4."); }
else if(PlayerInfo[playerid][pArmsSkill] == 400)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 5."); }
}
else if(level >= 201 && level <= 400)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai primit 500 Materiale pentru 4.000$ !");
PlayerInfo[playerid][pMats] += 2000;
MatsHolding[playerid] = 0;
PlayerInfo[playerid][pArmsSkill] ++;
if(PlayerInfo[DrugOffer[playerid]][pArmsSkill] == 50)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 2."); }
else if(PlayerInfo[playerid][pArmsSkill] == 100)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 3."); }
else if(PlayerInfo[playerid][pArmsSkill] == 200)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 4."); }
else if(PlayerInfo[playerid][pArmsSkill] == 400)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 5."); }
}
else if(level >= 401)
{
SendClientMessage(playerid, COLOR_GREY, "** Ai primit 500 Materiale pentru 5.000$ !");
PlayerInfo[playerid][pMats] += 2500;
MatsHolding[playerid] = 0;
PlayerInfo[playerid][pArmsSkill] ++;
if(PlayerInfo[DrugOffer[playerid]][pArmsSkill] == 50)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 2."); }
else if(PlayerInfo[playerid][pArmsSkill] == 100)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 3."); }
else if(PlayerInfo[playerid][pArmsSkill] == 200)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 4."); }
else if(PlayerInfo[playerid][pArmsSkill] == 400)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Arms Dealer Skill is now Level 5."); }
}
}
else
{
SendClientMessage(playerid, COLOR_GREY, "** Nu ai luat Pachetul de la Materials Get Los Santos.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_SG_MATS, "** Nu detii licenta de Materiale.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_SG_MATS, "** Locul de unde primesti Materialele este in Las Venturas.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_GREY, "** Invalid Materials Name !");
return 1;
}
}
return 1;
}

Reply
#2

?//??//?plss help me
Reply
#3

rezolved TOPIC CLOSED pls
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)