09.06.2013, 05:59
Try this
pawn Код:
if(listitem == 5) // Gate
{
new string[42], giveplayerid, shopstring[512];
if(PlayerInfo[playerid][pCredits] < 100)
{
return SendClientMessageEx(playerid, COLOR_GREY, " You do not have enough Credits !");
}
else
{
new PName[MAX_PLAYER_NAME];
GetPlayerName(giveplayerid, PName, sizeof(PName));
PlayerInfo[playerid][pCredits] = PlayerInfo[playerid][pCredits]-100;
format(string, sizeof(string), "[CreditShop]: %s has exchanged 100 credits for a house. Please issue it now.", PName);
ShopTechBroadCast(COLOR_SHOP, string);
return SendClientMessageEx(playerid, COLOR_GREY, " You exchanged 100 Credits for a house gate. !");
}
}