What I'm doing wrong here ?
#1

Not fixed, Never mind.
Reply
#2

pawn Код:
if (!strcmp("3", tmp, true)) if(Logged[playerid] == 1)
{
    if(GetPlayerecard(playerid) > 3) return SendClientMessage(playerid,c_r,"( ! ) You lack the items required !");
    //Code which gives Silver here works.
    SaveBag(playerid);
    ecardd[playerid] -= 3 // This code doesn't work, It doesn't take 3 ecard from the bag.
    SendClientMessage(playerid,COLOR_GREEN,"( ! ) You have gotten 1 Silver medal !");
    return 1;
}

// you can also use += for addition
// so ecardd[playerid] += 3 would add 3 "ecards"
Reply
#3

----
Reply
#4

pawn Код:
#define GivePlayerecard(%0,%1) ecardd[%0] += (%1)
Reply
#5

try this

Код:
if (!strcmp("3", tmp, true)) 
    {
    if(Logged[playerid] == 1) return SendClientMessage(playerid, -1,"( ! ) You aren't login !");
    if(GetPlayerecard(playerid) > 3) return SendClientMessage(playerid,c_r,"( ! ) You lack the items required !");
    //Code which gives Silver here works.
    SaveBag(playerid);
    GivePlayerecard(playerid,-3); // This code doesn't work, It doesn't take 3 ecard from the bag.
    SendClientMessage(playerid,COLOR_GREEN,"( ! ) You have gotten 1 Silver medal !");
    return 1;
    }
Reply
#6

----
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)