Advertisement
Guest User

Untitled

a guest
Jun 24th, 2019
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.60 KB | None | 0 0
  1. CMD:setcena(playerid, params[])
  2. {
  3.     if(PI[playerid][pAdmin] < 7 || dostup[playerid] == 0) return true;
  4.     new price, houseid;
  5.     if(sscanf(params, "ud", houseid, price)) return SendEsp(playerid, "/setcena [houseid] [cena]");
  6.     new query[512];
  7.     query = "UPDATE `houses` SET ";
  8.     acc_int_strcat(query, sizeof(query), "price", price);
  9.     strdel(query, strlen(query)-1, strlen(query));
  10.     format(strings, 100, " WHERE `id` = '%d' LIMIT 1", houseid);
  11.     strcat(query, strings);
  12.     mysql_tquery(connects, query, "", "");
  13.     SendClientMessage(playerid, -1, "Successfly");
  14.     return 1;
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement