Адель Нурутдинов
Новичок
Никак не сохраняет сейф,вот что в логах MYSQL
и так каждый дом,в БД записи не делает
вот сток с сохранением дома:
Загрузку сейфов.если ввести в базе,делает,вот диалог с сейфом самим:
PHP:
(error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '1'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '2'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '3'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '4'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '5'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '6'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '7'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '8'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '9'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '10'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '11'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '12'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '13'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '14'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '15'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '16'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '17'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '18'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '19'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '20'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '21'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '22'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '23'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '24'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '25'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '26'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '27'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '28'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '29'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '30'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '31'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '32'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '33'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '34'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '35'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '36'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '37'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '38'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '39'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '40'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '41'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '42'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '43'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '44'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '45'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '46'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '47'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '48'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '49'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '50'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '51'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '52'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '53'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '54'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '55'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '56'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '57'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '58'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '59'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '60'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '61'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '62'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '63'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '64'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '65'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '66'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '67'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '68'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '69'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '70'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '71'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '72'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '73'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '74'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '75'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '76'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '77'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '78'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '79'' at line 1
[21:30:33] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`Safe`= '0, 0, 0, 0, 0, 0, 0, 0' WHERE hID = '80'' at line 1
вот сток с сохранением дома:
PHP:
stock SaveHouse(id)
{
new temp[1024];
mysql_format(DATABASE, QUERY, sizeof(QUERY), "UPDATE `house` SET ");
format(temp,sizeof(temp),"`hEntrx`= '%f',",HouseInfo[id][hEntr][0]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hEntry`= '%f',",HouseInfo[id][hEntr][1]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hEntrz`= '%f',",HouseInfo[id][hEntr][2]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hExitx`= '%f',",HouseInfo[id][hExit][0]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hExity`= '%f',",HouseInfo[id][hExit][1]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hExitz`= '%f',",HouseInfo[id][hExit][2]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hOwner`= '%s',",HouseInfo[id][hOwner]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hDiscript`= '%i',",HouseInfo[id][hDiscript]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hPrice`= '%i',",HouseInfo[id][hPrice]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hOplata`= '%i',",HouseInfo[id][hOplata]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hInt`= '%i',",HouseInfo[id][hInt]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hLock`= '%i',",HouseInfo[id][hLock]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hHeal`= '%i',",HouseInfo[id][hHeal]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hBuyPrice`= '%i',",HouseInfo[id][hBuyPrice]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hCarx`= '%f',",HouseInfo[id][hCar][0]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hCary`= '%f',",HouseInfo[id][hCar][1]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hCarz`= '%f',",HouseInfo[id][hCar][2]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`hCara`= '%f'",HouseInfo[id][hCar][3]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp),"`Safe`= '%i, %i, %i, %i, %i, %i, %i, %i'",HouseInfo[id][Safe][0],HouseInfo[id][Safe][1],HouseInfo[id][Safe][2],
HouseInfo[id][Safe][3],HouseInfo[id][Safe][4],HouseInfo[id][Safe][5],HouseInfo[id][Safe][6],HouseInfo[id][Safe][7]);strcat(QUERY,temp,sizeof(QUERY));
format(temp,sizeof(temp)," WHERE hID = '%i'",HouseInfo[id][hID]);strcat(QUERY,temp,sizeof(QUERY));
mysql_function_query(DATABASE, QUERY, true, "", "");
return true;
}
PHP:
case D_SAFE:
{
if(!response) return true;
new string[256];
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
format(string, sizeof(string), "Наркотики: %d/2000\nSdPistol: %d/1000\nDeagle: %d/500\nShotGun: %d/500\nSMG: %d/5000\nAK-47: %d/5000\nM4: %d/5000\nRifle: %d/200",
HouseInfo[i][Safe][0], HouseInfo[i][Safe][1], HouseInfo[i][Safe][2], HouseInfo[i][Safe][3], HouseInfo[i][Safe][4], HouseInfo[i][Safe][5], HouseInfo[i][Safe][6], HouseInfo[i][Safe][7]);
switch(listitem)
{
case 0: ShowPlayerDialog(playerid, D_SAFE+1, DIALOG_STYLE_LIST, "Сейф", string, "Взять", "Отмена");
case 1: ShowPlayerDialog(playerid, D_SAFE+2, DIALOG_STYLE_LIST, "Сейф", string, "Положить", "Отмена");
}
return true;
}
case D_SAFE+1:
{
if(!response) return true;
new string[256];
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
format(string, sizeof(string), "Наркотики: %d/2000\nSdPistol: %d/1000\nDeagle: %d/500\nShotGun: %d/500\nSMG: %d/5000\nAK-47: %d/5000\nM4: %d/5000\nRifle: %d/200",
HouseInfo[i][Safe][0], HouseInfo[i][Safe][1], HouseInfo[i][Safe][2], HouseInfo[i][Safe][3], HouseInfo[i][Safe][4], HouseInfo[i][Safe][5], HouseInfo[i][Safe][6], HouseInfo[i][Safe][7]);
switch(listitem)
{
case 0: ShowPlayerDialog(playerid, D_SAFE+3, DIALOG_STYLE_INPUT, "Наркотики", "Введите кол-во наркотиков (От 1 до 2000)", "Взять", "Отмена");
case 1: ShowPlayerDialog(playerid, D_SAFE+4, DIALOG_STYLE_INPUT, "SDPistol", "Введите кол-во патрон (От 1 до 1000)", "Взять", "Отмена");
case 2: ShowPlayerDialog(playerid, D_SAFE+5, DIALOG_STYLE_INPUT, "Deagle", "Введите кол-во патрон (От 1 до 500)", "Взять", "Отмена");
case 3: ShowPlayerDialog(playerid, D_SAFE+6, DIALOG_STYLE_INPUT, "ShotGun", "Введите кол-во патрон (От 1 до 500)", "Взять", "Отмена");
case 4: ShowPlayerDialog(playerid, D_SAFE+7, DIALOG_STYLE_INPUT, "SMG", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
case 5: ShowPlayerDialog(playerid, D_SAFE+8, DIALOG_STYLE_INPUT, "AK-47", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
case 6: ShowPlayerDialog(playerid, D_SAFE+9, DIALOG_STYLE_INPUT, "M4", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
case 7: ShowPlayerDialog(playerid, D_SAFE+10, DIALOG_STYLE_INPUT, "Rifle", "Введите кол-во патрон (От 1 до 200)", "Взять", "Отмена");
}
return true;
}
case D_SAFE+2:
{
if(!response) return true;
new string[256];
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
format(string, sizeof(string), "Наркотики: %d/2000\nSdPistol: %d/1000\nDeagle: %d/500\nShotGun: %d/500\nSMG: %d/5000\nAK-47: %d/5000\nM4: %d/5000\nRifle: %d/200",
HouseInfo[i][Safe][0], HouseInfo[i][Safe][1], HouseInfo[i][Safe][2], HouseInfo[i][Safe][3], HouseInfo[i][Safe][4], HouseInfo[i][Safe][5], HouseInfo[i][Safe][6], HouseInfo[i][Safe][7]);
switch(listitem)
{
case 0: ShowPlayerDialog(playerid, D_SAFE+11, DIALOG_STYLE_INPUT, "Наркотики", "Введите кол-во наркотиков (От 1 до 2000)", "Положить", "Отмена");
case 1: ShowPlayerDialog(playerid, D_SAFE+12, DIALOG_STYLE_INPUT, "SDPistol", "Введите кол-во патрон (От 1 до 1000)", "Положить", "Отмена");
case 2: ShowPlayerDialog(playerid, D_SAFE+13, DIALOG_STYLE_INPUT, "Deagle", "Введите кол-во патрон (От 1 до 500)", "Положить", "Отмена");
case 3: ShowPlayerDialog(playerid, D_SAFE+14, DIALOG_STYLE_INPUT, "ShotGun", "Введите кол-во патрон (От 1 до 500)", "Положить", "Отмена");
case 4: ShowPlayerDialog(playerid, D_SAFE+15, DIALOG_STYLE_INPUT, "SMG", "Введите кол-во патрон (От 1 до 5000)", "Положить", "Отмена");
case 5: ShowPlayerDialog(playerid, D_SAFE+16, DIALOG_STYLE_INPUT, "AK-47", "Введите кол-во патрон (От 1 до 5000)", "Положить", "Отмена");
case 6: ShowPlayerDialog(playerid, D_SAFE+17, DIALOG_STYLE_INPUT, "M4", "Введите кол-во патрон (От 1 до 5000)", "Положить", "Отмена");
case 7: ShowPlayerDialog(playerid, D_SAFE+18, DIALOG_STYLE_INPUT, "Rifle", "Введите кол-во патрон (От 1 до 200)", "Положить", "Отмена");
}
return true;
}
case D_SAFE+3:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+3, DIALOG_STYLE_INPUT, "Наркотики", "Введите кол-во наркотиков (От 1 до 2000)", "Взять", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 2000) return ShowPlayerDialog(playerid, D_SAFE+3, DIALOG_STYLE_INPUT, "Наркотики", "Введите кол-во наркотиков (От 1 до 2000)", "Взять", "Отмена");
if(HouseInfo[i][Safe][0] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+3, DIALOG_STYLE_INPUT, "Наркотики", "У вас нет такого кол-ва в сейфе\n\nВведите кол-во наркотиков (От 1 до 2000)", "Взять", "Отмена");
if(User[playerid][Drug][0]+strval(inputtext) > 300 && User[playerid][Upgrade][0] == 1 || User[playerid][Drug][0]+strval(inputtext) > 150 && User[playerid][Upgrade][0] == 0) return ShowPlayerDialog(playerid, D_SAFE+3, DIALOG_STYLE_INPUT, "Наркотики", "Вы не можете унести такое кол-во наркотиков\n\nВведите кол-во наркотиков (От 1 до 2000)", "Взять", "Отмена");
HouseInfo[i][Safe][0] -= strval(inputtext);
User[playerid][Drug][0] += strval(inputtext);
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы взяли {ffffff}%d {ffff00}наркотиков из сейфа.", strval(inputtext));
return true;
}
case D_SAFE+4:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+4, DIALOG_STYLE_INPUT, "SDPistol", "Введите кол-во патрон (От 1 до 1000)", "Взять", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 1000) return ShowPlayerDialog(playerid, D_SAFE+4, DIALOG_STYLE_INPUT, "SDPistol", "Введите кол-во патрон (От 1 до 1000)", "Взять", "Отмена");
if(HouseInfo[i][Safe][1] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+4, DIALOG_STYLE_INPUT, "SDPistol", "У вас нет такого кол-ва патрон\n\nВведите кол-во патрон (От 1 до 1000)", "Взять", "Отмена");
HouseInfo[i][Safe][1] -= strval(inputtext);
GiveWeapon(playerid, 23, strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы взяли {ffffff}%d {ffff00}патрон(ов)/(а) SDPistol из сейфа.", strval(inputtext));
return true;
}
case D_SAFE+5:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+5, DIALOG_STYLE_INPUT, "Deagle", "Введите кол-во патрон (От 1 до 500)", "Взять", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 500) return ShowPlayerDialog(playerid, D_SAFE+5, DIALOG_STYLE_INPUT, "Deagle", "Введите кол-во патрон (От 1 до 500)", "Взять", "Отмена");
if(HouseInfo[i][Safe][2] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+5, DIALOG_STYLE_INPUT, "Deagle", "У вас нет такого кол-ва патрон\n\nВведите кол-во патрон (От 1 до 500)", "Взять", "Отмена");
HouseInfo[i][Safe][2] -= strval(inputtext);
GiveWeapon(playerid, 24, strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы взяли {ffffff}%d {ffff00}патрон(ов)/(а) Deagle из сейфа.", strval(inputtext));
return true;
}
case D_SAFE+6:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+6, DIALOG_STYLE_INPUT, "ShotGun", "Введите кол-во патрон (От 1 до 500)", "Взять", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 500) return ShowPlayerDialog(playerid, D_SAFE+6, DIALOG_STYLE_INPUT, "ShotGun", "Введите кол-во патрон (От 1 до 500)", "Взять", "Отмена");
if(HouseInfo[i][Safe][3] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+6, DIALOG_STYLE_INPUT, "ShotGun", "У вас нет такого кол-ва патрон\n\nВведите кол-во патрон (От 1 до 500)", "Взять", "Отмена");
HouseInfo[i][Safe][3] -= strval(inputtext);
GiveWeapon(playerid, 25, strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы взяли {ffffff}%d {ffff00}патрон(ов)/(а) ShotGun из сейфа.", strval(inputtext));
return true;
}
case D_SAFE+7:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+7, DIALOG_STYLE_INPUT, "SMG", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+7, DIALOG_STYLE_INPUT, "SMG", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
if(HouseInfo[i][Safe][4] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+7, DIALOG_STYLE_INPUT, "SMG", "У вас нет такого кол-ва патрон\n\nВведите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
HouseInfo[i][Safe][4] -= strval(inputtext);
GiveWeapon(playerid, 29, strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы взяли {ffffff}%d {ffff00}патрон(ов)/(а) SMG из сейфа.", strval(inputtext));
return true;
}
case D_SAFE+8:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+8, DIALOG_STYLE_INPUT, "AK-47", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+8, DIALOG_STYLE_INPUT, "AK-47", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
if(HouseInfo[i][Safe][5] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+8, DIALOG_STYLE_INPUT, "AK-47", "У вас нет такого кол-ва патрон\n\nВведите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
HouseInfo[i][Safe][5] -= strval(inputtext);
GiveWeapon(playerid, 30, strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы взяли {ffffff}%d {ffff00}патрон(ов)/(а) AK-47 из сейфа.", strval(inputtext));
return true;
}
case D_SAFE+9:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+9, DIALOG_STYLE_INPUT, "M4", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+9, DIALOG_STYLE_INPUT, "M4", "Введите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
if(HouseInfo[i][Safe][6] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+9, DIALOG_STYLE_INPUT, "M4", "У вас нет такого кол-ва патрон\n\nВведите кол-во патрон (От 1 до 5000)", "Взять", "Отмена");
HouseInfo[i][Safe][6] -= strval(inputtext);
GiveWeapon(playerid, 31, strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы взяли {ffffff}%d {ffff00}патрон(ов)/(а) M4 из сейфа.", strval(inputtext));
return true;
}
case D_SAFE+10:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+10, DIALOG_STYLE_INPUT, "Rifle", "Введите кол-во патрон (От 1 до 200)", "Взять", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 200) return ShowPlayerDialog(playerid, D_SAFE+10, DIALOG_STYLE_INPUT, "Rifle", "Введите кол-во патрон (От 1 до 200)", "Взять", "Отмена");
if(HouseInfo[i][Safe][7] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+10, DIALOG_STYLE_INPUT, "Rifle", "У вас нет такого кол-ва патрон\n\nВведите кол-во патрон (От 1 до 200)", "Взять", "Отмена");
HouseInfo[i][Safe][7] -= strval(inputtext);
GiveWeapon(playerid, 33, strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы взяли {ffffff}%d {ffff00}патрон(ов)/(а) Rifle из сейфа.", strval(inputtext));
return true;
}
case D_SAFE+11:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+11, DIALOG_STYLE_INPUT, "Наркотики", "Введите кол-во наркотиков (От 1 до 2000)", "Положить", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 2000) return ShowPlayerDialog(playerid, D_SAFE+11, DIALOG_STYLE_INPUT, "Наркотики", "Введите кол-во наркотиков (От 1 до 2000)", "Положить", "Отмена");
if(HouseInfo[i][Safe][0]+strval(inputtext) > 2000) return ShowPlayerDialog(playerid, D_SAFE+11, DIALOG_STYLE_INPUT, "Наркотики", "Вы не можете положить так много в сейф\n\nВведите кол-во наркотиков (От 1 до 2000)", "Положить", "Отмена");
if(User[playerid][Drug][0] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+11, DIALOG_STYLE_INPUT, "Наркотики", "У вас нет столько наркотиков\n\nВведите кол-во наркотиков (От 1 до 2000)", "Положить", "Отмена");
HouseInfo[i][Safe][0] += strval(inputtext);
User[playerid][Drug][0] -= strval(inputtext);
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы положили {ffffff}%d {ffff00}наркотиков в сейф.", strval(inputtext));
return true;
}
case D_SAFE+12:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+12, DIALOG_STYLE_INPUT, "SDPistol", "Введите кол-во наркотиков (От 1 до 1000)", "Положить", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 1000) return ShowPlayerDialog(playerid, D_SAFE+12, DIALOG_STYLE_INPUT, "SDPistol", "Введите кол-во наркотиков (От 1 до 1000)", "Положить", "Отмена");
if(HouseInfo[i][Safe][1]+strval(inputtext) > 1000) return ShowPlayerDialog(playerid, D_SAFE+12, DIALOG_STYLE_INPUT, "SDPistol", "Вы не можете положить так много в сейф\n\nВведите кол-во наркотиков (От 1 до 1000)", "Положить", "Отмена");
if(Weapons[playerid][23] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+12, DIALOG_STYLE_INPUT, "SDPistol", "У вас нет столько патрон\n\nВведите кол-во наркотиков (От 1 до 1000)", "Положить", "Отмена");
HouseInfo[i][Safe][1] += strval(inputtext);
GiveWeapon(playerid, 23, -strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы положили {ffffff}%d {ffff00}патрон(ов)/(а) SDPistol в сейф.", strval(inputtext));
return true;
}
case D_SAFE+13:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+13, DIALOG_STYLE_INPUT, "Deagle", "Введите кол-во наркотиков (От 1 до 500)", "Положить", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 500) return ShowPlayerDialog(playerid, D_SAFE+13, DIALOG_STYLE_INPUT, "Deagle", "Введите кол-во наркотиков (От 1 до 500)", "Положить", "Отмена");
if(HouseInfo[i][Safe][2]+strval(inputtext) > 500) return ShowPlayerDialog(playerid, D_SAFE+13, DIALOG_STYLE_INPUT, "Deagle", "Вы не можете положить так много в сейф\n\nВведите кол-во наркотиков (От 1 до 500)", "Положить", "Отмена");
if(Weapons[playerid][24] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+13, DIALOG_STYLE_INPUT, "Deagle", "У вас нет столько патрон\n\nВведите кол-во наркотиков (От 1 до 500)", "Положить", "Отмена");
HouseInfo[i][Safe][2] += strval(inputtext);
GiveWeapon(playerid, 24, -strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы положили {ffffff}%d {ffff00}патрон(ов)/(а) Deagle в сейф.", strval(inputtext));
return true;
}
case D_SAFE+14:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+14, DIALOG_STYLE_INPUT, "ShotGun", "Введите кол-во наркотиков (От 1 до 500)", "Положить", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 500) return ShowPlayerDialog(playerid, D_SAFE+14, DIALOG_STYLE_INPUT, "ShotGun", "Введите кол-во наркотиков (От 1 до 500)", "Положить", "Отмена");
if(HouseInfo[i][Safe][3]+strval(inputtext) > 500) return ShowPlayerDialog(playerid, D_SAFE+14, DIALOG_STYLE_INPUT, "ShotGun", "Вы не можете положить так много в сейф\n\nВведите кол-во наркотиков (От 1 до 500)", "Положить", "Отмена");
if(Weapons[playerid][25] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+14, DIALOG_STYLE_INPUT, "ShotGun", "У вас нет столько патрон\n\nВведите кол-во наркотиков (От 1 до 500)", "Положить", "Отмена");
HouseInfo[i][Safe][3] += strval(inputtext);
GiveWeapon(playerid, 25, -strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы положили {ffffff}%d {ffff00}патрон(ов)/(а) ShotGun в сейф.", strval(inputtext));
return true;
}
case D_SAFE+15:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+15, DIALOG_STYLE_INPUT, "SMG", "Введите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+15, DIALOG_STYLE_INPUT, "SMG", "Введите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(HouseInfo[i][Safe][4]+strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+15, DIALOG_STYLE_INPUT, "SMG", "Вы не можете положить так много в сейф\n\nВведите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(Weapons[playerid][29] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+15, DIALOG_STYLE_INPUT, "SMG", "У вас нет столько патрон\n\nВведите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
HouseInfo[i][Safe][4] += strval(inputtext);
GiveWeapon(playerid, 29, -strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы положили {ffffff}%d {ffff00}патрон(ов)/(а) SMG в сейф.", strval(inputtext));
return true;
}
case D_SAFE+16:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+16, DIALOG_STYLE_INPUT, "AK-47", "Введите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+16, DIALOG_STYLE_INPUT, "AK-47", "Введите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(HouseInfo[i][Safe][5]+strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+16, DIALOG_STYLE_INPUT, "AK-47", "Вы не можете положить так много в сейф\n\nВведите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(Weapons[playerid][30] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+16, DIALOG_STYLE_INPUT, "AK-47", "У вас нет столько патрон\n\nВведите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
HouseInfo[i][Safe][5] += strval(inputtext);
GiveWeapon(playerid, 30, -strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы положили {ffffff}%d {ffff00}патрон(ов)/(а) AK-47 в сейф.", strval(inputtext));
return true;
}
case D_SAFE+17:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+17, DIALOG_STYLE_INPUT, "M4", "Введите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+17, DIALOG_STYLE_INPUT, "M4", "Введите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(HouseInfo[i][Safe][6]+strval(inputtext) > 5000) return ShowPlayerDialog(playerid, D_SAFE+17, DIALOG_STYLE_INPUT, "M4", "Вы не можете положить так много в сейф\n\nВведите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
if(Weapons[playerid][31] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+17, DIALOG_STYLE_INPUT, "M4", "У вас нет столько патрон\n\nВведите кол-во наркотиков (От 1 до 5000)", "Положить", "Отмена");
HouseInfo[i][Safe][6] += strval(inputtext);
GiveWeapon(playerid, 31, -strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы положили {ffffff}%d {ffff00}патрон(ов)/(а) M4 в сейф.", strval(inputtext));
return true;
}
case D_SAFE+18:
{
if(!response) return true;
new i = GetPVarInt(playerid, "PlayerHouse");
if(GetPlayerHouse(playerid) == 0) return SendMes(playerid, COLOR_GREY, "У вас нет дома");
if(!strlen(inputtext) || !IsNumeric(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+18, DIALOG_STYLE_INPUT, "Rifle", "Введите кол-во наркотиков (От 1 до 200)", "Положить", "Отмена");
if(strval(inputtext) < 1 || strval(inputtext) > 200) return ShowPlayerDialog(playerid, D_SAFE+18, DIALOG_STYLE_INPUT, "Rifle", "Введите кол-во наркотиков (От 1 до 200)", "Положить", "Отмена");
if(HouseInfo[i][Safe][7]+strval(inputtext) > 200) return ShowPlayerDialog(playerid, D_SAFE+18, DIALOG_STYLE_INPUT, "Rifle", "Вы не можете положить так много в сейф\n\nВведите кол-во наркотиков (От 1 до 200)", "Положить", "Отмена");
if(Weapons[playerid][33] < strval(inputtext)) return ShowPlayerDialog(playerid, D_SAFE+18, DIALOG_STYLE_INPUT, "Rifle", "У вас нет столько патрон\n\nВведите кол-во наркотиков (От 1 до 200)", "Положить", "Отмена");
HouseInfo[i][Safe][7] += strval(inputtext);
GiveWeapon(playerid, 33, -strval(inputtext));
SendMes(playerid, COLOR_YELLOW, "{ffff00}Вы положили {ffffff}%d {ffff00}патрон(ов)/(а) Rifle в сейф.", strval(inputtext));
return true;
}
