Guest User

Untitled

a guest
Feb 6th, 2020
106
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. case DIALOG_HNAME: {
  2. if(response) {
  3. new bouse = PlayerInfo[playerid][pPhousekey],housename[250];
  4. if(PlayerInfo[playerid][pPhousekey] != 999 && strcmp(PlayerInfo[playerid][pNormalName], HouseInfo[PlayerInfo[playerid][pPhousekey]][hOwner], true) == 0)
  5. {
  6. new maxc = strlen(housename);
  7. if(maxc > 20) return SCM(playerid, COLOR_WHITE,"Maximum caracter is 20.");
  8. new housename2[250];
  9. mysql_real_escape_string(housename, housename2);
  10. strmid(HouseInfo[bouse][hDiscription], housename2, 0, 64, 255);
  11. format(string, sizeof(string), "House name set to: {008080}%s",HouseInfo[bouse][hDiscription]);
  12. SendClientMessage(playerid, COLOR_WHITE, string);
  13. new str[256];
  14. mysql_format(SQL,str,sizeof(str),"UPDATE houses SET Discription='%s' WHERE ID='%d'",HouseInfo[bouse][hDiscription],PlayerInfo[playerid][pPhousekey]);
  15. mysql_tquery(SQL,str,"","");
  16. OnPropTextdrawUpdate(1, bouse);
  17. }
  18. }
  19. return 1;
  20. }
RAW Paste Data