#include <a_samp>

//----------Tir defines----------
#define MAX_TIRS 		24
#define TARGET_MODEL 	1586
#define TIR_DIALOG  	238
#define COUNT_TARGETS   5
//------------------------------
#define CMD:%1(%2) COMMAND:%1(%2)
#define cmd:%1(%2) COMMAND:%1(%2)
#define command:%1(%2) COMMAND:%1(%2)

#define COMMAND:%1(%2)          \
			forward cmd_%1(%2); \
			public cmd_%1(%2)

#define ZAVOD_SKIN_1 259
#define ZAVOD_SKIN_2 260

#define PRESSED(%0) (((newkeys & (%0)) == (%0)) && ((oldkeys & (%0)) != (%0)))
#define RELEASED(%0) (((newkeys & (%0)) != (%0)) && ((oldkeys & (%0)) == (%0)))

#define MAX_KUBS 10

#define MAX_RINGS 2

#define MAX_STRIPS          50

#define UN_SPEED 	0.95
#define MAX_SPEED   0.50

#define COLOR_HPBAR 		0xB42225FF
#define COLOR_HPBAR_BG 		0x000000FF
#define COLOR_HPBAR_BG2 	0x551111FF

#define COLOR_SHBAR 		0x6053F3FF
#define COLOR_SHBAR_BG 		0x000000FF
#define COLOR_SHBAR_BG2 	0xB8CEF6FF

#define YES_LICENSE         (2)
#define NULLED_LIC         	(1)
#define NO_LICENSE         	(0)

#define COLOR_AMBAR 		0xFFFFFFFF
#define COLOR_AMBAR_BG 		0x000000FF
#define COLOR_AMBAR_BG2 	0xAFAFAFFF
#define COLOR_RED 			0xAA3333FF
#define COLOR_ISPOLZUY 		0x7FB151FF
#define COLOR_ORANGE 		0xFF9900FF
#define COLOR_BROWN 		0xA52A2AFF
#define COLOR_GREEN 		0x33AA33FF
#define COLOR_GOLD          0xFFD700FF
#define COLOR_LIGHTRED 		0xFF6347FF
#define COLOR_LIGHTBLUE 	0x33CCFFFF
#define COLOR_LIGHTGREEN 	0x9ACD32FF
#define COLOR_YELLOW 		0xFFFF00FF
#define COLOR_WHITE 		0xFFFFFFFF
#define COLOR_BLACK 		0x000000FF
#define COLOR_BLUENEW 		0xB8CEF6FF
#define COLOR_BLUE 			0x6053F3FF
#define COLOR_GRAD 			0xBFC0C2FF
#define COLOR_PURPLE 		0xC2A2DAFF
#define COLOR_LIME 			0x10F441FF
#define COLOR_TOMATO 		0xFF6347FF
#define COLOR_GREY 			0xAFAFAFFF
#define COLOR_INDIGO        0x400080FF
#define COLOR_CHAT		0xcececeFF

#define MINER_SLOT 			0
#define INC_SLOT_1  		1
#define INC_SLOT_2  		2
#define BUM_J_SLOT 			3
#define PHONE_SLOT  		4
#define INV_SLOT  			5
#define BAND_SLOT  			6
#define HAT_SLOT  			7
#define MASK_SLOT  			8
#define GLASS_SLOT  		9

#define MAX_AFK_RUN_TIME 20 * 60

#define MAX_MUSORS 136

#define HOTEL_SPAWN  2233.6999, -1114.5999, 1050.9000

#define ServerName "United RP"
#define ServerIP "46.174.50.42:7834"
#define SetPlayerTimer(%0,%1,%2,%3) SetTimerEx(%1, %2, %3, "i", %0)

#define RENAME_DIALOG 	(170)

#define VEHICLE_STATE_CAR   0
#define VEHICLE_STATE_BIKE  1
#define VEHICLE_STATE_VELIK 2
#define VEHICLE_STATE_PLANE 3
#define VEHICLE_STATE_BOAT  4
#define VEHICLE_STATE_MOPED 5

#define JOB_NONE        (0)
#define JOB_GUNDEALER 	(1)
#define JOB_DETECTIVE 	(2)
#define JOB_CARJACKER 	(3)
#define JOB_MECHANIC 	(4)
#define JOB_TAXI 		(5)
#define JOB_COACH 		(6)
#define JOB_MINER 		(7)
#define JOB_GUIDE 		(8)
#define JOB_COLLECTOR 	(9)
#define JOB_DRUGDEALER  (10)
#define JOB_TRUCKER  	(11)
#define JOB_THEIF  		(12)
#define JOB_SCRAPER  	(13)
#define JOB_MUSOR  		(14)

#define SPECIAL_ACTION_PISS (68)

#define INVALID_DIALOG_ID   (1234)

#define ADM_NONE 		(0)
#define ADM_MODER 		(1)
#define ADM_SUPER_MODER (2)
#define ADM_ADMIN       (3)
#define ADM_SUPER_ADMIN (4)
#define ADM_GRAND_ADMIN (5)

#define STATUS_NONE     (0)
#define STATUS_VIP      (1)
#define STATUS_GOLD     (2)

#define ICQ_UIN "62077434"
#define ICQ_PASS "39j7zzjl"

//#define GUN_POS 295.20001221, -39.29999924, 1001.59997559
#define GUN_POS GunPos[gunid][0], GunPos[gunid][1], GunPos[gunid][2]
#define GUN_ROT 90.0, 0.0, 90.0
#define FIRE_GUN_ROT 90.0, 0.0, 5.0

#define MAX_GPS 20

#define TEAM_FIRST_RANK (1)

#define PUT_STATE_MONEY (0)
#define PUT_STATE_DRUGS (1)
#define PUT_STATE_MATS 	(2)

#define PUT_STATE_CHEEPS (0)
#define PUT_STATE_SPRUNK (1)

#define SDPistolMats 	(2)
#define MP5Mats      	(2)
#define AK47Mats 	 	(3)
#define M4Mats 		 	(3)
#define EagleMats    	(4)
#define ShotGunMats  	(5)
#define RifleMats    	(6)
#define SniperMats   	(8)
#define MAX_ORGS 		(25)
#define GasMax 			(100)
#define COUNT_QUESTIONS (104)
#define MAX_OWNABLECARS (550)
#define MAX_PING        (500)
#define MAX_HOUSES 		(500)
#define MAX_BIZ         (50)
#define NO_DUTY_TEXT "Вы не на дежурстве. Используйте {33CCFF}/aduty"
//---------------------------------------
#undef MAX_PLAYERS
#define MAX_PLAYERS (120)
//---------------------------------------
#define INVALID_BIZ     (-1)

#define BIZ_GS_LS       (0)
#define BIZ_GS_SF       (1)
#define BIZ_GS_LV       (2)

#define BIZ_ELECTRO_LS 	(15)
#define BIZ_ELECTRO_SF 	(16)
#define BIZ_ELECTRO_LV 	(17)

#define BIZ_CU      	(18)

#define BIZ_GAS_LS_1 	(19)
#define BIZ_GAS_LS_2 	(20)

#define BIZ_GAS_SF_1 	(21)
#define BIZ_GAS_SF_2 	(22)
#define BIZ_GAS_SF_3 	(23)
#define BIZ_GAS_SF_4 	(24)
#define BIZ_GAS_SF_5 	(25)
#define BIZ_GAS_SF_6 	(26)

#define BIZ_GAS_LV_1 	(27)
#define BIZ_GAS_LV_2 	(28)
#define BIZ_GAS_LV_3 	(29)
#define BIZ_GAS_LV_4 	(30)
#define BIZ_GAS_LV_5 	(31)
#define BIZ_GAS_LV_6 	(32)

#define BIZ_RENT_LS     (39)
#define BIZ_RENT_SF     (40)
#define BIZ_RENT_LV     (41)
#define BIZ_AERO_LS     (42)
#define BIZ_AERO_SF     (43)
#define BIZ_AERO_LV     (44)

#define SPAWN_NONE  	(0)
#define SPAWN_HOTEL  	(1)
#define SPAWN_HOUSE 	(2)

#define MAX_EATCP 2

#define MAX_TELEPORTS   (84)

#define MAX_BANS        (50)

#define NONE_3D_TEXT (Text3D:-1)

#define D_BUY_VIP       (0)
#define D_BUY_GOLD 		(1)
#define D_BUY_MONEY 	(2)
#define D_BUY_PHONE 	(3)
#define D_BUY_WARN 		(4)
#define D_BUY_SKILL 	(5)
#define D_BUY_NAME 		(6)
#define D_BUY_EXP 		(7)
#define D_BUY_UNBL 		(8)
#define D_BUY_ZKP 		(9)

#define FIRST_MOBILE_ID (18865)
#define MOBILE_CORDS    0.0, 0.0, 0.0, 0.0, 0.0, 0.0

#define TEAM_NONE       (0)
#define TEAM_LSPD 		(1)
#define TEAM_LVPD 		(2)
#define TEAM_FBI 		(3)
#define TEAM_SWAT		(4)
#define TEAM_M4C 		(5)
#define TEAM_MERIALS 	(6)
#define TEAM_MERIASF 	(7)
#define TEAM_MERIALV 	(8)
#define TEAM_LICENSERS 	(9)
#define TEAM_RADIO 		(10)
#define TEAM_RACERS 	(11)
#define TEAM_GROOVE 	(12)
#define TEAM_VAGOS 		(13)
#define TEAM_BALLAS 	(14)
#define TEAM_CORONOS 	(15)
#define TEAM_RIFA 		(16)
#define TEAM_RM 		(17)
#define TEAM_YAKUZA 	(18)
#define TEAM_LCN 		(19)
#define TEAM_TRIADS 	(20)
#define TEAM_UM 		(21)
#define TEAM_BIKERS 	(22)
#define TEAM_CRIPS      (23)
#define TEAM_MS13		(24)

#define RES_CAR_TIME    (600)

#define BUY_MENU_PRODUCTS 	"Чипсы $2\nСпранк $1\nПиво $3"
#define BUY_MENU_CHANCERY 	"Телефонная книга $10\nПачка скрепок $5\nВеревка $3"
#define BUY_MENU_ACCSESSORY	"Набор масок $15\nНабор очков $25\nНабор бандан $20\nНабор шляп $20\nРюкзак $50"
#define BUY_MENU_TEXNIKA    "Мобильный телефон $50\nРадио $15\nМеталлоискатель $200\nФотоаппарат $100"
#define BUY_MENU_SMOKE      "Сигареты\nЗажигалки"
#define BUY_MENU_FISHED     "Удочка $15\nЧерви $2"
#define BUY_MENU_FUN        "Ролики $20\nФейерверк [1шт] $50"
#define BUY_MENU_MEHAN      "Гаечный ключ $5\nКанистра $10\nОтвертка $15\nЛопата $7\nНабор для починки $50"
#define BUY_MENU_OTHER      "Бронежилет $50\nЯД $50\nМотошлем $30\nШприц $1"

#define BUY_MENU_SMOKES2    "LM $1\nBOND $1\nРусский Стиль $1\nKent $1\nОптима $1\nChesterfield $2\nMarllboro $2\nParlament $2\nСигары $10\nПрима без фильтра $1\nБеломор канал $1"
#define BUY_MENU_LIGHTS2    "Автогеновая $2\nZippo $3\nCricket $1"

#define GRAND_247_MENU_TEXT "Купить\nПродать"
#define GRAND_BUY_MENU_TEXT "Продукты\nКанцелярия\nАксессуары\nТехника\nТабачные изделия\nРыбалка\nРазвлечения\nРазное"

//###############_KEYS_###################
#define KEY_HORN 				(2)
#define KEY_ACCELERATE 			(8)
#define KEY_ACTION_WALK 		(9)
#define KEY_FIRE_ACCELERATE 	(12)
#define KEY_EXIT_VEHICLE 		(16)
#define KEY_BRAKE 				(32)
#define KEY_FIRE_BRAKE 			(36)
#define KEY_SPRINT_JUMP 		(40)
#define KEY_AIM                 (128)
#define KEY_AIM_FIRE 			(132)
#define KEY_AIM_BRAKE 			(136)
#define KEY_LOOK_BEHIND_V 		(320)
#define KEY_LOOK_BEHIND_AIM 	(640)
#define KEY_WALK_AIM 			(1152)
#define KEY_FIRE_ANALOG_LEFT 	(8196)
#define KEY_AIM_ANALOG_LEFT 	(8320)
#define KEY_NUM4				(8192)
#define KEY_WALK_ANALOG_LEFT 	(9216)
#define KEY_NUM6 				(16384)
#define KEY_FIRE_ANALOG_RIGHT 	(16388)
#define KEY_AIM_ANALOG_RIGHT 	(16512)
#define KEY_WALK_ANALOG_RIGHT 	(17408)

#define CLICK_STATE_NONE 	 (-1)
#define CLICK_STATE_PAY      (0)
#define CLICK_STATE_MATS   	 (1)
#define CLICK_STATE_DRUGS  	 (2)
#define CLICK_STATE_SIGS  	 (3)
#define CLICK_STATE_CHEEPS 	 (4)
#define CLICK_STATE_SPRUNK 	 (5)
#define CLICK_STATE_BEER 	 (6)
#define CLICK_STATE_GOLD 	 (7)
#define CLICK_STATE_SYRINGE  (8)
#define CLICK_STATE_POISON 	 (9)
#define CLICK_STATE_CLIP     (10)
#define CLICK_STATE_WORMS    (11)
#define CLICK_STATE_WHISPER  (12)
#define CLICK_STATE_AUDIOMSG (13)

#define ArendCars 100//Макс. кол-во каров для аренды
#define AREND_DIALOG 230//Диалог аренды

#define B_GUNSHOP 	(0)
#define B_BAR 		(1)
#define B_BUY 		(2)
#define B_BINKO 	(3)
#define B_ELECTRO 	(4)
#define B_CARUPGR 	(5)
#define B_GAS 		(6)
#define B_CL_BELL 	(7)
#define B_RENTCAR 	(8)

#define SEK_MC 	1000
#define MIN_SEC 60

#define MAX_BARS 3

#define SCRAP_POS_X   	-1579.69995117
#define SCRAP_POS_Y   	123.30000305
#define SCRAP_POS_Z   	2.79999995

#define MAX_AFK_TIME 	(300)

#define MAX_BOMBS   	(100)

#define BARRIER_SPEED 	0.015

#define D_STATE_NORMAL  	(0)
#define D_STATE_CUFFED  	(1)
#define D_STATE_TEMPCUFF	(2)
#define D_STATE_KNOCKOUT    (3)
#define D_STATE_TIED        (4)

#define PHONE_STATE_NONE 			0
#define PHONE_STATE_ENTER_NUM   	1
#define PHONE_STATE_MENU_NUM    	2
#define PHONE_STATE_CALL        	3
#define PHONE_STATE_SEND_SMS    	4
#define PHONE_STATE_ADD        		5
#define PHONE_STATE_MENU        	6
#define PHONE_STATE_READ_ALL_SMS 	7
#define PHONE_STATE_READ_SMS   		8
#define PHONE_STATE_READ_CONTACTS   9
#define PHONE_STATE_READ_CONTACT   	10
#define PHONE_STATE_SMS_MENU        11
#define PHONE_STATE_CONTACT_MENU    12

#define OPERATOR_MTS    1
#define OPERATOR_MF     2
#define OPERATOR_BE     3

#define MAX_PHOTOS 6
#define MAX_CPS 21
#define MAX_RADIOS 50
#define INC_CPs 16
#define MAX_GUNS (sizeof(BuyGunInfo)-1)
