armor storing on gui
#1

pawn Код:
if(dialogid == 15)
{
if(response)
{
new plyName[MAX_PLAYER_NAME];
new bouse = PlayerInfo[playerid][pHouseKey];

GetPlayerName(playerid, plyName, MAX_PLAYER_NAME);
new Float:plyArmour;
GetPlayerArmour(playerid, plyArmour);
new amount =  strval(inputtext);

SetPlayerArmour(playerid, -sarvaipadeti);
Houses[bouse][Armour]=Houses[bouse][Armour]+amount;
new string[126];
format(string, sizeof(string), "stored %s", amount);
SendClientMessage(playerid, 0xAFAFAFAA, string);
}
return 1;
}
Okay i'm trying to put armour with gui.. But server are not detecting what did i write in gui.. I mean i write 50, server says 2.. Somthing is wrong with detection.. Poor english sorry..
Reply
#2

pawn Код:
new float: total;
GetPlayerArmour(playerid, total);
SetPlayerArmour(playerid, (total - w/e amoount));
i think..
Reply
#3

nope
Reply
#4

pawn Код:
if(dialogid == 15)
{
    if(response)
    {
        new plyName[MAX_PLAYER_NAME];
        new bouse = PlayerInfo[playerid][pHouseKey];

        GetPlayerName(playerid, plyName, MAX_PLAYER_NAME);
        new Float:plyArmour;
        GetPlayerArmour(playerid, plyArmour);
        new amount = strval(inputtext);

        SetPlayerArmour(playerid, plyArmour-amount);
        Houses[bouse][Armour] += amount;
        new string[126];
        format(string, sizeof(string), "stored %d", amount);
        SendClientMessage(playerid, 0xAFAFAFAA, string);
    }
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)