22.11.2016, 22:14
PHP код:
if(PlayerData[playerid][FonduriEuro] < PRETCASANOUA) return SendClientMessage(playerid, COLOR_YELLOW2, "Nu ai destule fonduri");
PlayerData[playerid][FonduriEuro] = PlayerData[playerid][FonduriEuro] - PRETCASANOUA;
titles = "Ai cumparat o casa ";
strings = "{FFFFFF}Tocmai ai achizitionat o casa din itemshop,multumim\n";
strcat(strings, "{FFFFFF}Te rugam sa faci un {FF3300}PRINTSCREEN[F8]{FFFFFF} si sa contactezi un owner pentru detalii\n");
new str[128];
mysql_format(SQL, str,128,"UPDATE `users` SET `FonduriEuro`='%d' WHERE `ID`='%d' LIMIT 1",PlayerData[playerid][FonduriEuro],PlayerData[playerid]);
mysql_tquery(SQL, str, "", "");
new stringcumparare[128];
format(stringcumparare, sizeof(stringcumparare), "ITEM-SHOP: %s si-a cumparat o casa noua din item-shop.", PlayerData[playerid][Name]);
ABroadCast(RED,stringcumparare,1);
ShowPlayerDialog(playerid, DIALOG_ITEMSHOP, DIALOG_STYLE_MSGBOX,titles,strings,"Ok","");