hlmod.hu

Magyar Half-Life Mód közösség!
Pontos idő: 2020.08.11. 09:12



Jelenlévő felhasználók

Jelenleg 34 felhasználó van jelen :: 0 regisztrált, 0 rejtett és 34 vendég

A legtöbb felhasználó (652 fő) 2015.05.25. 22:38-kor tartózkodott itt.

Regisztrált felhasználók: nincs regisztrált felhasználó az elmúlt 5 percben aktív felhasználók alapján

Utoljára aktív
Ahhoz hogy lásd ki volt utoljára aktív, be kell jelentkezned.



Az oldal teljeskörű
használatához regisztrálj.

Regisztráció

Kereső


Új téma nyitása  Hozzászólás a témához  [ 31 hozzászólás ]  Oldal 1 2 3 4 Következő
Szerző Üzenet
 Hozzászólás témája: rangrendszer + skinmenü összeírása
HozzászólásElküldve: 2020.02.08. 10:13 
Offline
Fanatikus

Csatlakozott: 2019.12.06. 20:00
Hozzászólások: 158
Megköszönt másnak: 13 alkalommal
Üdv,

valaki megtudná nekem oldani hogy a rangrendszer és SkinMenü egyben legyen, 1 mentéssel.

köszönöm előre is! :)


Csatolmányok:
darkdemonsmod2k19.sma [49.66 KiB]
Letöltve 46 alkalommal.
rangrnedszerjavitott.sma [10.39 KiB]
Letöltve 46 alkalommal.
Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.09. 11:57 
Offline
Fanatikus
Avatar

Csatlakozott: 2018.02.06. 14:07
Hozzászólások: 175
Megköszönt másnak: 19 alkalommal
Megköszönték neki: 12 alkalommal
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Header size: 1752 bytes
Code size: 56332 bytes
Data size: 227404 bytes
Stack/heap size: 16384 bytes; max. usage is unknown, due to recursion
Total requirements: 301872 bytes
Done.


Hali tesék teszteld! de nem olyan nehéz egybe írni 2 plugint! :)
De lasan 3 éve tag vagy nem hiszem hogy eze allat semmit nem tanúltál meg! ez nem ofolásnak szántam! :D


Csatolmányok:
darkdemonsmod2k19.sma [48.19 KiB]
Letöltve 31 alkalommal.

_________________
Kép

Ők köszönték meg ROL_MESTER nek ezt a hozzászólást: shoxe (2020.02.09. 14:19)
  Népszerűség: 2.27%
Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.10. 18:56 
Offline
Fanatikus

Csatlakozott: 2019.12.06. 20:00
Hozzászólások: 158
Megköszönt másnak: 13 alkalommal
ROL_MESTER írta:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Header size: 1752 bytes
Code size: 56332 bytes
Data size: 227404 bytes
Stack/heap size: 16384 bytes; max. usage is unknown, due to recursion
Total requirements: 301872 bytes
Done.


Hali tesék teszteld! de nem olyan nehéz egybe írni 2 plugint! :)
De lasan 3 éve tag vagy nem hiszem hogy eze allat semmit nem tanúltál meg! ez nem ofolásnak szántam! :D


Rangrendszer öléseket és a SkinMenü öléseket nem menti! :)


Csatolmányok:
darkdemonsmod2k19.sma [48.19 KiB]
Letöltve 27 alkalommal.
Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.10. 19:52 
Offline
Fanatikus
Avatar

Csatlakozott: 2018.02.06. 14:07
Hozzászólások: 175
Megköszönt másnak: 19 alkalommal
Megköszönték neki: 12 alkalommal
shoxe írta:
ROL_MESTER írta:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Header size: 1752 bytes
Code size: 56332 bytes
Data size: 227404 bytes
Stack/heap size: 16384 bytes; max. usage is unknown, due to recursion
Total requirements: 301872 bytes
Done.


Hali tesék teszteld! de nem olyan nehéz egybe írni 2 plugint! :)
De lasan 3 éve tag vagy nem hiszem hogy eze allat semmit nem tanúltál meg! ez nem ofolásnak szántam! :D


Rangrendszer öléseket és a SkinMenü öléseket nem menti! :)


Szia Log file ? csatlakozik egyáltalan az sql adatbázis hoz ?

_________________
Kép


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.11. 06:06 
Offline
Fanatikus

Csatlakozott: 2019.12.06. 20:00
Hozzászólások: 158
Megköszönt másnak: 13 alkalommal
ROL_MESTER írta:
shoxe írta:
ROL_MESTER írta:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Header size: 1752 bytes
Code size: 56332 bytes
Data size: 227404 bytes
Stack/heap size: 16384 bytes; max. usage is unknown, due to recursion
Total requirements: 301872 bytes
Done.


Hali tesék teszteld! de nem olyan nehéz egybe írni 2 plugint! :)
De lasan 3 éve tag vagy nem hiszem hogy eze allat semmit nem tanúltál meg! ez nem ofolásnak szántam! :D


Rangrendszer öléseket és a SkinMenü öléseket nem menti! :)


Szia Log file ? csatlakozik egyáltalan az sql adatbázis hoz ?



  1. L 02/09/2020 - 14:18:01: [MySQL] Invalid column: -1
  2. L 02/09/2020 - 14:18:01: [AMXX] Displaying debug trace (plugin "darkdemonsmod2020.amxx", version "1.0")
  3. L 02/09/2020 - 14:18:01: [AMXX] Run time error 10: native error (native "SQL_ReadResult")
  4. L 02/09/2020 - 14:18:01: [AMXX]    [0] 4eb1a43319f1f0e96f0a328d191fdffd.sma::QuerySelectData (line 822)


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.11. 12:04 
Offline
Fanatikus
Avatar

Csatlakozott: 2018.02.06. 14:07
Hozzászólások: 175
Megköszönt másnak: 19 alkalommal
Megköszönték neki: 12 alkalommal
Szia tesék teszteld ha megint hibát dobna kérlek csatolt a logot vagy az error-t! :D


Csatolmányok:
darkdemonsmod2k19.sma [48.12 KiB]
Letöltve 28 alkalommal.

_________________
Kép
Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.11. 17:59 
Offline
Fanatikus

Csatlakozott: 2019.12.06. 20:00
Hozzászólások: 158
Megköszönt másnak: 13 alkalommal
ROL_MESTER írta:
Szia tesék teszteld ha megint hibát dobna kérlek csatolt a logot vagy az error-t! :D


 ! Moderátori megjegyzés (Pika):
Ne szórakozz már, használd a szerkesztés gombot. Köszönöm. :)


Konzol ezt írja

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 'olesek = "0", szint = "0", UPDATE `SkinMenu` SET g_uPointsAWP = "0", g_uPointsM4' at line 1

Steamidre ment az kétszer hozza létre MySQL adatbázisban!

Konzol ezt írja

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 'olesek = "0", szint = "0", UPDATE `SkinMenu` SET g_uPointsAWP = "0", g_uPointsM4' at line 1

  1. #include <amxmodx>
  2. #include <engine>
  3. #include <fakemeta>
  4. #include <colorchat>
  5. #include <cstrike>
  6. #include <sqlx>
  7.  
  8. #pragma tabsize 0
  9.  
  10. #define PLUGIN "New Plug-In"
  11. #define VERSION "1.0"
  12. #define AUTHOR "author"
  13.  
  14. #define KILL_POINT 5
  15. #define HEADSHOT_POINT 10
  16.  
  17. #define TULAJ ADMIN_IMMUNITY
  18. #define ADMIN ADMIN_LEVEL_E
  19. #define FOADMIN ADMIN_LEVEL_B
  20. #define VIP ADMIN_BAN
  21. #define ASD 15
  22.  
  23.  
  24. enum _:GunDatas
  25. {
  26. M4A1,
  27. AK47,
  28. AWP,
  29. SCOUT,
  30. FAMAS,
  31. GALIL,
  32. AUG,
  33. M3,
  34. XM1014,
  35. KNIFE,
  36. DEAGLE,
  37. USP,
  38. GLOCK,
  39. }
  40. new g_SelectedGun[GunDatas][33];
  41. new g_uPoints[GunDatas][33];
  42. new g_Wpn[33];
  43. new Handle:g_SqlTuple;
  44. new hudkibe[33];
  45. new olesek[33];
  46. new szint[33];
  47. new Temp[192];
  48.  
  49.  
  50. new const PREFIX[] = "\w[\y.:DarK*_*DemonS:.\w]\y ~\w Fun Szerver ~By ChaoS*"
  51. new const C_Perfix[] = "[.:DarK*_*DemonS:.]"
  52.  
  53. enum _:DATA
  54. {
  55. GunName[64],
  56. ModelName[64],
  57. Points[8],
  58. AnimType[8]
  59. }
  60. new const szamok[ASD] =
  61. {
  62. 100,
  63. 300,
  64. 550,
  65. 1000,
  66. 2000,
  67. 4000,
  68. 5000,
  69. 6000,
  70. 7000,
  71. 8000,
  72. 10000,
  73. 12000,
  74. 15000,
  75. 18000,
  76. 22000  
  77. }
  78. new const rangok[ASD+1][] =
  79. {
  80. "Újonc",
  81. "Honvéd",
  82. "Őrvezető",
  83. "Tizedes",
  84. "Szakaszvezető",
  85. "Őrmester",
  86. "Hadnagy",
  87. "Főhadnagy",
  88. "Százados",   
  89. "Őrnagy",
  90. "Alezredes",
  91. "Ezredes",
  92. "Dandártábornok",
  93. "Vezéragy",
  94. "Altábornok",
  95. "Vezérezredes"
  96. }
  97. new const WeaponM4A1[][DATA] =
  98. {
  99. {"M4a1 | Default", "models/darkdemonsfun_mod/Default/v_m4a1.mdl", 0, -1},
  100. {"M4a1 | Neon Mist", "models/darkdemonsfun_mod/m4a1/v_m4a1_neon_mist.mdl", 300, -1},
  101. {"M4a1 | Cyrex Retextured", "models/darkdemonsfun_mod/m4a1/v_m4a1_cyrex_retextured.mdl", 600, -1},
  102. {"M4a1 | Stickers", "models/darkdemonsfun_mod/m4a1/v_m4a1_Stickers.mdl", 900, -1},
  103. {"M4a1 | Flashback", "models/darkdemonsfun_mod/m4a1/v_m4a1_flashback.mdl", 1200, -1},
  104. {"M4a1 | Golden Coil", "models/darkdemonsfun_mod/m4a1/v_m4a1_golden_coil.mdl", 1500, -1},
  105. {"M4a1 | Colored", "models/darkdemonsfun_mod/m4a1/v_m4a1_colored.mdl", 1800, -1},
  106. {"M4a1 | Fire", "models/darkdemonsfun_mod/m4a1/v_m4a1_fire.mdl", 2100, -1},
  107. {"M4a1 | Halloween", "models/darkdemonsfun_mod/m4a1/v_m4a1_halloween.mdl", 2300, -1},
  108. {"M4a1 | Condor", "models/darkdemonsfun_mod/m4a1/v_m4a1_Condor.mdl", 2600, -1},
  109. {"M4a1 | Stickers", "models/darkdemonsfun_mod/m4a1/v_m4a1_Stickers.mdl", 2900, -1},
  110. {"M4a1 | Frontside Misty", "models/darkdemonsfun_mod/m4a1/v_m4a1_frontside_misty.mdl", 3200, -1},
  111. {"M4a1 | Dragon Lore", "models/darkdemonsfun_mod/m4a1/v_m4a1_dragon_lore.mdl", 3500, -1},
  112. {"M4A1 | High Foltage God", "models/darkdemonsfun_mod/m4a1/v_m4a1_hight_foltage_god.mdl", 3800, -1}
  113. }
  114. new const WeaponAK47[][DATA] =
  115. {
  116. {"Ak47 | Default", "models/darkdemonsfun_mod/Default/v_ak47.mdl", 0, -1},
  117. {"Ak47 | Ufo", "models/darkdemonsfun_mod/ak47/v_ak47_ufo.mdl", 300, -1},
  118. {"Ak47 | Arktika Led Dlya", "models/darkdemonsfun_mod/ak47/v_ak47_arktikaleddlya.mdl", 600, -1},
  119. {"Ak47 | Case Hardened", "models/darkdemonsfun_mod/ak47/v_ak47_case_hardened.mdl", 900, -1},
  120. {"Ak47 | Hydroponic", "models/darkdemonsfun_mod/ak47/v_ak47_hydroponic.mdl", 1200, -1},
  121. {"Ak47 | Jet Set", "models/darkdemonsfun_mod/ak47/v_ak47_jetset.mdl", 1500, -1},
  122. {"Ak47 | Ono", "models/darkdemonsfun_mod/ak47/v_ak47_Ono.mdl", 1500, -1},
  123. {"Ak47 | Pinstripe", "models/darkdemonsfun_mod/ak47/v_ak47_pinstripe.mdl", 1800, -1},
  124. {"Ak47 | Point Dissary", "models/darkdemonsfun_mod/ak47/v_ak47_point_dissary.mdl", 2100, -1},
  125. {"Ak47 | Polar Bear", "models/darkdemonsfun_mod/ak47/v_ak47_polar_bear.mdl", 2400, -1},
  126. {"Ak47 | Red Force", "models/darkdemonsfun_mod/ak47/v_ak47_red_force.mdl", 2700, -1},
  127. {"Ak47 | Shark Attack", "models/darkdemonsfun_mod/ak47/v_ak47_shark_attack.mdl", 3000, -1},
  128. {"Ak47 | Anubis", "models/darkdemonsfun_mod/ak47/v_ak47_anubis.mdl", 3300, -1},
  129. {"Ak47 | Neon Revolution", "models/darkdemonsfun_mod/ak47/v_ak47_neon_revolution.mdl", 3600, -1},
  130. {"Ak47 | Purple 94", "models/darkdemonsfun_mod/ak47/v_ak47_purple_94.mdl", 3900, -1},
  131. {"Ak47 | Stainl HD", "models/darkdemonsfun_mod/ak47/v_ak47_stainl.mdl", 4200, -1},
  132. {"Ak47 | Shadow", "models/darkdemonsfun_mod/ak47/v_ak47_shadow.mdl", 4500, -1},
  133. {"Ak47 | Gold", "models/darkdemonsfun_mod/ak47/v_ak47_gold.mdl", 4800, -1}
  134. }
  135. new const WeaponAWP[][DATA] =
  136. {
  137. {"Awp | Default", "models/darkdemonsfun_mod/Default/v_awp.mdl", 0, -1},
  138. {"Awp | Leviathan Kiss", "models/darkdemonsfun_mod/awp/v_awp_leviathan_kiss.mdl", 300, -1},
  139. {"Awp | Graphite", "models/darkdemonsfun_mod/awp/v_awp_graphite.mdl", 600, -1},
  140. {"Awp | Meduza", "models/darkdemonsfun_mod/awp/v_awp_medusa.mdl", 900, -1},
  141. {"Awp | Banshee", "models/darkdemonsfun_mod/awp/v_awp_banshee.mdl", 1200, -1},
  142. {"Awp | Fire", "models/darkdemonsfun_mod/awp/v_awp_fire.mdl", 1500, -1},
  143. {"Awp | Azure Fantasy", "models/darkdemonsfun_mod/awp/v_awp_azure_fantasy.mdl", 1800, -1},
  144. {"Awp | Navi", "models/darkdemonsfun_mod/awp/v_awp_navi.mdl", 2100, -1},
  145. {"Awp | Elitebuild", "models/darkdemonsfun_mod/awp/v_awp_elitebuild.mdl", 2400, -1},
  146. {"Awp | Fever Dream", "models/darkdemonsfun_mod/awp/v_awp_fever_dream.mdl", 2700, -1}
  147. }
  148. new const WeaponSCOUT[][DATA] =
  149. {
  150. {"Scout | Default", "models/darkdemonsfun_mod/Default/v_scout.mdl", 0, -1},
  151. {"Scout | Dragonfire", "models/darkdemonsfun_mod/scout/v_scout_dragonfire.mdl", 300, -1},
  152. {"Scout | Blood Water", "models/darkdemonsfun_mod/scout/v_scout_blood_water.mdl", 600, -1},
  153. {"Scout | Shooting Dead", "models/darkdemonsfun_mod/scout/v_scout_shooting_dead.mdl", 900, -1},
  154. {"Scout | Bluediamond", "models/darkdemonsfun_mod/scout/v_scout_bluediamond.mdl", 1200, -1},
  155. {"Scout | Cityguardian", "models/darkdemonsfun_mod/scout/v_scout_cityguardian.mdl", 1500, -1}
  156. }
  157. new const WeaponFAMAS[][DATA] =
  158. {
  159. {"Famas | Default", "models/darkdemonsfun_mod/Default/v_famas.mdl", 0, -1},
  160. {"Famas | Neon Mist", "models/darkdemonsfun_mod/famas/v_famas_neon_mist.mdl", 300, -1},
  161. {"Famas | Psycho", "models/darkdemonsfun_mod/famas/v_famas_psycho.mdl", 600, -1},
  162. {"Famas | Skull", "models/darkdemonsfun_mod/famas/v_famas_skull.mdl", 900, -1},
  163. {"Famas | 4TH", "models/darkdemonsfun_mod/famas/v_famas_4th.mdl", 1200, -1},
  164. {"Famas | Asiimov", "models/darkdemonsfun_mod/famas/v_famas_asiimov.mdl", 1500, -1},
  165. {"Famas | Redline", "models/darkdemonsfun_mod/famas/v_famas_redline.mdl", 1800, -1},
  166. {"Famas | Pulze", "models/darkdemonsfun_mod/famas/v_famas_pulze.mdl", 2100, -1}
  167. }
  168. new const WeaponGALIL[][DATA] =
  169. {
  170. {"Galil | Default", "models/darkdemonsfun_mod/Default/v_galil.mdl", 0, -1},
  171. {"Galil | Coup", "models/darkdemonsfun_mod/galil/v_galil_Coup.mdl", 300, -1},
  172. {"Galil | Stone col", "models/darkdemonsfun_mod/galil/v_galil_stone_col.mdl", 600, -1},
  173. {"Galil | Orange", "models/darkdemonsfun_mod/galil/v_galil_orange.mdl", 900, -1}
  174. }
  175. new const WeaponAUG[][DATA] =
  176. {
  177. {"Aug | Default", "models/darkdemonsfun_mod/Default/v_aug.mdl", 0, -1},
  178. {"Aug | Azuro", "models/darkdemonsfun_mod/aug/v_aug_azuro.mdl", 300, -1},
  179. {"Aug | Next Tec", "models/darkdemonsfun_mod/aug/v_aug_Next_Tec.mdl",  600, -1},
  180. {"Aug | White Fa", "models/darkdemonsfun_mod/aug/v_aug_whitefa.mdl", 900, -1},
  181. {"Aug | Lavale", "models/darkdemonsfun_mod/aug/v_aug_Lavale.mdl", 1200, -1}
  182. }
  183. new const WeaponM3[][DATA] =
  184. {
  185. {"M3 | Default", "models/darkdemonsfun_mod/Default/v_m3.mdl", 0, -1},
  186. {"M3 | Nova Hyper Beast", "models/darkdemonsfun_mod/m3/v_m3_novahyperbeast.mdl", 300, -1},
  187. {"M3 | Sawed off Gray", "models/darkdemonsfun_mod/m3/v_m3_sawed-off-gray.mdl", 600, -1},
  188. {"M3 | Sawed off Limitel", "models/darkdemonsfun_mod/m3/v_m3_sawed-off-limel.mdl", 900, -1},
  189. {"M3 | Sawed off Seren", "models/darkdemonsfun_mod/m3/v_m3_sawed-off-seren.mdl", 1200, -1},
  190. {"M3 | Yellow Flowe", "models/darkdemonsfun_mod/m3/v_m3_yellow-flowe.mdl", 1500, -1}
  191. }
  192. new const WeaponXM1014[][DATA] =
  193. {
  194. {"XM1014 | Default", "models/darkdemonsfun_mod/Default/v_xm1014.mdl", 0, -1},
  195. {"XM1014 | Vandal", "models/darkdemonsfun_mod/xm1014/v_xm1014_vandal.mdl", 300, -1},
  196. {"XM1014 | Northern", "models/darkdemonsfun_mod/xm1014/v_xm1014_northern.mdl", 600, -1},
  197. {"XM1014 | Lego", "models/darkdemonsfun_mod/xm1014/v_xm1014_lego.mdl", 900, -1},
  198. {"XM1014 | Teclu Burner", "models/darkdemonsfun_mod/xm1014/v_xm1014_teclu_bu.mdl", 1200, -1},
  199. {"XM1014 | Heaven", "models/darkdemonsfun_mod/xm1014/v_xm1014_heaven.mdl", 1500, -1},
  200. {"XM1014 | Flame", "models/darkdemonsfun_mod/xm1014/v_xm1014_flame.mdl", 1800, -1},
  201. {"XM1014 | Asiimov", "models/darkdemonsfun_mod/xm1014/v_xm1014_asiimov.mdl", 2100, -1},
  202. {"XM1014 | Lego", "models/darkdemonsfun_mod/xm1014/v_xm1014_lego.mdl", 2400, -1},
  203. {"XM1014 | Tecu", "models/darkdemonsfun_mod/xm1014/v_xm1014_tecu.mdl", 2700, -1},
  204. {"XM1014 | Snow Cam", "models/darkdemonsfun_mod/xm1014/v_xm1014_Snow_cam.mdl", 3000, -1},
  205. {"XM1014 | Haven", "models/darkdemonsfun_mod/xm1014/v_xm1014_Haven.mdl", 3300, -1},
  206. {"XM1014 | Flame", "models/darkdemonsfun_mod/xm1014/v_xm1014_Flame.mdl", 3600, -1},
  207. {"XM1014 | Asiimow", "models/darkdemonsfun_mod/xm1014/v_xm1014_Asiimow.mdl", 3900, -1},
  208. {"XM1014 | Teclu Burner", "models/darkdemonsfun_mod/xm1014/v_xm1014_teclu_burner.mdl", 4200, -1},
  209. {"XM1014 | Heaven Guard", "models/darkdemonsfun_mod/xm1014/v_xm1014_heaven_guard.mdl", 4500, -1}   
  210. }
  211. new const WeaponKNIFE[][DATA] =
  212. {
  213. {"Knife | Default", "models/darkdemonsfun_mod/Default/v_knife.mdl", 0, -1},
  214. {"Knife | Navi", "models/darkdemonsfun_mod/knife/v_knife_navi.mdl", 300, -1},
  215. {"Knife | Green", "models/darkdemonsfun_mod/knife/v_knife_green.mdl", 600, -1},
  216. {"Knife | Abys", "models/darkdemonsfun_mod/knife/v_knife_abys.mdl", 900, -1},
  217. {"Knife | Armage", "models/darkdemonsfun_mod/knife/v_knife_armage.mdl", 1200, -1},
  218. {"Knife | Neon Rider", "models/darkdemonsfun_mod/knife/v_knife_neon_rider.mdl", 1500, -1},
  219. {"Knife | Slaught", "models/darkdemonsfun_mod/knife/v_knife_slaught.mdl", 1800,-1},
  220. {"Knife | Tiger", "models/darkdemonsfun_mod/knife/v_knife_tiger.mdl", 2100, -1}
  221. }
  222. new const WeaponDEAGLE[][DATA] =
  223. {
  224. {"Deagle | Default", "models/darkdemonsfun_mod/Default/v_deagle.mdl", 0, -1},
  225. {"Deagle | Glory", "models/darkdemonsfun_mod/deagle/v_deagle_glory.mdl", 300, -1},
  226. {"Deagle | Obstacle", "models/darkdemonsfun_mod/deagle/v_deagle_obstacle.mdl", 600, -1},
  227. {"Deagle | Kumicho Dragon", "models/darkdemonsfun_mod/deagle/v_deagle_kumicho-dragon.mdl", 900, -1},
  228. {"Deagle | Salient v2", "models/darkdemonsfun_mod/deagle/v_deagle_salientv2.mdl", 1200, -1},
  229. {"Deagle | Bloodsport", "models/darkdemonsfun_mod/deagle/v_deagle_bloodsport.mdl", 1500, -1},
  230. {"Deagle | Pilot", "models/darkdemonsfun_mod/deagle/v_deagle_point_pilot.mdl", 1800, -1},
  231. {"Deagle | Doomsday", "models/darkdemonsfun_mod/deagle/v_deagle_doomsday.mdl", 2100, -1},
  232. {"Deagle | Machine", "models/darkdemonsfun_mod/deagle/v_deagle_machine.mdl", 2400, -1},
  233. {"Deagle | Blaze", "models/darkdemonsfun_mod/deagle/v_deagle_blaze.mdl", 2700, -1},
  234. {"Deagle | Alexandr", "models/darkdemonsfun_mod/deagle/v_deagle_Alexandr.mdl", 3000, -1},
  235. {"Deagle | Stick", "models/darkdemonsfun_mod/deagle/v_deagle_Stick.mdl", 3300, -1},
  236. {"Deagle | Bloodspo", "models/darkdemonsfun_mod/deagle/v_deagle_Bloodspo.mdl", 3600, -1},
  237. {"Deagle | Sunset", "models/darkdemonsfun_mod/deagle/v_deagle_sunset.mdl", 3900, -1},
  238. {"Deagle | Cobalt", "models/darkdemonsfun_mod/deagle/v_deagle_cobalt.mdl", 4200, -1},
  239. {"Deagle | Toxic", "models/darkdemonsfun_mod/deagle/v_deagle_toxic.mdl", 4500, -1},
  240. {"Deagle | Dooms", "models/darkdemonsfun_mod/deagle/v_deagle_dooms.mdl", 4800, -1},
  241. {"Deagle | Eag", "models/darkdemonsfun_mod/deagle/v_deagle_Eag.mdl", 5100, -1},
  242. {"Deagle | Crims", "models/darkdemonsfun_mod/deagle/v_deagle_crims.mdl", 5400, -1}
  243. }
  244. new const WeaponUSP[][DATA] =
  245. {
  246. {"Usp | Default", "models/darkdemonsfun_mod/Default/v_usp.mdl", 0, -1},
  247. {"Usp | Green Drako", "models/darkdemonsfun_mod/usp/v_usp_green_drako.mdl", 300, -1},
  248. {"Usp | Stealth Hunter", "models/darkdemonsfun_mod/usp/v_usp_stealth_hunter.mdl", 600, -1},
  249. {"Usp | Oil Filter", "models/darkdemonsfun_mod/usp/v_usp_oil-filter.mdl", 900, -1},
  250. {"Usp | Royal Blue Stickers", "models/darkdemonsfun_mod/usp/v_usp_royal_blue_stickers.mdl", 1200, -1},
  251. {"Usp | Pink", "models/darkdemonsfun_mod/usp/v_usp_Pink.mdl", 1500, -1},
  252. {"Usp | Next Tec", "models/darkdemonsfun_mod/usp/v_usp_next_tec.mdl", 1800, -1},
  253. {"Usp | Fat Cap", "models/darkdemonsfun_mod/usp/v_usp_fat_cap.mdl", 2100, -1},
  254. {"Usp | Revena", "models/darkdemonsfun_mod/usp/v_usp_revena.mdl", 2400, -1},
  255. {"Usp | Cutv2", "models/darkdemonsfun_mod/usp/v_usp_cutv2.mdl", 2700, -1}
  256. }
  257. new const WeaponGLOCK[][DATA] =
  258. {
  259. {"Glock18 | Default",  "models/darkdemonsfun_mod/Default/v_glock18.mdl", 0, -1},
  260. {"Glock18 | Water Ele", "models/darkdemonsfun_mod/glock/v_glock18_water_ele.mdl", 300, -1},
  261. {"Glock18 | Wasteland", "models/darkdemonsfun_mod/glock/v_glock18_wasteland.mdl", 600, -1},
  262. {"Glock18 | Cubes Wor", "models/darkdemonsfun_mod/glock/v_glock18_cubes_wor.mdl", 900, -1},
  263. {"Glock18 | Fire", "models/darkdemonsfun_mod/glock/v_glock18_fire.mdl", 1200, -1},
  264. {"Glock18 | Oxid Blaze", "models/darkdemonsfun_mod/glock/v_glock18_oxid_blaze.mdl", 1500, -1},
  265. {"Glock18 | Web Green", "models/darkdemonsfun_mod/glock/v_glock18_webgreen.mdl", 1800, -1}
  266. }
  267. new const MainStrings[][] =
  268. {
  269. "«M4a1 Skinek»",
  270. "«Ak47 Skinek»",
  271. "«Awp Skinek»",
  272. "«Scout Skinek»",
  273. "«Famas Skinek»",
  274. "«Galil Skinek»",
  275. "«Aug Skinek»",
  276. "«M3 Skinek»",
  277. "«Xm1014 Skinek»",
  278. "«Kés Skinek»",
  279. "«Deagle Skinek»",
  280. "«Usp Skinek»",
  281. "«Glock18 Skinek»"
  282. }
  283. public plugin_init() {
  284. register_plugin(PLUGIN, VERSION, AUTHOR)
  285. register_clcmd("say /menu", "openMainMenu")
  286. register_clcmd("say /add", "Addolas")
  287. register_clcmd("say /rang", "showrang");
  288. register_clcmd("say /hud", "hudkibekapcs");
  289. register_impulse(201, "openMainMenu");
  290. register_event("DeathMsg","Halal","a")
  291. register_event("CurWeapon", "evChangeWeapon", "be", "1=1")
  292. register_impulse(100, "cmdInspectWeap");
  293. register_clcmd("say", "sayhook");
  294. }
  295. public Addolas(id)
  296. {
  297. g_uPoints[M4A1][id] += 300
  298. g_uPoints[AK47][id] += 300
  299. g_uPoints[AWP][id] += 300
  300. g_uPoints[SCOUT][id] += 300
  301. g_uPoints[FAMAS][id] += 300
  302. g_uPoints[GALIL][id] += 300
  303. g_uPoints[AUG][id] += 300
  304. g_uPoints[M3][id] += 300
  305. g_uPoints[XM1014][id] += 300
  306. g_uPoints[KNIFE][id] += 300
  307. g_uPoints[DEAGLE][id] += 300
  308. g_uPoints[USP][id] += 300
  309. g_uPoints[GLOCK][id] += 300;
  310. }
  311. public plugin_precache() {
  312. for(new i;i < sizeof(WeaponM4A1); i++) precache_model(WeaponM4A1[i][ModelName])
  313. for(new i;i < sizeof(WeaponAK47); i++) precache_model(WeaponAK47[i][ModelName])
  314. for(new i;i < sizeof(WeaponAWP); i++) precache_model(WeaponAWP[i][ModelName])
  315. for(new i;i < sizeof(WeaponSCOUT); i++) precache_model(WeaponSCOUT[i][ModelName])
  316. for(new i;i < sizeof(WeaponFAMAS); i++) precache_model(WeaponFAMAS[i][ModelName])
  317. for(new i;i < sizeof(WeaponGALIL); i++) precache_model(WeaponGALIL[i][ModelName])
  318. for(new i;i < sizeof(WeaponAUG); i++) precache_model(WeaponAUG[i][ModelName])
  319. for(new i;i < sizeof(WeaponM3); i++) precache_model(WeaponM3[i][ModelName])
  320. for(new i;i < sizeof(WeaponXM1014); i++) precache_model(WeaponXM1014[i][ModelName])
  321. for(new i;i < sizeof(WeaponKNIFE); i++) precache_model(WeaponKNIFE[i][ModelName])
  322. for(new i;i < sizeof(WeaponDEAGLE); i++) precache_model(WeaponDEAGLE[i][ModelName])
  323. for(new i;i < sizeof(WeaponUSP); i++) precache_model(WeaponUSP[i][ModelName])
  324. for(new i;i < sizeof(WeaponGLOCK); i++) precache_model(WeaponGLOCK[i][ModelName])
  325. }
  326. public cmdInspectWeap(id) {
  327. if(!is_user_alive(id)) return PLUGIN_HANDLED;
  328. new Wpns = get_user_weapon(id)
  329.  
  330. switch(Wpns) {
  331. case CSW_M4A1: {
  332. if(WeaponM4A1[g_SelectedGun[M4A1][id]][AnimType] == -1) return PLUGIN_HANDLED;
  333. UTIL_PlayWeaponAnimation(id, WeaponM4A1[g_SelectedGun[M4A1][id]][AnimType]);
  334. }
  335. case CSW_AK47: {
  336. if(WeaponAK47[g_SelectedGun[AK47][id]][AnimType] == -1) return PLUGIN_HANDLED;
  337. UTIL_PlayWeaponAnimation(id, WeaponAK47[g_SelectedGun[AK47][id]][AnimType]);
  338. }
  339. case CSW_AWP: {
  340. if(WeaponAWP[g_SelectedGun[AWP][id]][AnimType] == -1) return PLUGIN_HANDLED;
  341. UTIL_PlayWeaponAnimation(id, WeaponAWP[g_SelectedGun[AWP][id]][AnimType]);
  342. }
  343. case CSW_SCOUT: {
  344. if(WeaponSCOUT[g_SelectedGun[SCOUT][id]][AnimType] == -1) return PLUGIN_HANDLED;
  345. UTIL_PlayWeaponAnimation(id, WeaponSCOUT[g_SelectedGun[SCOUT][id]][AnimType]);
  346. }
  347. case CSW_FAMAS: {
  348. if(WeaponFAMAS[g_SelectedGun[FAMAS][id]][AnimType] == -1) return PLUGIN_HANDLED;
  349. UTIL_PlayWeaponAnimation(id, WeaponFAMAS[g_SelectedGun[FAMAS][id]][AnimType]);
  350. }
  351. case CSW_GALIL: {
  352. if(WeaponGALIL[g_SelectedGun[GALIL][id]][AnimType] == -1) return PLUGIN_HANDLED;
  353. UTIL_PlayWeaponAnimation(id, WeaponGALIL[g_SelectedGun[GALIL][id]][AnimType]);
  354. }
  355. case CSW_AUG: {
  356. if(WeaponAUG[g_SelectedGun[AUG][id]][AnimType] == -1) return PLUGIN_HANDLED;
  357. UTIL_PlayWeaponAnimation(id, WeaponAUG[g_SelectedGun[AUG][id]][AnimType]);
  358. }
  359. case CSW_M3: {
  360. if(WeaponM3[g_SelectedGun[M3][id]][AnimType] == -1) return PLUGIN_HANDLED;
  361. UTIL_PlayWeaponAnimation(id, WeaponM3[g_SelectedGun[M3][id]][AnimType]);
  362. }
  363. case CSW_XM1014: {    
  364. if(WeaponXM1014[g_SelectedGun[XM1014][id]][AnimType] == -1) return PLUGIN_HANDLED;
  365. UTIL_PlayWeaponAnimation(id, WeaponXM1014[g_SelectedGun[XM1014][id]][AnimType]);
  366. }
  367. case CSW_KNIFE: {
  368. if(WeaponKNIFE[g_SelectedGun[KNIFE][id]][AnimType] == -1) return PLUGIN_HANDLED;
  369. UTIL_PlayWeaponAnimation(id, WeaponKNIFE[g_SelectedGun[KNIFE][id]][AnimType]);
  370. }
  371. case CSW_DEAGLE: {
  372. if(WeaponDEAGLE[g_SelectedGun[DEAGLE][id]][AnimType] == -1) return PLUGIN_HANDLED;
  373. UTIL_PlayWeaponAnimation(id, WeaponDEAGLE[g_SelectedGun[DEAGLE][id]][AnimType]);
  374. }
  375. case CSW_USP: {
  376. if(WeaponUSP[g_SelectedGun[USP][id]][AnimType] == -1) return PLUGIN_HANDLED;
  377. UTIL_PlayWeaponAnimation(id, WeaponUSP[g_SelectedGun[USP][id]][AnimType]);
  378. }
  379. case CSW_GLOCK18: {
  380. if(WeaponGLOCK[g_SelectedGun[GLOCK][id]][AnimType] == -1) return PLUGIN_HANDLED;
  381. UTIL_PlayWeaponAnimation(id, WeaponGLOCK[g_SelectedGun[GLOCK][id]][AnimType]);
  382. }  
  383. }  
  384. return PLUGIN_HANDLED
  385. }
  386. public evChangeWeapon(id) {
  387. switch(get_user_weapon(id)) {
  388. case CSW_M4A1: entity_set_string(id, EV_SZ_viewmodel, WeaponM4A1[g_SelectedGun[M4A1][id]][ModelName]);
  389. case CSW_AK47: entity_set_string(id, EV_SZ_viewmodel, WeaponAK47[g_SelectedGun[AK47][id]][ModelName]);
  390. case CSW_AWP: entity_set_string(id, EV_SZ_viewmodel, WeaponAWP[g_SelectedGun[AWP][id]][ModelName]);
  391. case CSW_SCOUT: entity_set_string(id, EV_SZ_viewmodel, WeaponSCOUT[g_SelectedGun[SCOUT][id]][ModelName]);
  392. case CSW_FAMAS: entity_set_string(id, EV_SZ_viewmodel, WeaponFAMAS[g_SelectedGun[FAMAS][id]][ModelName]);
  393. case CSW_GALIL: entity_set_string(id, EV_SZ_viewmodel, WeaponGALIL[g_SelectedGun[GALIL][id]][ModelName]);
  394. case CSW_AUG: entity_set_string(id, EV_SZ_viewmodel, WeaponAUG[g_SelectedGun[AUG][id]][ModelName]);
  395. case CSW_M3: entity_set_string(id, EV_SZ_viewmodel, WeaponM3[g_SelectedGun[M3][id]][ModelName]);
  396. case CSW_XM1014: entity_set_string(id, EV_SZ_viewmodel, WeaponXM1014[g_SelectedGun[XM1014][id]][ModelName]);
  397. case CSW_KNIFE: entity_set_string(id, EV_SZ_viewmodel, WeaponKNIFE[g_SelectedGun[KNIFE][id]][ModelName]);
  398. case CSW_DEAGLE: entity_set_string(id, EV_SZ_viewmodel, WeaponDEAGLE[g_SelectedGun[DEAGLE][id]][ModelName]);
  399. case CSW_USP: entity_set_string(id, EV_SZ_viewmodel, WeaponUSP[g_SelectedGun[USP][id]][ModelName])
  400. case CSW_GLOCK18: entity_set_string(id, EV_SZ_viewmodel, WeaponGLOCK[g_SelectedGun[GLOCK][id]][ModelName]);
  401. }
  402. return PLUGIN_CONTINUE
  403. }
  404. public Halal() {
  405.  
  406. new iAttacker = read_data(1)
  407. new iVictim = read_data(2)
  408. new iHs = read_data(3)
  409. new killer = read_data(4);
  410. new victim = read_data(5);
  411.  
  412. if(iAttacker == iVictim || iAttacker == 0) return PLUGIN_HANDLED
  413. if(killer != victim)
  414. olesek[killer]++
  415.  
  416. while(olesek[killer] >= szamok[szint[killer]])  
  417. szint[killer]++
  418.  
  419. new iPoints = iHs ? HEADSHOT_POINT : KILL_POINT
  420. switch(get_user_weapon(iAttacker))
  421. {
  422. case CSW_AK47: g_uPoints[AK47][iAttacker] += iPoints
  423. case CSW_M4A1: g_uPoints[M4A1][iAttacker] += iPoints
  424. case CSW_AWP: g_uPoints[AWP][iAttacker] += iPoints
  425. case CSW_SCOUT: g_uPoints[SCOUT][iAttacker] += iPoints
  426. case CSW_FAMAS: g_uPoints[FAMAS][iAttacker] += iPoints
  427. case CSW_GALIL: g_uPoints[GALIL][iAttacker] += iPoints
  428. case CSW_AUG: g_uPoints[AUG][iAttacker] += iPoints
  429. case CSW_M3: g_uPoints[M3][iAttacker] += iPoints
  430. case CSW_XM1014: g_uPoints[XM1014][iAttacker] += iPoints
  431. case CSW_KNIFE: g_uPoints[KNIFE][iAttacker] += iPoints
  432. case CSW_DEAGLE: g_uPoints[DEAGLE][iAttacker] += iPoints
  433. case CSW_USP: g_uPoints[USP][iAttacker] += iPoints
  434. case CSW_GLOCK18: g_uPoints[GLOCK][iAttacker] += iPoints
  435. }
  436. set_hudmessage(random(256), random(256), random(256), -1.0, 0.85, 0, 6.0, 3.0);
  437. show_hudmessage(iAttacker, "+%i Pont", iPoints);
  438. return PLUGIN_CONTINUE;
  439. }
  440. public openMainMenu(id)
  441. {
  442.     new szMenu[121], String[6]
  443.     formatex(szMenu, charsmax(szMenu), "%s \wFőmenü", PREFIX)
  444.     new menu = menu_create(szMenu, "hMainMenu");
  445.    
  446.     for(new i ;i < sizeof(MainStrings); i++)
  447.     {
  448.     num_to_str(i, String, 5)
  449.     formatex(szMenu, charsmax(szMenu), MainStrings[i]);
  450.     menu_additem(menu, szMenu, String);
  451.     }
  452.     menu_display(id, menu, 0);
  453.     return PLUGIN_HANDLED;
  454. }
  455. public hMainMenu(id, menu, item)
  456. {
  457.     if(item == MENU_EXIT)
  458.     {
  459.         menu_destroy(menu);
  460.         return PLUGIN_HANDLED;
  461.     }
  462.     g_Wpn[id] = item+1
  463.     openSkinMenu(id)
  464.     menu_destroy(menu);
  465.     return PLUGIN_HANDLED;
  466. }
  467. public openSkinMenu(id)
  468. {
  469.     new szMenu[121], szMenu2[64], String[15]
  470.     if(g_Wpn[id] == 1) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  471.     g_uPoints[M4A1][id])
  472.     else if(g_Wpn[id] == 2) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1], g_uPoints[AK47][id])
  473.     else if(g_Wpn[id] == 3) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1], g_uPoints[AWP][id])
  474.     else if(g_Wpn[id] == 4) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1], g_uPoints[SCOUT][id])
  475.     else if(g_Wpn[id] == 5) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1], g_uPoints[FAMAS][id])
  476.     if(g_Wpn[id] == 6) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  477.     g_uPoints[GALIL][id])
  478.     if(g_Wpn[id] == 7) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  479.     g_uPoints[AUG][id])
  480.     if(g_Wpn[id] == 8) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  481.     g_uPoints[M3][id])
  482.     if(g_Wpn[id] == 9) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  483.     g_uPoints[XM1014][id])
  484.     if(g_Wpn[id] == 10) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  485.     g_uPoints[KNIFE][id])
  486.     if(g_Wpn[id] == 11) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  487.     g_uPoints[DEAGLE][id])
  488.     if(g_Wpn[id] == 12) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  489.     g_uPoints[USP][id])
  490.     if(g_Wpn[id] == 13) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  491.     g_uPoints[GLOCK][id])
  492.     new menu = menu_create(szMenu, "hSkinChooser");
  493.     if(g_Wpn[id] == 1) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  494.     MainStrings[g_Wpn[id]-1], g_uPoints[M4A1][id])
  495.     if(g_Wpn[id] == 2) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  496.     MainStrings[g_Wpn[id]-1], g_uPoints[AK47][id])
  497.     if(g_Wpn[id] == 3) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  498.     MainStrings[g_Wpn[id]-1], g_uPoints[AWP][id])
  499.     if(g_Wpn[id] == 4) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  500.     MainStrings[g_Wpn[id]-1], g_uPoints[SCOUT][id])
  501.     if(g_Wpn[id] == 5) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  502.     MainStrings[g_Wpn[id]-1], g_uPoints[FAMAS][id])
  503.     if(g_Wpn[id] == 6) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  504.     MainStrings[g_Wpn[id]-1], g_uPoints[GALIL][id])
  505.     if(g_Wpn[id] == 7) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  506.     MainStrings[g_Wpn[id]-1], g_uPoints[AUG][id])
  507.     if(g_Wpn[id] == 8) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  508.     MainStrings[g_Wpn[id]-1], g_uPoints[M3][id])
  509.     if(g_Wpn[id] == 10) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  510.     MainStrings[g_Wpn[id]-1], g_uPoints[XM1014][id])
  511.     if(g_Wpn[id] == 11) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  512.     MainStrings[g_Wpn[id]-1], g_uPoints[KNIFE][id])
  513.     if(g_Wpn[id] == 12) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  514.     MainStrings[g_Wpn[id]-1], g_uPoints[DEAGLE][id])
  515.     if(g_Wpn[id] == 13) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  516.     MainStrings[g_Wpn[id]-1], g_uPoints[USP][id])
  517.     if(g_Wpn[id] == 14) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  518.     MainStrings[g_Wpn[id]-1], g_uPoints[GLOCK][id])
  519.    
  520.    
  521.    
  522.    
  523.     if(g_Wpn[id] == 1) {
  524.         for(new i; i < sizeof(WeaponM4A1); i++) {
  525.             num_to_str(i, String, 5)
  526.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponM4A1[i][Points]);
  527.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponM4A1[i][GunName], g_SelectedGun[M4A1][id] == i ? "\y|Aktív|": szMenu2);
  528.             menu_additem(menu, szMenu, String);
  529.         }
  530.     }
  531.     else if(g_Wpn[id] == 2) {
  532.         for(new i; i < sizeof(WeaponAK47); i++) {
  533.             num_to_str(i, String, 5)
  534.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponAK47[i][Points]);
  535.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponAK47[i][GunName], g_SelectedGun[AK47][id] == i ? "\y|Aktív|": szMenu2);
  536.             menu_additem(menu, szMenu, String);
  537.         }
  538.     }
  539.     else if(g_Wpn[id] == 3) {
  540.         for(new i; i < sizeof(WeaponAWP); i++) {
  541.             num_to_str(i, String, 5)
  542.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponAWP[i][Points]);
  543.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponAWP[i][GunName], g_SelectedGun[AWP][id] == i ? "\y|Aktív|": szMenu2);
  544.             menu_additem(menu, szMenu, String);
  545.         }
  546.     }
  547.     else if(g_Wpn[id] == 4) {
  548.         for(new i; i < sizeof(WeaponSCOUT); i++) {
  549.             num_to_str(i, String, 5)
  550.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponSCOUT[i][Points]);
  551.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponSCOUT[i][GunName], g_SelectedGun[SCOUT][id] == i ? "\y|Aktív|": szMenu2);
  552.             menu_additem(menu, szMenu, String);
  553.         }
  554.     }
  555.     else if(g_Wpn[id] == 5) {
  556.         for(new i; i < sizeof(WeaponFAMAS); i++) {
  557.             num_to_str(i, String, 5)
  558.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponFAMAS[i][Points]);
  559.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponFAMAS[i][GunName], g_SelectedGun[FAMAS][id] == i ? "\y|Aktív|": szMenu2);
  560.             menu_additem(menu, szMenu, String);
  561.         }
  562.     }
  563.     else if(g_Wpn[id] == 6) {
  564.         for(new i; i < sizeof(WeaponGALIL); i++) {
  565.             num_to_str(i, String, 5)
  566.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponGALIL[i][Points]);
  567.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponGALIL[i][GunName], g_SelectedGun[GALIL][id] == i ? "\y|Aktív|": szMenu2);
  568.             menu_additem(menu, szMenu, String);
  569.         }
  570.     }
  571.     else if(g_Wpn[id] == 7) {
  572.         for(new i; i < sizeof(WeaponAUG); i++) {
  573.             num_to_str(i, String, 5)
  574.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponAUG[i][Points]);
  575.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponAUG[i][GunName], g_SelectedGun[AUG][id] == i ? "\y|Aktív|": szMenu2);
  576.             menu_additem(menu, szMenu, String);
  577.            
  578.         }  
  579.     }
  580.     else if(g_Wpn[id] == 8) {
  581.         for(new i; i < sizeof(WeaponM3); i++) {
  582.             num_to_str(i, String, 5)
  583.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponM3[i][Points]);
  584.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponM3[i][GunName], g_SelectedGun[M3][id] == i ? "\y|Aktív|": szMenu2);
  585.             menu_additem(menu, szMenu, String);
  586.            
  587.         }  
  588.     }
  589.     else if(g_Wpn[id] == 9) {
  590.         for(new i; i < sizeof(WeaponXM1014); i++) {
  591.             num_to_str(i, String, 5)
  592.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponXM1014[i][Points]);
  593.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponXM1014[i][GunName], g_SelectedGun[XM1014][id] == i ? "\y|Aktív|": szMenu2);
  594.             menu_additem(menu, szMenu, String);
  595.            
  596.         }  
  597.     }
  598.     else if(g_Wpn[id] == 10) {
  599.         for(new i; i < sizeof(WeaponKNIFE); i++) {
  600.             num_to_str(i, String, 5)
  601.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponKNIFE[i][Points]);
  602.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponKNIFE[i][GunName], g_SelectedGun[KNIFE][id] == i ? "\y|Aktív|": szMenu2);
  603.             menu_additem(menu, szMenu, String);
  604.            
  605.         }  
  606.     }
  607.     else if(g_Wpn[id] == 11) {
  608.         for(new i; i < sizeof(WeaponDEAGLE); i++) {
  609.             num_to_str(i, String, 5)
  610.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponDEAGLE[i][Points]);
  611.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponDEAGLE[i][GunName], g_SelectedGun[DEAGLE][id] == i ? "\y|Aktív|": szMenu2);
  612.             menu_additem(menu, szMenu, String);
  613.            
  614.         }  
  615.     }
  616.     else if(g_Wpn[id] == 12) {
  617.         for(new i; i < sizeof(WeaponUSP); i++) {
  618.             num_to_str(i, String, 5)
  619.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponUSP[i][Points]);
  620.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponUSP[i][GunName], g_SelectedGun[USP][id] == i ? "\y|Aktív|": szMenu2);
  621.             menu_additem(menu, szMenu, String);
  622.            
  623.         }  
  624.     }
  625.     else if(g_Wpn[id] == 13) {
  626.         for(new i; i < sizeof(WeaponGLOCK); i++) {
  627.             num_to_str(i, String, 5)
  628.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponGLOCK[i][Points]);
  629.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponGLOCK[i][GunName], g_SelectedGun[GLOCK][id] == i ? "\y|Aktív|": szMenu2);
  630.             menu_additem(menu, szMenu, String);            
  631.         }
  632.     }
  633.     menu_display(id, menu, 0);
  634.     return PLUGIN_HANDLED;
  635. }
  636. public hSkinChooser(id, menu, item) {
  637.     if(item == MENU_EXIT)
  638.     {
  639.         menu_destroy(menu);
  640.         return PLUGIN_CONTINUE;
  641.     }
  642.     switch(g_Wpn[id]) {
  643.         case 1: {
  644.             if(g_uPoints[M4A1][id] >= WeaponM4A1[item][Points]) {
  645.                 g_SelectedGun[M4A1][id] = item
  646.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  647.             }
  648.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  649.         }
  650.         case 2: {
  651.             if(g_uPoints[AK47][id] >= WeaponAK47[item][Points]) {
  652.                 g_SelectedGun[AK47][id] = item
  653.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  654.             }
  655.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  656.         }
  657.         case 3: {
  658.             if(g_uPoints[AWP][id] >= WeaponAWP[item][Points]) {
  659.                 g_SelectedGun[AWP][id] = item
  660.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  661.             }
  662.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  663.         }
  664.         case 4: {
  665.             if(g_uPoints[SCOUT][id] >= WeaponSCOUT[item][Points]) {
  666.                 g_SelectedGun[SCOUT][id] = item
  667.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  668.             }
  669.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  670.         }
  671.         case 5: {
  672.             if(g_uPoints[FAMAS][id] >= WeaponFAMAS[item][Points]) {
  673.                 g_SelectedGun[FAMAS][id] = item
  674.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  675.             }
  676.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  677.         }
  678.         case 6: {
  679.             if(g_uPoints[GALIL][id] >= WeaponAUG[item][Points]) {
  680.                 g_SelectedGun[GALIL][id] = item
  681.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  682.             }
  683.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  684.         }
  685.         case 7: {
  686.             if(g_uPoints[AUG][id] >= WeaponAUG[item][Points]) {
  687.                 g_SelectedGun[AUG][id] = item
  688.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  689.             }
  690.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  691.         }
  692.         case 8: {
  693.             if(g_uPoints[M3][id] >= WeaponM3[item][Points]) {
  694.                 g_SelectedGun[M3][id] = item
  695.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  696.             }
  697.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  698.         }  
  699.         case 9: {
  700.             if(g_uPoints[XM1014][id] >= WeaponXM1014[item][Points]) {
  701.                 g_SelectedGun[XM1014][id] = item
  702.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  703.             }
  704.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  705.         }  
  706.         case 10: {
  707.             if(g_uPoints[KNIFE][id] >= WeaponKNIFE[item][Points]) {
  708.                 g_SelectedGun[KNIFE][id] = item
  709.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  710.             }
  711.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  712.         }  
  713.         case 11: {
  714.             if(g_uPoints[DEAGLE][id] >= WeaponDEAGLE[item][Points]) {
  715.                 g_SelectedGun[DEAGLE][id] = item
  716.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  717.             }
  718.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  719.         }  
  720.         case 12: {
  721.             if(g_uPoints[USP][id] >= WeaponUSP[item][Points]) {
  722.                 g_SelectedGun[USP][id] = item
  723.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  724.             }
  725.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)        
  726.         }  
  727.         case 13: {
  728.             if(g_uPoints[GLOCK][id] >= WeaponGLOCK[item][Points]) {
  729.                 g_SelectedGun[GLOCK][id] = item
  730.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  731.             }
  732.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  733.            
  734.         }
  735.     }
  736.     menu_destroy(menu);
  737.     return PLUGIN_HANDLED;
  738. }
  739. stock UTIL_PlayWeaponAnimation(const Player, const Sequence) {
  740.     set_pev(Player, pev_weaponanim, Sequence)
  741.     message_begin(MSG_ONE_UNRELIABLE, SVC_WEAPONANIM, .player = Player)
  742.     write_byte(Sequence)
  743.     write_byte(pev(Player, pev_body))
  744.     message_end()
  745. }
  746. public plugin_cfg()
  747. {
  748.     g_SqlTuple = SQL_MakeDbTuple(SQL_Kiszolgaltato, SQL_FelhasznaloNev, SQL_Jelszo, SQL_Adatbazis_Neve)
  749.     static Query[10048]
  750.     new Len
  751.     Len += formatex(Query[Len], charsmax(Query), "CREATE TABLE IF NOT EXISTS `SkinMenu`")
  752.     Len += formatex(Query[Len], charsmax(Query)-Len, "(`Steamid` varchar(32) NOT NULL, ")
  753.     Len += formatex(Query[Len], charsmax(Query)-Len, "`olesek` int(11) NOT NULL,")
  754.     Len += formatex(Query[Len], charsmax(Query)-Len, "`szint` int(11) NOT NULL,")
  755.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsM4A1` int(11) NOT NULL,")
  756.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsAK47` int(11) NOT NULL,")
  757.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsAWP` int(11) NOT NULL,")
  758.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsSCOUT` int(11) NOT NULL,")
  759.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsFAMAS` int(11) NOT NULL,")
  760.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsGALIL` int(11) NOT NULL,")
  761.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsAUG` int(11) NOT NULL,")
  762.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsM3` int(11) NOT NULL,")
  763.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsXM1014` int(11) NOT NULL,")
  764.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsKNIFE` int(11) NOT NULL,")
  765.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsDEAGLE` int(11) NOT NULL,")
  766.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsUSP` int(11) NOT NULL,")
  767.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsGLOCK` int(11) NOT NULL,")
  768.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunM4A1` int(11) NOT NULL,")
  769.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunAK47` int(11) NOT NULL,")
  770.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunAWP` int(11) NOT NULL,")
  771.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunSCOUT` int(11) NOT NULL,")
  772.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunFAMAS` int(11) NOT NULL,")
  773.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunGALIL` int(11) NOT NULL,")
  774.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunAUG` int(11) NOT NULL,")
  775.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunM3` int(11) NOT NULL,")
  776.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunXM1014` int(11) NOT NULL,")
  777.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunKNIFE` int(11) NOT NULL,")
  778.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunDEAGLE` int(11) NOT NULL,")
  779.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunUSP` int(11) NOT NULL,")
  780.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunGLOCK` int(11) NOT NULL,")
  781.     Len += formatex(Query[Len], charsmax(Query)-Len, "`id` INT(11) NOT NULL AUTO_INCREMENT PRIMARY KEY)")
  782.     SQL_ThreadQuery(g_SqlTuple, "createTableThread", Query)
  783. }
  784. public Load(id)
  785. {
  786.     static Query[10048]
  787.     new Data[1], Steam[32]
  788.     get_user_authid(id, Steam, 31)
  789.     Data[0] = id
  790.     formatex(Query, charsmax(Query), "SELECT * FROM `SkinMenu` WHERE Steamid = ^"%s^";", Steam)
  791.     SQL_ThreadQuery(g_SqlTuple, "QuerySelectData", Query, Data, 1)
  792. }
  793. public QuerySelectData(FailState, Handle:Query, Error[], Errcode, Data[], DataSize, Float:Queuetime)
  794. {
  795.     if(FailState == TQUERY_CONNECT_FAILED || FailState == TQUERY_QUERY_FAILED) {
  796.         log_amx("%s", Error)
  797.         return
  798.     }
  799.     else {
  800.         new id = Data[0];
  801.         if(SQL_NumRows(Query) > 0)
  802.         {
  803.             g_uPoints[M4A1][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsM4A1"))
  804.             g_uPoints[AK47][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsAK47"))
  805.             g_uPoints[AWP][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsAWP"))
  806.             g_uPoints[SCOUT][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsSCOUT"))
  807.             g_uPoints[FAMAS][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsFAMAS"))
  808.             g_uPoints[GALIL][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsGALIL"))
  809.             g_uPoints[AUG][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsAUG"))
  810.             g_uPoints[M3][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsM3"))
  811.             g_uPoints[XM1014][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsXM1014"))
  812.             g_uPoints[KNIFE][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsKNIFE"))
  813.             g_uPoints[DEAGLE][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsUSP"))
  814.             g_uPoints[USP][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsGLOCK"))
  815.             g_uPoints[GLOCK][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsDEAGLE"))
  816.             g_SelectedGun[M4A1][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunM4A1"))
  817.             g_SelectedGun[AK47][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunAK47"))
  818.             g_SelectedGun[AWP][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunAWP"))
  819.             g_SelectedGun[SCOUT][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunSCOUT"))
  820.             g_SelectedGun[FAMAS][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunFAMAS"))
  821.             g_SelectedGun[GALIL][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunGALIL"))
  822.             g_SelectedGun[AUG][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunAUG"))
  823.             g_SelectedGun[M3][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunM3"))
  824.             g_SelectedGun[XM1014][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunXM1014"))
  825.             g_SelectedGun[KNIFE][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunKNIFE"))
  826.             g_SelectedGun[DEAGLE][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunDEAGLE"))
  827.             g_SelectedGun[USP][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunUSP"))
  828.             g_SelectedGun[GLOCK][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunGLOCK"))
  829.         }
  830.         else
  831.         {
  832.             Save(id)
  833.         }
  834.     }
  835. }
  836. public Save(id)
  837. {
  838.     static Query[256]
  839.     new Steam[32]; get_user_authid(id, Steam, 31)
  840.     formatex(Query, charsmax(Query), "INSERT INTO `SkinMenu` (`Steamid`) VALUES (^"%s^");", Steam)
  841.     SQL_ThreadQuery(g_SqlTuple, "QuerySetData", Query)
  842. }
  843. public Update(id)
  844. {
  845.     static Query[10048]
  846.     new Len
  847.     new Steam[32]; get_user_authid(id, Steam, 31)
  848.     Len += formatex(Query[Len], charsmax(Query)-Len, "olesek = ^"%i^", ", olesek[id])
  849.     Len += formatex(Query[Len], charsmax(Query)-Len, "szint = ^"%i^", ", szint[id])
  850.     Len += formatex(Query[Len], charsmax(Query), "UPDATE `SkinMenu` SET g_uPointsAWP = ^"%i^", ", g_uPoints[AWP][id])
  851.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsM4A1 = ^"%i^", ", g_uPoints[M4A1][id])
  852.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsAK47 = ^"%i^", ", g_uPoints[AK47][id])
  853.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsAWP = ^"%i^", ", g_uPoints[AWP][id])
  854.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsSCOUT = ^"%i^", ", g_uPoints[SCOUT][id])
  855.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsFAMAS = ^"%i^", ", g_uPoints[FAMAS][id])
  856.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsGALIL = ^"%i^", ", g_uPoints[GALIL][id])
  857.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsAUG= ^"%i^", ", g_uPoints[AUG][id])
  858.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsM3 = ^"%i^", ", g_uPoints[M3][id])
  859.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsXM1014 = ^"%i^", ", g_uPoints[XM1014][id])
  860.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsKNIFE = ^"%i^", ", g_uPoints[KNIFE][id])
  861.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsDEAGLE = ^"%i^", ", g_uPoints[DEAGLE][id])
  862.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsUSP = ^"%i^", ", g_uPoints[USP][id])
  863.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsGLOCK = ^"%i^", ", g_uPoints[GLOCK][id])
  864.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunM4A1 = ^"%i^", ", g_SelectedGun[M4A1][id])
  865.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunAK47 = ^"%i^", ", g_SelectedGun[AK47][id])
  866.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunAWP = ^"%i^", ", g_SelectedGun[AWP][id])
  867.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunSCOUT = ^"%i^", ", g_SelectedGun[SCOUT][id])
  868.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunFAMAS = ^"%i^", ", g_SelectedGun[FAMAS][id])
  869.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunGALIL = ^"%i^", ", g_SelectedGun[GALIL][id])
  870.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunAUG = ^"%i^", ", g_SelectedGun[AUG][id])
  871.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunM3 = ^"%i^", ", g_SelectedGun[M3][id])
  872.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunXM1014 = ^"%i^", ", g_SelectedGun[XM1014][id])
  873.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunKNIFE = ^"%i^", ", g_SelectedGun[KNIFE][id])
  874.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunDEAGLE = ^"%i^", ", g_SelectedGun[DEAGLE][id])
  875.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunUSP = ^"%i^", ", g_SelectedGun[USP][id])
  876.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunGLOCK = ^"%i^", ", g_SelectedGun[GLOCK][id])
  877.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunM4A1 = ^"%i^" WHERE Steamid = ^"%s^";", g_SelectedGun[M4A1][id], Steam)
  878.     SQL_ThreadQuery(g_SqlTuple, "QuerySetData", Query)
  879. }
  880. public createTableThread(FailState, Handle:Query, Error[], Errcode, Data[], DataSize, Float:Queuetime) {
  881.     if(FailState == TQUERY_CONNECT_FAILED)
  882.         set_fail_state("[HIBA*] NEM TUDTAM CSATLAKOZNI AZ ADATBAZISHOZ!")
  883.     else if(FailState == TQUERY_QUERY_FAILED)
  884.         set_fail_state("Query Error")
  885.     if(Errcode)
  886.         log_amx("[HIBA*] HIBAT DOBTAM: %s",Error)
  887. }
  888. public QuerySetData(FailState, Handle:Query, Error[], Errcode, Data[], DataSize, Float:Queuetime) {
  889.     if(FailState == TQUERY_CONNECT_FAILED || FailState == TQUERY_QUERY_FAILED) {
  890.         log_amx("%s", Error);
  891.         return;
  892.     }
  893. }
  894. public client_putinserver(id)
  895. {
  896.    
  897.     if(!is_user_bot(id))
  898.     {
  899.         Load(id);
  900.     }
  901.     hudkibe[id] = true;
  902.     set_task(1.0, "hudrendszer", id, _, _, "b");
  903.     olesek[id] = 0
  904.     szint[id] = 0
  905.     g_uPoints[M4A1][id] = 0
  906.     g_uPoints[AK47][id] = 0
  907.     g_uPoints[AWP][id] = 0
  908.     g_uPoints[SCOUT][id] = 0
  909.     g_uPoints[FAMAS][id] = 0
  910.     g_uPoints[GALIL][id] = 0
  911.     g_uPoints[AUG][id] = 0
  912.     g_uPoints[M3][id] = 0
  913.     g_uPoints[XM1014][id] = 0
  914.     g_uPoints[KNIFE][id] = 0
  915.     g_uPoints[DEAGLE][id] = 0
  916.     g_uPoints[USP][id] = 0
  917.     g_uPoints[GLOCK][id] = 0
  918.     g_SelectedGun[M4A1][id] = 0
  919.     g_SelectedGun[AK47][id] = 0
  920.     g_SelectedGun[AWP][id] = 0
  921.     g_SelectedGun[SCOUT][id] = 0
  922.     g_SelectedGun[FAMAS][id] = 0
  923.     g_SelectedGun[GALIL][id] = 0
  924.     g_SelectedGun[AUG][id] = 0
  925.     g_SelectedGun[M3][id] = 0
  926.     g_SelectedGun[XM1014][id] = 0
  927.     g_SelectedGun[KNIFE][id] = 0
  928.     g_SelectedGun[DEAGLE][id] = 0
  929.     g_SelectedGun[USP][id] = 0
  930.     g_SelectedGun[GLOCK][id] = 0
  931.     if(!is_user_bot(id))
  932.     Load(id);
  933.     return PLUGIN_CONTINUE
  934. }
  935. public client_disconnect(id)
  936. {
  937.     if(!is_user_bot(id))
  938.     {
  939.         Update(id);
  940.     }
  941.    
  942.     olesek[id] = 0
  943.     szint[id] = 0
  944.     return PLUGIN_CONTINUE
  945. }
  946. public hudrendszer(id)
  947. {
  948.     if(!hudkibe[id])
  949.         return;
  950.     if(is_user_alive(id))
  951.     {
  952.         set_hudmessage(0, 85, 255, 0.01, 0.18, 0, 6.0, 12.0)
  953.         show_hudmessage(id, "Öléseid: %d^nRangod: %s^nParancsok: /rang, /hud", olesek[id], rangok[szint[id]]);
  954.     }
  955. }  
  956. public hudkibekapcs(id)
  957. {
  958.     if(hudkibe[id])
  959.     {
  960.         ColorChat(id, GREEN, "^4[%s] ^1Kikapcsoltad a hudot.", PREFIX);
  961.         hudkibe[id] = false;
  962.     }
  963.     else
  964.     {
  965.         ColorChat(id, GREEN, "^4[%s] ^1Bekapcsoltad a hudot.", PREFIX);
  966.         hudkibe[id] = true;
  967.     }
  968. }
  969. public showrang(id)
  970. {
  971.     if(szint[id] != ASD+1)
  972.     {
  973.         ColorChat(id, GREEN, "^4[%s] ^3Rang: ^4%s ^1| ^3Öléseid: ^4%d ^1| ^3Kell még: ^4%d", PREFIX, rangok[szint[id]], olesek[id], szamok[szint[id]]-olesek[id]);
  974.     }
  975.     else
  976.     {
  977.         ColorChat(id, GREEN, "^4[%s] ^3Rang: ^4%s ^1| ^3Öléseid: ^4%d", PREFIX, rangok[szint[id]], olesek[id]);
  978.         ColorChat(id, GREEN, "^4[%s] ^1Elérted a legmagasabb ^3Rangot.", PREFIX);
  979.     }
  980.     return PLUGIN_HANDLED;
  981. }
  982. public sayhook(id)
  983. {
  984.     new message[192], nev[32], none[2][32], chat[192];
  985.     read_args(message, 191);
  986.     remove_quotes(message);
  987.    
  988.     formatex(none[0], 31, ""), formatex(none[1], 31, " ");
  989.    
  990.     if (message[0] == '@' || message[0] == '/' || message[0] == '#' || message[0] == '!' || equal (message, ""))
  991.         return PLUGIN_HANDLED_MAIN;
  992.    
  993.     if(!equali(message, none[0]) && !equali(message, none[1]))
  994.     {
  995.         get_user_name(id, nev, 31);
  996.         if(is_user_alive(id))
  997.         {
  998.             if(get_user_flags(id) & TULAJ)
  999.                 formatex(chat, 191, "^x04[Tulajdonos][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1000.             else if(get_user_flags(id) & FOADMIN)
  1001.                 formatex(chat, 191, "^x04[FőAdmin][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1002.             else if(get_user_flags(id) & ADMIN)
  1003.                 formatex(chat, 191, "^x04[Admin][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1004.             else if(get_user_flags(id) & VIP)
  1005.                 formatex(chat, 191, "^x04[VIP][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1006.             else
  1007.                 formatex(chat, 191, "^x04[%s]^3%s^x01: %s", rangok[szint[id]], nev, message);
  1008.         }
  1009.         else {
  1010.            
  1011.             if(get_user_flags(id) & TULAJ)
  1012.                 formatex(chat, 191, "^x01*Halott*^x04[Tulajdonos][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1013.             else if(get_user_flags(id) & FOADMIN)
  1014.                 formatex(chat, 191, "^x01*Halott*^x04[FőAdmin][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1015.             else if(get_user_flags(id) & ADMIN)
  1016.                 formatex(chat, 191, "^x01*Halott*^x04[Admin][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1017.             else if(get_user_flags(id) & VIP)
  1018.                 formatex(chat, 191, "^x01*Halott*^x04[VIP][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1019.             else
  1020.                 formatex(chat, 191, "^x01*Halott*^x04[%s]^3%s^x01: %s", rangok[szint[id]], nev, message);
  1021.         }
  1022.         if ( !is_user_connected(id) )
  1023.             return PLUGIN_CONTINUE;
  1024.        
  1025.         switch(cs_get_user_team(id)) //Prefix
  1026.         {
  1027.             case 1: ColorChat(0, RED, chat);
  1028.                 case 2: ColorChat(0, BLUE, chat);
  1029.             }
  1030.         if(cs_get_user_team(id) == CS_TEAM_SPECTATOR)
  1031.             ColorChat(0, GREY, chat);
  1032.         return PLUGIN_HANDLED_MAIN;
  1033.     }
  1034.     return PLUGIN_CONTINUE;
  1035. }
  1036. public sendmessage(color[])
  1037. {
  1038.     new teamName[32];
  1039.     for(new player = 1; player < get_maxplayers(); player++)
  1040.     {
  1041.         get_user_team (player, teamName, 9);
  1042.         teamf (player, color);
  1043.         elkuldes(player, Temp);
  1044.         teamf(player, teamName);
  1045.     }
  1046. }
  1047. public teamf(player, team[])
  1048. {
  1049.     message_begin(MSG_ONE, get_user_msgid("TeamInfo"), _, player);
  1050.     write_byte(player);
  1051.     write_string(team);
  1052.     message_end();
  1053. }
  1054. public elkuldes(player, Temp[])
  1055. {
  1056.     message_begin( MSG_ONE, get_user_msgid( "SayText" ), _, player);
  1057.     write_byte( player );
  1058.     write_string( Temp );
  1059.     message_end();
  1060. }
  1061. public plugin_end()
  1062. {
  1063.     SQL_FreeHandle(g_SqlTuple);
  1064. }


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.14. 11:45 
Offline
Jómunkásember
Avatar

Csatlakozott: 2019.08.20. 18:19
Hozzászólások: 312
Megköszönt másnak: 166 alkalommal
Megköszönték neki: 23 alkalommal
.

_________________
Hlmod.hu aktivitásom véget ért!

pbT# Fura*Csé: Nem tudsz plugint irni csak a copy és paste megy.


A hozzászólást 1 alkalommal szerkesztették, utoljára 8mTNNe 2020.02.18. 16:54-kor.

Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.18. 16:48 
Offline
Fanatikus

Csatlakozott: 2019.12.06. 20:00
Hozzászólások: 158
Megköszönt másnak: 13 alkalommal
8mTNNe írta:
Szia teszteld, össze vissza volt az egész Sql tábla.
  1. #include <amxmodx>
  2. #include <engine>
  3. #include <fakemeta>
  4. #include <colorchat>
  5. #include <cstrike>
  6. #include <sqlx>
  7.  
  8. #pragma tabsize 0
  9.  
  10. #define PLUGIN "New Plug-In"
  11. #define VERSION "1.0"
  12. #define AUTHOR "author"
  13.  
  14. #define KILL_POINT 5
  15. #define HEADSHOT_POINT 10
  16.  
  17. #define TULAJ ADMIN_IMMUNITY
  18. #define ADMIN ADMIN_LEVEL_E
  19. #define FOADMIN ADMIN_LEVEL_B
  20. #define VIP ADMIN_BAN
  21. #define ASD 15
  22.  
  23.  
  24. enum _:GunDatas
  25. {
  26. M4A1,
  27. AK47,
  28. AWP,
  29. SCOUT,
  30. FAMAS,
  31. GALIL,
  32. AUG,
  33. M3,
  34. XM1014,
  35. KNIFE,
  36. DEAGLE,
  37. USP,
  38. GLOCK,
  39. }
  40. new g_SelectedGun[GunDatas][33];
  41. new g_uPoints[GunDatas][33];
  42. new g_Wpn[33];
  43. new Handle:g_SqlTuple;
  44. new hudkibe[33];
  45. new olesek[33];
  46. new szint[33];
  47. new Temp[192];
  48.  
  49.  
  50. new const PREFIX[] = "\w[\y.:DarK*_*DemonS:.\w]\y ~\w Fun Szerver ~By ChaoS*"
  51. new const C_Perfix[] = "[.:DarK*_*DemonS:.]"
  52.  
  53. enum _:DATA
  54. {
  55. GunName[64],
  56. ModelName[64],
  57. Points[8],
  58. AnimType[8]
  59. }
  60. new const szamok[ASD] =
  61. {
  62. 100,
  63. 300,
  64. 550,
  65. 1000,
  66. 2000,
  67. 4000,
  68. 5000,
  69. 6000,
  70. 7000,
  71. 8000,
  72. 10000,
  73. 12000,
  74. 15000,
  75. 18000,
  76. 22000  
  77. }
  78. new const rangok[ASD+1][] =
  79. {
  80. "Újonc",
  81. "Honvéd",
  82. "Őrvezető",
  83. "Tizedes",
  84. "Szakaszvezető",
  85. "Őrmester",
  86. "Hadnagy",
  87. "Főhadnagy",
  88. "Százados",  
  89. "Őrnagy",
  90. "Alezredes",
  91. "Ezredes",
  92. "Dandártábornok",
  93. "Vezéragy",
  94. "Altábornok",
  95. "Vezérezredes"
  96. }
  97. new const WeaponM4A1[][DATA] =
  98. {
  99. {"M4a1 | Default", "models/darkdemonsfun_mod/Default/v_m4a1.mdl", 0, -1},
  100. {"M4a1 | Neon Mist", "models/darkdemonsfun_mod/m4a1/v_m4a1_neon_mist.mdl", 300, -1},
  101. {"M4a1 | Cyrex Retextured", "models/darkdemonsfun_mod/m4a1/v_m4a1_cyrex_retextured.mdl", 600, -1},
  102. {"M4a1 | Stickers", "models/darkdemonsfun_mod/m4a1/v_m4a1_Stickers.mdl", 900, -1},
  103. {"M4a1 | Flashback", "models/darkdemonsfun_mod/m4a1/v_m4a1_flashback.mdl", 1200, -1},
  104. {"M4a1 | Golden Coil", "models/darkdemonsfun_mod/m4a1/v_m4a1_golden_coil.mdl", 1500, -1},
  105. {"M4a1 | Colored", "models/darkdemonsfun_mod/m4a1/v_m4a1_colored.mdl", 1800, -1},
  106. {"M4a1 | Fire", "models/darkdemonsfun_mod/m4a1/v_m4a1_fire.mdl", 2100, -1},
  107. {"M4a1 | Halloween", "models/darkdemonsfun_mod/m4a1/v_m4a1_halloween.mdl", 2300, -1},
  108. {"M4a1 | Condor", "models/darkdemonsfun_mod/m4a1/v_m4a1_Condor.mdl", 2600, -1},
  109. {"M4a1 | Stickers", "models/darkdemonsfun_mod/m4a1/v_m4a1_Stickers.mdl", 2900, -1},
  110. {"M4a1 | Frontside Misty", "models/darkdemonsfun_mod/m4a1/v_m4a1_frontside_misty.mdl", 3200, -1},
  111. {"M4a1 | Dragon Lore", "models/darkdemonsfun_mod/m4a1/v_m4a1_dragon_lore.mdl", 3500, -1},
  112. {"M4A1 | High Foltage God", "models/darkdemonsfun_mod/m4a1/v_m4a1_hight_foltage_god.mdl", 3800, -1}
  113. }
  114. new const WeaponAK47[][DATA] =
  115. {
  116. {"Ak47 | Default", "models/darkdemonsfun_mod/Default/v_ak47.mdl", 0, -1},
  117. {"Ak47 | Ufo", "models/darkdemonsfun_mod/ak47/v_ak47_ufo.mdl", 300, -1},
  118. {"Ak47 | Arktika Led Dlya", "models/darkdemonsfun_mod/ak47/v_ak47_arktikaleddlya.mdl", 600, -1},
  119. {"Ak47 | Case Hardened", "models/darkdemonsfun_mod/ak47/v_ak47_case_hardened.mdl", 900, -1},
  120. {"Ak47 | Hydroponic", "models/darkdemonsfun_mod/ak47/v_ak47_hydroponic.mdl", 1200, -1},
  121. {"Ak47 | Jet Set", "models/darkdemonsfun_mod/ak47/v_ak47_jetset.mdl", 1500, -1},
  122. {"Ak47 | Ono", "models/darkdemonsfun_mod/ak47/v_ak47_Ono.mdl", 1500, -1},
  123. {"Ak47 | Pinstripe", "models/darkdemonsfun_mod/ak47/v_ak47_pinstripe.mdl", 1800, -1},
  124. {"Ak47 | Point Dissary", "models/darkdemonsfun_mod/ak47/v_ak47_point_dissary.mdl", 2100, -1},
  125. {"Ak47 | Polar Bear", "models/darkdemonsfun_mod/ak47/v_ak47_polar_bear.mdl", 2400, -1},
  126. {"Ak47 | Red Force", "models/darkdemonsfun_mod/ak47/v_ak47_red_force.mdl", 2700, -1},
  127. {"Ak47 | Shark Attack", "models/darkdemonsfun_mod/ak47/v_ak47_shark_attack.mdl", 3000, -1},
  128. {"Ak47 | Anubis", "models/darkdemonsfun_mod/ak47/v_ak47_anubis.mdl", 3300, -1},
  129. {"Ak47 | Neon Revolution", "models/darkdemonsfun_mod/ak47/v_ak47_neon_revolution.mdl", 3600, -1},
  130. {"Ak47 | Purple 94", "models/darkdemonsfun_mod/ak47/v_ak47_purple_94.mdl", 3900, -1},
  131. {"Ak47 | Stainl HD", "models/darkdemonsfun_mod/ak47/v_ak47_stainl.mdl", 4200, -1},
  132. {"Ak47 | Shadow", "models/darkdemonsfun_mod/ak47/v_ak47_shadow.mdl", 4500, -1},
  133. {"Ak47 | Gold", "models/darkdemonsfun_mod/ak47/v_ak47_gold.mdl", 4800, -1}
  134. }
  135. new const WeaponAWP[][DATA] =
  136. {
  137. {"Awp | Default", "models/darkdemonsfun_mod/Default/v_awp.mdl", 0, -1},
  138. {"Awp | Leviathan Kiss", "models/darkdemonsfun_mod/awp/v_awp_leviathan_kiss.mdl", 300, -1},
  139. {"Awp | Graphite", "models/darkdemonsfun_mod/awp/v_awp_graphite.mdl", 600, -1},
  140. {"Awp | Meduza", "models/darkdemonsfun_mod/awp/v_awp_medusa.mdl", 900, -1},
  141. {"Awp | Banshee", "models/darkdemonsfun_mod/awp/v_awp_banshee.mdl", 1200, -1},
  142. {"Awp | Fire", "models/darkdemonsfun_mod/awp/v_awp_fire.mdl", 1500, -1},
  143. {"Awp | Azure Fantasy", "models/darkdemonsfun_mod/awp/v_awp_azure_fantasy.mdl", 1800, -1},
  144. {"Awp | Navi", "models/darkdemonsfun_mod/awp/v_awp_navi.mdl", 2100, -1},
  145. {"Awp | Elitebuild", "models/darkdemonsfun_mod/awp/v_awp_elitebuild.mdl", 2400, -1},
  146. {"Awp | Fever Dream", "models/darkdemonsfun_mod/awp/v_awp_fever_dream.mdl", 2700, -1}
  147. }
  148. new const WeaponSCOUT[][DATA] =
  149. {
  150. {"Scout | Default", "models/darkdemonsfun_mod/Default/v_scout.mdl", 0, -1},
  151. {"Scout | Dragonfire", "models/darkdemonsfun_mod/scout/v_scout_dragonfire.mdl", 300, -1},
  152. {"Scout | Blood Water", "models/darkdemonsfun_mod/scout/v_scout_blood_water.mdl", 600, -1},
  153. {"Scout | Shooting Dead", "models/darkdemonsfun_mod/scout/v_scout_shooting_dead.mdl", 900, -1},
  154. {"Scout | Bluediamond", "models/darkdemonsfun_mod/scout/v_scout_bluediamond.mdl", 1200, -1},
  155. {"Scout | Cityguardian", "models/darkdemonsfun_mod/scout/v_scout_cityguardian.mdl", 1500, -1}
  156. }
  157. new const WeaponFAMAS[][DATA] =
  158. {
  159. {"Famas | Default", "models/darkdemonsfun_mod/Default/v_famas.mdl", 0, -1},
  160. {"Famas | Neon Mist", "models/darkdemonsfun_mod/famas/v_famas_neon_mist.mdl", 300, -1},
  161. {"Famas | Psycho", "models/darkdemonsfun_mod/famas/v_famas_psycho.mdl", 600, -1},
  162. {"Famas | Skull", "models/darkdemonsfun_mod/famas/v_famas_skull.mdl", 900, -1},
  163. {"Famas | 4TH", "models/darkdemonsfun_mod/famas/v_famas_4th.mdl", 1200, -1},
  164. {"Famas | Asiimov", "models/darkdemonsfun_mod/famas/v_famas_asiimov.mdl", 1500, -1},
  165. {"Famas | Redline", "models/darkdemonsfun_mod/famas/v_famas_redline.mdl", 1800, -1},
  166. {"Famas | Pulze", "models/darkdemonsfun_mod/famas/v_famas_pulze.mdl", 2100, -1}
  167. }
  168. new const WeaponGALIL[][DATA] =
  169. {
  170. {"Galil | Default", "models/darkdemonsfun_mod/Default/v_galil.mdl", 0, -1},
  171. {"Galil | Coup", "models/darkdemonsfun_mod/galil/v_galil_Coup.mdl", 300, -1},
  172. {"Galil | Stone col", "models/darkdemonsfun_mod/galil/v_galil_stone_col.mdl", 600, -1},
  173. {"Galil | Orange", "models/darkdemonsfun_mod/galil/v_galil_orange.mdl", 900, -1}
  174. }
  175. new const WeaponAUG[][DATA] =
  176. {
  177. {"Aug | Default", "models/darkdemonsfun_mod/Default/v_aug.mdl", 0, -1},
  178. {"Aug | Azuro", "models/darkdemonsfun_mod/aug/v_aug_azuro.mdl", 300, -1},
  179. {"Aug | Next Tec", "models/darkdemonsfun_mod/aug/v_aug_Next_Tec.mdl",  600, -1},
  180. {"Aug | White Fa", "models/darkdemonsfun_mod/aug/v_aug_whitefa.mdl", 900, -1},
  181. {"Aug | Lavale", "models/darkdemonsfun_mod/aug/v_aug_Lavale.mdl", 1200, -1}
  182. }
  183. new const WeaponM3[][DATA] =
  184. {
  185. {"M3 | Default", "models/darkdemonsfun_mod/Default/v_m3.mdl", 0, -1},
  186. {"M3 | Nova Hyper Beast", "models/darkdemonsfun_mod/m3/v_m3_novahyperbeast.mdl", 300, -1},
  187. {"M3 | Sawed off Gray", "models/darkdemonsfun_mod/m3/v_m3_sawed-off-gray.mdl", 600, -1},
  188. {"M3 | Sawed off Limitel", "models/darkdemonsfun_mod/m3/v_m3_sawed-off-limel.mdl", 900, -1},
  189. {"M3 | Sawed off Seren", "models/darkdemonsfun_mod/m3/v_m3_sawed-off-seren.mdl", 1200, -1},
  190. {"M3 | Yellow Flowe", "models/darkdemonsfun_mod/m3/v_m3_yellow-flowe.mdl", 1500, -1}
  191. }
  192. new const WeaponXM1014[][DATA] =
  193. {
  194. {"XM1014 | Default", "models/darkdemonsfun_mod/Default/v_xm1014.mdl", 0, -1},
  195. {"XM1014 | Vandal", "models/darkdemonsfun_mod/xm1014/v_xm1014_vandal.mdl", 300, -1},
  196. {"XM1014 | Northern", "models/darkdemonsfun_mod/xm1014/v_xm1014_northern.mdl", 600, -1},
  197. {"XM1014 | Lego", "models/darkdemonsfun_mod/xm1014/v_xm1014_lego.mdl", 900, -1},
  198. {"XM1014 | Teclu Burner", "models/darkdemonsfun_mod/xm1014/v_xm1014_teclu_bu.mdl", 1200, -1},
  199. {"XM1014 | Heaven", "models/darkdemonsfun_mod/xm1014/v_xm1014_heaven.mdl", 1500, -1},
  200. {"XM1014 | Flame", "models/darkdemonsfun_mod/xm1014/v_xm1014_flame.mdl", 1800, -1},
  201. {"XM1014 | Asiimov", "models/darkdemonsfun_mod/xm1014/v_xm1014_asiimov.mdl", 2100, -1},
  202. {"XM1014 | Lego", "models/darkdemonsfun_mod/xm1014/v_xm1014_lego.mdl", 2400, -1},
  203. {"XM1014 | Tecu", "models/darkdemonsfun_mod/xm1014/v_xm1014_tecu.mdl", 2700, -1},
  204. {"XM1014 | Snow Cam", "models/darkdemonsfun_mod/xm1014/v_xm1014_Snow_cam.mdl", 3000, -1},
  205. {"XM1014 | Haven", "models/darkdemonsfun_mod/xm1014/v_xm1014_Haven.mdl", 3300, -1},
  206. {"XM1014 | Flame", "models/darkdemonsfun_mod/xm1014/v_xm1014_Flame.mdl", 3600, -1},
  207. {"XM1014 | Asiimow", "models/darkdemonsfun_mod/xm1014/v_xm1014_Asiimow.mdl", 3900, -1},
  208. {"XM1014 | Teclu Burner", "models/darkdemonsfun_mod/xm1014/v_xm1014_teclu_burner.mdl", 4200, -1},
  209. {"XM1014 | Heaven Guard", "models/darkdemonsfun_mod/xm1014/v_xm1014_heaven_guard.mdl", 4500, -1}  
  210. }
  211. new const WeaponKNIFE[][DATA] =
  212. {
  213. {"Knife | Default", "models/darkdemonsfun_mod/Default/v_knife.mdl", 0, -1},
  214. {"Knife | Navi", "models/darkdemonsfun_mod/knife/v_knife_navi.mdl", 300, -1},
  215. {"Knife | Green", "models/darkdemonsfun_mod/knife/v_knife_green.mdl", 600, -1},
  216. {"Knife | Abys", "models/darkdemonsfun_mod/knife/v_knife_abys.mdl", 900, -1},
  217. {"Knife | Armage", "models/darkdemonsfun_mod/knife/v_knife_armage.mdl", 1200, -1},
  218. {"Knife | Neon Rider", "models/darkdemonsfun_mod/knife/v_knife_neon_rider.mdl", 1500, -1},
  219. {"Knife | Slaught", "models/darkdemonsfun_mod/knife/v_knife_slaught.mdl", 1800,-1},
  220. {"Knife | Tiger", "models/darkdemonsfun_mod/knife/v_knife_tiger.mdl", 2100, -1}
  221. }
  222. new const WeaponDEAGLE[][DATA] =
  223. {
  224. {"Deagle | Default", "models/darkdemonsfun_mod/Default/v_deagle.mdl", 0, -1},
  225. {"Deagle | Glory", "models/darkdemonsfun_mod/deagle/v_deagle_glory.mdl", 300, -1},
  226. {"Deagle | Obstacle", "models/darkdemonsfun_mod/deagle/v_deagle_obstacle.mdl", 600, -1},
  227. {"Deagle | Kumicho Dragon", "models/darkdemonsfun_mod/deagle/v_deagle_kumicho-dragon.mdl", 900, -1},
  228. {"Deagle | Salient v2", "models/darkdemonsfun_mod/deagle/v_deagle_salientv2.mdl", 1200, -1},
  229. {"Deagle | Bloodsport", "models/darkdemonsfun_mod/deagle/v_deagle_bloodsport.mdl", 1500, -1},
  230. {"Deagle | Pilot", "models/darkdemonsfun_mod/deagle/v_deagle_point_pilot.mdl", 1800, -1},
  231. {"Deagle | Doomsday", "models/darkdemonsfun_mod/deagle/v_deagle_doomsday.mdl", 2100, -1},
  232. {"Deagle | Machine", "models/darkdemonsfun_mod/deagle/v_deagle_machine.mdl", 2400, -1},
  233. {"Deagle | Blaze", "models/darkdemonsfun_mod/deagle/v_deagle_blaze.mdl", 2700, -1},
  234. {"Deagle | Alexandr", "models/darkdemonsfun_mod/deagle/v_deagle_Alexandr.mdl", 3000, -1},
  235. {"Deagle | Stick", "models/darkdemonsfun_mod/deagle/v_deagle_Stick.mdl", 3300, -1},
  236. {"Deagle | Bloodspo", "models/darkdemonsfun_mod/deagle/v_deagle_Bloodspo.mdl", 3600, -1},
  237. {"Deagle | Sunset", "models/darkdemonsfun_mod/deagle/v_deagle_sunset.mdl", 3900, -1},
  238. {"Deagle | Cobalt", "models/darkdemonsfun_mod/deagle/v_deagle_cobalt.mdl", 4200, -1},
  239. {"Deagle | Toxic", "models/darkdemonsfun_mod/deagle/v_deagle_toxic.mdl", 4500, -1},
  240. {"Deagle | Dooms", "models/darkdemonsfun_mod/deagle/v_deagle_dooms.mdl", 4800, -1},
  241. {"Deagle | Eag", "models/darkdemonsfun_mod/deagle/v_deagle_Eag.mdl", 5100, -1},
  242. {"Deagle | Crims", "models/darkdemonsfun_mod/deagle/v_deagle_crims.mdl", 5400, -1}
  243. }
  244. new const WeaponUSP[][DATA] =
  245. {
  246. {"Usp | Default", "models/darkdemonsfun_mod/Default/v_usp.mdl", 0, -1},
  247. {"Usp | Green Drako", "models/darkdemonsfun_mod/usp/v_usp_green_drako.mdl", 300, -1},
  248. {"Usp | Stealth Hunter", "models/darkdemonsfun_mod/usp/v_usp_stealth_hunter.mdl", 600, -1},
  249. {"Usp | Oil Filter", "models/darkdemonsfun_mod/usp/v_usp_oil-filter.mdl", 900, -1},
  250. {"Usp | Royal Blue Stickers", "models/darkdemonsfun_mod/usp/v_usp_royal_blue_stickers.mdl", 1200, -1},
  251. {"Usp | Pink", "models/darkdemonsfun_mod/usp/v_usp_Pink.mdl", 1500, -1},
  252. {"Usp | Next Tec", "models/darkdemonsfun_mod/usp/v_usp_next_tec.mdl", 1800, -1},
  253. {"Usp | Fat Cap", "models/darkdemonsfun_mod/usp/v_usp_fat_cap.mdl", 2100, -1},
  254. {"Usp | Revena", "models/darkdemonsfun_mod/usp/v_usp_revena.mdl", 2400, -1},
  255. {"Usp | Cutv2", "models/darkdemonsfun_mod/usp/v_usp_cutv2.mdl", 2700, -1}
  256. }
  257. new const WeaponGLOCK[][DATA] =
  258. {
  259. {"Glock18 | Default",  "models/darkdemonsfun_mod/Default/v_glock18.mdl", 0, -1},
  260. {"Glock18 | Water Ele", "models/darkdemonsfun_mod/glock/v_glock18_water_ele.mdl", 300, -1},
  261. {"Glock18 | Wasteland", "models/darkdemonsfun_mod/glock/v_glock18_wasteland.mdl", 600, -1},
  262. {"Glock18 | Cubes Wor", "models/darkdemonsfun_mod/glock/v_glock18_cubes_wor.mdl", 900, -1},
  263. {"Glock18 | Fire", "models/darkdemonsfun_mod/glock/v_glock18_fire.mdl", 1200, -1},
  264. {"Glock18 | Oxid Blaze", "models/darkdemonsfun_mod/glock/v_glock18_oxid_blaze.mdl", 1500, -1},
  265. {"Glock18 | Web Green", "models/darkdemonsfun_mod/glock/v_glock18_webgreen.mdl", 1800, -1}
  266. }
  267. new const MainStrings[][] =
  268. {
  269. "«M4a1 Skinek»",
  270. "«Ak47 Skinek»",
  271. "«Awp Skinek»",
  272. "«Scout Skinek»",
  273. "«Famas Skinek»",
  274. "«Galil Skinek»",
  275. "«Aug Skinek»",
  276. "«M3 Skinek»",
  277. "«Xm1014 Skinek»",
  278. "«Kés Skinek»",
  279. "«Deagle Skinek»",
  280. "«Usp Skinek»",
  281. "«Glock18 Skinek»"
  282. }
  283. public plugin_init() {
  284. register_plugin(PLUGIN, VERSION, AUTHOR)
  285. register_clcmd("say /menu", "openMainMenu")
  286. register_clcmd("say /add", "Addolas")
  287. register_clcmd("say /rang", "showrang");
  288. register_clcmd("say /hud", "hudkibekapcs");
  289. register_impulse(201, "openMainMenu");
  290. register_event("DeathMsg","Halal","a")
  291. register_event("CurWeapon", "evChangeWeapon", "be", "1=1")
  292. register_impulse(100, "cmdInspectWeap");
  293. register_clcmd("say", "sayhook");
  294. }
  295. public Addolas(id)
  296. {
  297. g_uPoints[M4A1][id] += 300
  298. g_uPoints[AK47][id] += 300
  299. g_uPoints[AWP][id] += 300
  300. g_uPoints[SCOUT][id] += 300
  301. g_uPoints[FAMAS][id] += 300
  302. g_uPoints[GALIL][id] += 300
  303. g_uPoints[AUG][id] += 300
  304. g_uPoints[M3][id] += 300
  305. g_uPoints[XM1014][id] += 300
  306. g_uPoints[KNIFE][id] += 300
  307. g_uPoints[DEAGLE][id] += 300
  308. g_uPoints[USP][id] += 300
  309. g_uPoints[GLOCK][id] += 300;
  310. }
  311. public plugin_precache() {
  312. for(new i;i < sizeof(WeaponM4A1); i++) precache_model(WeaponM4A1[i][ModelName])
  313. for(new i;i < sizeof(WeaponAK47); i++) precache_model(WeaponAK47[i][ModelName])
  314. for(new i;i < sizeof(WeaponAWP); i++) precache_model(WeaponAWP[i][ModelName])
  315. for(new i;i < sizeof(WeaponSCOUT); i++) precache_model(WeaponSCOUT[i][ModelName])
  316. for(new i;i < sizeof(WeaponFAMAS); i++) precache_model(WeaponFAMAS[i][ModelName])
  317. for(new i;i < sizeof(WeaponGALIL); i++) precache_model(WeaponGALIL[i][ModelName])
  318. for(new i;i < sizeof(WeaponAUG); i++) precache_model(WeaponAUG[i][ModelName])
  319. for(new i;i < sizeof(WeaponM3); i++) precache_model(WeaponM3[i][ModelName])
  320. for(new i;i < sizeof(WeaponXM1014); i++) precache_model(WeaponXM1014[i][ModelName])
  321. for(new i;i < sizeof(WeaponKNIFE); i++) precache_model(WeaponKNIFE[i][ModelName])
  322. for(new i;i < sizeof(WeaponDEAGLE); i++) precache_model(WeaponDEAGLE[i][ModelName])
  323. for(new i;i < sizeof(WeaponUSP); i++) precache_model(WeaponUSP[i][ModelName])
  324. for(new i;i < sizeof(WeaponGLOCK); i++) precache_model(WeaponGLOCK[i][ModelName])
  325. }
  326. public cmdInspectWeap(id) {
  327. if(!is_user_alive(id)) return PLUGIN_HANDLED;
  328. new Wpns = get_user_weapon(id)
  329.  
  330. switch(Wpns) {
  331. case CSW_M4A1: {
  332. if(WeaponM4A1[g_SelectedGun[M4A1][id]][AnimType] == -1) return PLUGIN_HANDLED;
  333. UTIL_PlayWeaponAnimation(id, WeaponM4A1[g_SelectedGun[M4A1][id]][AnimType]);
  334. }
  335. case CSW_AK47: {
  336. if(WeaponAK47[g_SelectedGun[AK47][id]][AnimType] == -1) return PLUGIN_HANDLED;
  337. UTIL_PlayWeaponAnimation(id, WeaponAK47[g_SelectedGun[AK47][id]][AnimType]);
  338. }
  339. case CSW_AWP: {
  340. if(WeaponAWP[g_SelectedGun[AWP][id]][AnimType] == -1) return PLUGIN_HANDLED;
  341. UTIL_PlayWeaponAnimation(id, WeaponAWP[g_SelectedGun[AWP][id]][AnimType]);
  342. }
  343. case CSW_SCOUT: {
  344. if(WeaponSCOUT[g_SelectedGun[SCOUT][id]][AnimType] == -1) return PLUGIN_HANDLED;
  345. UTIL_PlayWeaponAnimation(id, WeaponSCOUT[g_SelectedGun[SCOUT][id]][AnimType]);
  346. }
  347. case CSW_FAMAS: {
  348. if(WeaponFAMAS[g_SelectedGun[FAMAS][id]][AnimType] == -1) return PLUGIN_HANDLED;
  349. UTIL_PlayWeaponAnimation(id, WeaponFAMAS[g_SelectedGun[FAMAS][id]][AnimType]);
  350. }
  351. case CSW_GALIL: {
  352. if(WeaponGALIL[g_SelectedGun[GALIL][id]][AnimType] == -1) return PLUGIN_HANDLED;
  353. UTIL_PlayWeaponAnimation(id, WeaponGALIL[g_SelectedGun[GALIL][id]][AnimType]);
  354. }
  355. case CSW_AUG: {
  356. if(WeaponAUG[g_SelectedGun[AUG][id]][AnimType] == -1) return PLUGIN_HANDLED;
  357. UTIL_PlayWeaponAnimation(id, WeaponAUG[g_SelectedGun[AUG][id]][AnimType]);
  358. }
  359. case CSW_M3: {
  360. if(WeaponM3[g_SelectedGun[M3][id]][AnimType] == -1) return PLUGIN_HANDLED;
  361. UTIL_PlayWeaponAnimation(id, WeaponM3[g_SelectedGun[M3][id]][AnimType]);
  362. }
  363. case CSW_XM1014: {    
  364. if(WeaponXM1014[g_SelectedGun[XM1014][id]][AnimType] == -1) return PLUGIN_HANDLED;
  365. UTIL_PlayWeaponAnimation(id, WeaponXM1014[g_SelectedGun[XM1014][id]][AnimType]);
  366. }
  367. case CSW_KNIFE: {
  368. if(WeaponKNIFE[g_SelectedGun[KNIFE][id]][AnimType] == -1) return PLUGIN_HANDLED;
  369. UTIL_PlayWeaponAnimation(id, WeaponKNIFE[g_SelectedGun[KNIFE][id]][AnimType]);
  370. }
  371. case CSW_DEAGLE: {
  372. if(WeaponDEAGLE[g_SelectedGun[DEAGLE][id]][AnimType] == -1) return PLUGIN_HANDLED;
  373. UTIL_PlayWeaponAnimation(id, WeaponDEAGLE[g_SelectedGun[DEAGLE][id]][AnimType]);
  374. }
  375. case CSW_USP: {
  376. if(WeaponUSP[g_SelectedGun[USP][id]][AnimType] == -1) return PLUGIN_HANDLED;
  377. UTIL_PlayWeaponAnimation(id, WeaponUSP[g_SelectedGun[USP][id]][AnimType]);
  378. }
  379. case CSW_GLOCK18: {
  380. if(WeaponGLOCK[g_SelectedGun[GLOCK][id]][AnimType] == -1) return PLUGIN_HANDLED;
  381. UTIL_PlayWeaponAnimation(id, WeaponGLOCK[g_SelectedGun[GLOCK][id]][AnimType]);
  382. }  
  383. }  
  384. return PLUGIN_HANDLED
  385. }
  386. public evChangeWeapon(id) {
  387. switch(get_user_weapon(id)) {
  388. case CSW_M4A1: entity_set_string(id, EV_SZ_viewmodel, WeaponM4A1[g_SelectedGun[M4A1][id]][ModelName]);
  389. case CSW_AK47: entity_set_string(id, EV_SZ_viewmodel, WeaponAK47[g_SelectedGun[AK47][id]][ModelName]);
  390. case CSW_AWP: entity_set_string(id, EV_SZ_viewmodel, WeaponAWP[g_SelectedGun[AWP][id]][ModelName]);
  391. case CSW_SCOUT: entity_set_string(id, EV_SZ_viewmodel, WeaponSCOUT[g_SelectedGun[SCOUT][id]][ModelName]);
  392. case CSW_FAMAS: entity_set_string(id, EV_SZ_viewmodel, WeaponFAMAS[g_SelectedGun[FAMAS][id]][ModelName]);
  393. case CSW_GALIL: entity_set_string(id, EV_SZ_viewmodel, WeaponGALIL[g_SelectedGun[GALIL][id]][ModelName]);
  394. case CSW_AUG: entity_set_string(id, EV_SZ_viewmodel, WeaponAUG[g_SelectedGun[AUG][id]][ModelName]);
  395. case CSW_M3: entity_set_string(id, EV_SZ_viewmodel, WeaponM3[g_SelectedGun[M3][id]][ModelName]);
  396. case CSW_XM1014: entity_set_string(id, EV_SZ_viewmodel, WeaponXM1014[g_SelectedGun[XM1014][id]][ModelName]);
  397. case CSW_KNIFE: entity_set_string(id, EV_SZ_viewmodel, WeaponKNIFE[g_SelectedGun[KNIFE][id]][ModelName]);
  398. case CSW_DEAGLE: entity_set_string(id, EV_SZ_viewmodel, WeaponDEAGLE[g_SelectedGun[DEAGLE][id]][ModelName]);
  399. case CSW_USP: entity_set_string(id, EV_SZ_viewmodel, WeaponUSP[g_SelectedGun[USP][id]][ModelName])
  400. case CSW_GLOCK18: entity_set_string(id, EV_SZ_viewmodel, WeaponGLOCK[g_SelectedGun[GLOCK][id]][ModelName]);
  401. }
  402. return PLUGIN_CONTINUE
  403. }
  404. public Halal() {
  405.  
  406. new iAttacker = read_data(1)
  407. new iVictim = read_data(2)
  408. new iHs = read_data(3)
  409. new killer = read_data(4);
  410. new victim = read_data(5);
  411.  
  412. if(iAttacker == iVictim || iAttacker == 0) return PLUGIN_HANDLED
  413. if(killer != victim)
  414. olesek[killer]++
  415.  
  416. while(olesek[killer] >= szamok[szint[killer]])  
  417. szint[killer]++
  418.  
  419. new iPoints = iHs ? HEADSHOT_POINT : KILL_POINT
  420. switch(get_user_weapon(iAttacker))
  421. {
  422. case CSW_AK47: g_uPoints[AK47][iAttacker] += iPoints
  423. case CSW_M4A1: g_uPoints[M4A1][iAttacker] += iPoints
  424. case CSW_AWP: g_uPoints[AWP][iAttacker] += iPoints
  425. case CSW_SCOUT: g_uPoints[SCOUT][iAttacker] += iPoints
  426. case CSW_FAMAS: g_uPoints[FAMAS][iAttacker] += iPoints
  427. case CSW_GALIL: g_uPoints[GALIL][iAttacker] += iPoints
  428. case CSW_AUG: g_uPoints[AUG][iAttacker] += iPoints
  429. case CSW_M3: g_uPoints[M3][iAttacker] += iPoints
  430. case CSW_XM1014: g_uPoints[XM1014][iAttacker] += iPoints
  431. case CSW_KNIFE: g_uPoints[KNIFE][iAttacker] += iPoints
  432. case CSW_DEAGLE: g_uPoints[DEAGLE][iAttacker] += iPoints
  433. case CSW_USP: g_uPoints[USP][iAttacker] += iPoints
  434. case CSW_GLOCK18: g_uPoints[GLOCK][iAttacker] += iPoints
  435. }
  436. set_hudmessage(random(256), random(256), random(256), -1.0, 0.85, 0, 6.0, 3.0);
  437. show_hudmessage(iAttacker, "+%i Pont", iPoints);
  438. return PLUGIN_CONTINUE;
  439. }
  440. public openMainMenu(id)
  441. {
  442.     new szMenu[121], String[6]
  443.     formatex(szMenu, charsmax(szMenu), "%s \wFőmenü", PREFIX)
  444.     new menu = menu_create(szMenu, "hMainMenu");
  445.    
  446.     for(new i ;i < sizeof(MainStrings); i++)
  447.     {
  448.     num_to_str(i, String, 5)
  449.     formatex(szMenu, charsmax(szMenu), MainStrings[i]);
  450.     menu_additem(menu, szMenu, String);
  451.     }
  452.     menu_display(id, menu, 0);
  453.     return PLUGIN_HANDLED;
  454. }
  455. public hMainMenu(id, menu, item)
  456. {
  457.     if(item == MENU_EXIT)
  458.     {
  459.         menu_destroy(menu);
  460.         return PLUGIN_HANDLED;
  461.     }
  462.     g_Wpn[id] = item+1
  463.     openSkinMenu(id)
  464.     menu_destroy(menu);
  465.     return PLUGIN_HANDLED;
  466. }
  467. public openSkinMenu(id)
  468. {
  469.     new szMenu[121], szMenu2[64], String[15]
  470.     if(g_Wpn[id] == 1) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  471.     g_uPoints[M4A1][id])
  472.     else if(g_Wpn[id] == 2) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1], g_uPoints[AK47][id])
  473.     else if(g_Wpn[id] == 3) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1], g_uPoints[AWP][id])
  474.     else if(g_Wpn[id] == 4) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1], g_uPoints[SCOUT][id])
  475.     else if(g_Wpn[id] == 5) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1], g_uPoints[FAMAS][id])
  476.     if(g_Wpn[id] == 6) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  477.     g_uPoints[GALIL][id])
  478.     if(g_Wpn[id] == 7) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  479.     g_uPoints[AUG][id])
  480.     if(g_Wpn[id] == 8) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  481.     g_uPoints[M3][id])
  482.     if(g_Wpn[id] == 9) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  483.     g_uPoints[XM1014][id])
  484.     if(g_Wpn[id] == 10) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  485.     g_uPoints[KNIFE][id])
  486.     if(g_Wpn[id] == 11) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  487.     g_uPoints[DEAGLE][id])
  488.     if(g_Wpn[id] == 12) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  489.     g_uPoints[USP][id])
  490.     if(g_Wpn[id] == 13) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX, MainStrings[g_Wpn[id]-1],
  491.     g_uPoints[GLOCK][id])
  492.     new menu = menu_create(szMenu, "hSkinChooser");
  493.     if(g_Wpn[id] == 1) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  494.     MainStrings[g_Wpn[id]-1], g_uPoints[M4A1][id])
  495.     if(g_Wpn[id] == 2) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  496.     MainStrings[g_Wpn[id]-1], g_uPoints[AK47][id])
  497.     if(g_Wpn[id] == 3) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  498.     MainStrings[g_Wpn[id]-1], g_uPoints[AWP][id])
  499.     if(g_Wpn[id] == 4) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  500.     MainStrings[g_Wpn[id]-1], g_uPoints[SCOUT][id])
  501.     if(g_Wpn[id] == 5) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  502.     MainStrings[g_Wpn[id]-1], g_uPoints[FAMAS][id])
  503.     if(g_Wpn[id] == 6) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  504.     MainStrings[g_Wpn[id]-1], g_uPoints[GALIL][id])
  505.     if(g_Wpn[id] == 7) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  506.     MainStrings[g_Wpn[id]-1], g_uPoints[AUG][id])
  507.     if(g_Wpn[id] == 8) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  508.     MainStrings[g_Wpn[id]-1], g_uPoints[M3][id])
  509.     if(g_Wpn[id] == 10) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  510.     MainStrings[g_Wpn[id]-1], g_uPoints[XM1014][id])
  511.     if(g_Wpn[id] == 11) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  512.     MainStrings[g_Wpn[id]-1], g_uPoints[KNIFE][id])
  513.     if(g_Wpn[id] == 12) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  514.     MainStrings[g_Wpn[id]-1], g_uPoints[DEAGLE][id])
  515.     if(g_Wpn[id] == 13) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  516.     MainStrings[g_Wpn[id]-1], g_uPoints[USP][id])
  517.     if(g_Wpn[id] == 14) formatex(szMenu, charsmax(szMenu), "%s \w%s^n\wPont: \y%i\d", PREFIX,
  518.     MainStrings[g_Wpn[id]-1], g_uPoints[GLOCK][id])
  519.    
  520.    
  521.    
  522.    
  523.     if(g_Wpn[id] == 1) {
  524.         for(new i; i < sizeof(WeaponM4A1); i++) {
  525.             num_to_str(i, String, 5)
  526.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponM4A1[i][Points]);
  527.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponM4A1[i][GunName], g_SelectedGun[M4A1][id] == i ? "\y|Aktív|": szMenu2);
  528.             menu_additem(menu, szMenu, String);
  529.         }
  530.     }
  531.     else if(g_Wpn[id] == 2) {
  532.         for(new i; i < sizeof(WeaponAK47); i++) {
  533.             num_to_str(i, String, 5)
  534.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponAK47[i][Points]);
  535.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponAK47[i][GunName], g_SelectedGun[AK47][id] == i ? "\y|Aktív|": szMenu2);
  536.             menu_additem(menu, szMenu, String);
  537.         }
  538.     }
  539.     else if(g_Wpn[id] == 3) {
  540.         for(new i; i < sizeof(WeaponAWP); i++) {
  541.             num_to_str(i, String, 5)
  542.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponAWP[i][Points]);
  543.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponAWP[i][GunName], g_SelectedGun[AWP][id] == i ? "\y|Aktív|": szMenu2);
  544.             menu_additem(menu, szMenu, String);
  545.         }
  546.     }
  547.     else if(g_Wpn[id] == 4) {
  548.         for(new i; i < sizeof(WeaponSCOUT); i++) {
  549.             num_to_str(i, String, 5)
  550.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponSCOUT[i][Points]);
  551.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponSCOUT[i][GunName], g_SelectedGun[SCOUT][id] == i ? "\y|Aktív|": szMenu2);
  552.             menu_additem(menu, szMenu, String);
  553.         }
  554.     }
  555.     else if(g_Wpn[id] == 5) {
  556.         for(new i; i < sizeof(WeaponFAMAS); i++) {
  557.             num_to_str(i, String, 5)
  558.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponFAMAS[i][Points]);
  559.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponFAMAS[i][GunName], g_SelectedGun[FAMAS][id] == i ? "\y|Aktív|": szMenu2);
  560.             menu_additem(menu, szMenu, String);
  561.         }
  562.     }
  563.     else if(g_Wpn[id] == 6) {
  564.         for(new i; i < sizeof(WeaponGALIL); i++) {
  565.             num_to_str(i, String, 5)
  566.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponGALIL[i][Points]);
  567.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponGALIL[i][GunName], g_SelectedGun[GALIL][id] == i ? "\y|Aktív|": szMenu2);
  568.             menu_additem(menu, szMenu, String);
  569.         }
  570.     }
  571.     else if(g_Wpn[id] == 7) {
  572.         for(new i; i < sizeof(WeaponAUG); i++) {
  573.             num_to_str(i, String, 5)
  574.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponAUG[i][Points]);
  575.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponAUG[i][GunName], g_SelectedGun[AUG][id] == i ? "\y|Aktív|": szMenu2);
  576.             menu_additem(menu, szMenu, String);
  577.            
  578.         }  
  579.     }
  580.     else if(g_Wpn[id] == 8) {
  581.         for(new i; i < sizeof(WeaponM3); i++) {
  582.             num_to_str(i, String, 5)
  583.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponM3[i][Points]);
  584.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponM3[i][GunName], g_SelectedGun[M3][id] == i ? "\y|Aktív|": szMenu2);
  585.             menu_additem(menu, szMenu, String);
  586.            
  587.         }  
  588.     }
  589.     else if(g_Wpn[id] == 9) {
  590.         for(new i; i < sizeof(WeaponXM1014); i++) {
  591.             num_to_str(i, String, 5)
  592.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponXM1014[i][Points]);
  593.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponXM1014[i][GunName], g_SelectedGun[XM1014][id] == i ? "\y|Aktív|": szMenu2);
  594.             menu_additem(menu, szMenu, String);
  595.            
  596.         }  
  597.     }
  598.     else if(g_Wpn[id] == 10) {
  599.         for(new i; i < sizeof(WeaponKNIFE); i++) {
  600.             num_to_str(i, String, 5)
  601.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponKNIFE[i][Points]);
  602.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponKNIFE[i][GunName], g_SelectedGun[KNIFE][id] == i ? "\y|Aktív|": szMenu2);
  603.             menu_additem(menu, szMenu, String);
  604.            
  605.         }  
  606.     }
  607.     else if(g_Wpn[id] == 11) {
  608.         for(new i; i < sizeof(WeaponDEAGLE); i++) {
  609.             num_to_str(i, String, 5)
  610.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponDEAGLE[i][Points]);
  611.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponDEAGLE[i][GunName], g_SelectedGun[DEAGLE][id] == i ? "\y|Aktív|": szMenu2);
  612.             menu_additem(menu, szMenu, String);
  613.            
  614.         }  
  615.     }
  616.     else if(g_Wpn[id] == 12) {
  617.         for(new i; i < sizeof(WeaponUSP); i++) {
  618.             num_to_str(i, String, 5)
  619.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponUSP[i][Points]);
  620.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponUSP[i][GunName], g_SelectedGun[USP][id] == i ? "\y|Aktív|": szMenu2);
  621.             menu_additem(menu, szMenu, String);
  622.            
  623.         }  
  624.     }
  625.     else if(g_Wpn[id] == 13) {
  626.         for(new i; i < sizeof(WeaponGLOCK); i++) {
  627.             num_to_str(i, String, 5)
  628.             formatex(szMenu2, charsmax(szMenu2), "\r|%i| Ölés", WeaponGLOCK[i][Points]);
  629.             formatex(szMenu, charsmax(szMenu), "%s %s", WeaponGLOCK[i][GunName], g_SelectedGun[GLOCK][id] == i ? "\y|Aktív|": szMenu2);
  630.             menu_additem(menu, szMenu, String);            
  631.         }
  632.     }
  633.     menu_display(id, menu, 0);
  634.     return PLUGIN_HANDLED;
  635. }
  636. public hSkinChooser(id, menu, item) {
  637.     if(item == MENU_EXIT)
  638.     {
  639.         menu_destroy(menu);
  640.         return PLUGIN_CONTINUE;
  641.     }
  642.     switch(g_Wpn[id]) {
  643.         case 1: {
  644.             if(g_uPoints[M4A1][id] >= WeaponM4A1[item][Points]) {
  645.                 g_SelectedGun[M4A1][id] = item
  646.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  647.             }
  648.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  649.         }
  650.         case 2: {
  651.             if(g_uPoints[AK47][id] >= WeaponAK47[item][Points]) {
  652.                 g_SelectedGun[AK47][id] = item
  653.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  654.             }
  655.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  656.         }
  657.         case 3: {
  658.             if(g_uPoints[AWP][id] >= WeaponAWP[item][Points]) {
  659.                 g_SelectedGun[AWP][id] = item
  660.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  661.             }
  662.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  663.         }
  664.         case 4: {
  665.             if(g_uPoints[SCOUT][id] >= WeaponSCOUT[item][Points]) {
  666.                 g_SelectedGun[SCOUT][id] = item
  667.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  668.             }
  669.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  670.         }
  671.         case 5: {
  672.             if(g_uPoints[FAMAS][id] >= WeaponFAMAS[item][Points]) {
  673.                 g_SelectedGun[FAMAS][id] = item
  674.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  675.             }
  676.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  677.         }
  678.         case 6: {
  679.             if(g_uPoints[GALIL][id] >= WeaponAUG[item][Points]) {
  680.                 g_SelectedGun[GALIL][id] = item
  681.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  682.             }
  683.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  684.         }
  685.         case 7: {
  686.             if(g_uPoints[AUG][id] >= WeaponAUG[item][Points]) {
  687.                 g_SelectedGun[AUG][id] = item
  688.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  689.             }
  690.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  691.         }
  692.         case 8: {
  693.             if(g_uPoints[M3][id] >= WeaponM3[item][Points]) {
  694.                 g_SelectedGun[M3][id] = item
  695.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  696.             }
  697.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  698.         }  
  699.         case 9: {
  700.             if(g_uPoints[XM1014][id] >= WeaponXM1014[item][Points]) {
  701.                 g_SelectedGun[XM1014][id] = item
  702.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  703.             }
  704.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  705.         }  
  706.         case 10: {
  707.             if(g_uPoints[KNIFE][id] >= WeaponKNIFE[item][Points]) {
  708.                 g_SelectedGun[KNIFE][id] = item
  709.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  710.             }
  711.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  712.         }  
  713.         case 11: {
  714.             if(g_uPoints[DEAGLE][id] >= WeaponDEAGLE[item][Points]) {
  715.                 g_SelectedGun[DEAGLE][id] = item
  716.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  717.             }
  718.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  719.         }  
  720.         case 12: {
  721.             if(g_uPoints[USP][id] >= WeaponUSP[item][Points]) {
  722.                 g_SelectedGun[USP][id] = item
  723.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  724.             }
  725.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)        
  726.         }  
  727.         case 13: {
  728.             if(g_uPoints[GLOCK][id] >= WeaponGLOCK[item][Points]) {
  729.                 g_SelectedGun[GLOCK][id] = item
  730.                 ColorChat(id, GREEN, "^4%s ^1Sikeresen aktiváltad a skint!", C_Perfix)
  731.             }
  732.             else ColorChat(id, GREEN, "^4%s ^1Nincs elég ölésed az aktiváláshoz!", C_Perfix)
  733.            
  734.         }
  735.     }
  736.     menu_destroy(menu);
  737.     return PLUGIN_HANDLED;
  738. }
  739. stock UTIL_PlayWeaponAnimation(const Player, const Sequence) {
  740.     set_pev(Player, pev_weaponanim, Sequence)
  741.     message_begin(MSG_ONE_UNRELIABLE, SVC_WEAPONANIM, .player = Player)
  742.     write_byte(Sequence)
  743.     write_byte(pev(Player, pev_body))
  744.     message_end()
  745. }
  746. public plugin_cfg()
  747. {
  748.     g_SqlTuple = SQL_MakeDbTuple(SQL_Kiszolgaltato, SQL_FelhasznaloNev, SQL_Jelszo, SQL_Adatbazis_Neve)
  749.     static Query[10048]
  750.     new Len
  751.     Len += formatex(Query[Len], charsmax(Query), "CREATE TABLE IF NOT EXISTS `SkinMenu`")
  752.     Len += formatex(Query[Len], charsmax(Query)-Len, "(`Steamid` varchar(32) NOT NULL, ")
  753.     Len += formatex(Query[Len], charsmax(Query)-Len, "`olesek` int(11) NOT NULL,")
  754.     Len += formatex(Query[Len], charsmax(Query)-Len, "`szint` int(11) NOT NULL,")
  755.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsM4A1` int(11) NOT NULL,")
  756.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsAK47` int(11) NOT NULL,")
  757.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsAWP` int(11) NOT NULL,")
  758.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsSCOUT` int(11) NOT NULL,")
  759.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsFAMAS` int(11) NOT NULL,")
  760.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsGALIL` int(11) NOT NULL,")
  761.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsAUG` int(11) NOT NULL,")
  762.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsM3` int(11) NOT NULL,")
  763.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsXM1014` int(11) NOT NULL,")
  764.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsKNIFE` int(11) NOT NULL,")
  765.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsDEAGLE` int(11) NOT NULL,")
  766.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsUSP` int(11) NOT NULL,")
  767.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_uPointsGLOCK` int(11) NOT NULL,")
  768.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunM4A1` int(11) NOT NULL,")
  769.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunAK47` int(11) NOT NULL,")
  770.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunAWP` int(11) NOT NULL,")
  771.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunSCOUT` int(11) NOT NULL,")
  772.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunFAMAS` int(11) NOT NULL,")
  773.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunGALIL` int(11) NOT NULL,")
  774.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunAUG` int(11) NOT NULL,")
  775.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunM3` int(11) NOT NULL,")
  776.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunXM1014` int(11) NOT NULL,")
  777.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunKNIFE` int(11) NOT NULL,")
  778.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunDEAGLE` int(11) NOT NULL,")
  779.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunUSP` int(11) NOT NULL,")
  780.     Len += formatex(Query[Len], charsmax(Query)-Len, "`g_SelectedGunGLOCK` int(11) NOT NULL,")
  781.     Len += formatex(Query[Len], charsmax(Query)-Len, "`id` INT(11) NOT NULL AUTO_INCREMENT PRIMARY KEY)")
  782.     SQL_ThreadQuery(g_SqlTuple, "createTableThread", Query)
  783. }
  784. public Load(id)
  785. {
  786.     static Query[10048]
  787.     new Data[1], Steam[32]
  788.     get_user_authid(id, Steam, 31)
  789.     Data[0] = id
  790.     formatex(Query, charsmax(Query), "SELECT * FROM `SkinMenu` WHERE Steamid = ^"%s^";", Steam)
  791.     SQL_ThreadQuery(g_SqlTuple, "QuerySelectData", Query, Data, 1)
  792. }
  793. public QuerySelectData(FailState, Handle:Query, Error[], Errcode, Data[], DataSize, Float:Queuetime)
  794. {
  795.     if(FailState == TQUERY_CONNECT_FAILED || FailState == TQUERY_QUERY_FAILED) {
  796.         log_amx("%s", Error)
  797.         return
  798.     }
  799.     else {
  800.         new id = Data[0];
  801.         if(SQL_NumRows(Query) > 0)
  802.         {
  803.             szint[id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "szint"))
  804.             olesek[id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "olesek"))
  805.             g_uPoints[M4A1][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsM4A1"))
  806.             g_uPoints[AK47][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsAK47"))
  807.             g_uPoints[AWP][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsAWP"))
  808.             g_uPoints[SCOUT][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsSCOUT"))
  809.             g_uPoints[FAMAS][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsFAMAS"))
  810.             g_uPoints[GALIL][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsGALIL"))
  811.             g_uPoints[AUG][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsAUG"))
  812.             g_uPoints[M3][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsM3"))
  813.             g_uPoints[XM1014][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsXM1014"))
  814.             g_uPoints[KNIFE][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsKNIFE"))
  815.             g_uPoints[DEAGLE][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsUSP"))
  816.             g_uPoints[USP][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsGLOCK"))
  817.             g_uPoints[GLOCK][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_uPointsDEAGLE"))
  818.             g_SelectedGun[M4A1][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunM4A1"))
  819.             g_SelectedGun[AK47][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunAK47"))
  820.             g_SelectedGun[AWP][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunAWP"))
  821.             g_SelectedGun[SCOUT][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunSCOUT"))
  822.             g_SelectedGun[FAMAS][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunFAMAS"))
  823.             g_SelectedGun[GALIL][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunGALIL"))
  824.             g_SelectedGun[AUG][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunAUG"))
  825.             g_SelectedGun[M3][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunM3"))
  826.             g_SelectedGun[XM1014][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunXM1014"))
  827.             g_SelectedGun[KNIFE][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunKNIFE"))
  828.             g_SelectedGun[DEAGLE][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunDEAGLE"))
  829.             g_SelectedGun[USP][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunUSP"))
  830.             g_SelectedGun[GLOCK][id] = SQL_ReadResult(Query, SQL_FieldNameToNum(Query, "g_SelectedGunGLOCK"))
  831.         }
  832.         else
  833.         {
  834.             Save(id)
  835.         }
  836.     }
  837. }
  838. public Save(id)
  839. {
  840.     static Query[256]
  841.     new Steam[32]; get_user_authid(id, Steam, 31)
  842.     formatex(Query, charsmax(Query), "INSERT INTO `SkinMenu` (`Steamid`) VALUES (^"%s^");", Steam)
  843.     SQL_ThreadQuery(g_SqlTuple, "QuerySetData", Query)
  844. }
  845. public Update(id)
  846. {
  847.     static Query[10048]
  848.     new Len
  849.     new Steam[32]; get_user_authid(id, Steam, 31)
  850.     Len += formatex(Query[Len], charsmax(Query), "UPDATE `SkinMenu` SET g_uPointsAWP = ^"%i^", ", g_uPoints[AWP][id])
  851.     Len += formatex(Query[Len], charsmax(Query)-Len, "szint = ^"%i^", ", szint[id])
  852.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsM4A1 = ^"%i^", ", g_uPoints[M4A1][id])
  853.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsAK47 = ^"%i^", ", g_uPoints[AK47][id])
  854.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsSCOUT = ^"%i^", ", g_uPoints[SCOUT][id])
  855.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsFAMAS = ^"%i^", ", g_uPoints[FAMAS][id])
  856.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsGALIL = ^"%i^", ", g_uPoints[GALIL][id])
  857.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsAUG= ^"%i^", ", g_uPoints[AUG][id])
  858.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsM3 = ^"%i^", ", g_uPoints[M3][id])
  859.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsXM1014 = ^"%i^", ", g_uPoints[XM1014][id])
  860.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsKNIFE = ^"%i^", ", g_uPoints[KNIFE][id])
  861.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsDEAGLE = ^"%i^", ", g_uPoints[DEAGLE][id])
  862.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsUSP = ^"%i^", ", g_uPoints[USP][id])
  863.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_uPointsGLOCK = ^"%i^", ", g_uPoints[GLOCK][id])
  864.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunM4A1 = ^"%i^", ", g_SelectedGun[M4A1][id])
  865.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunAK47 = ^"%i^", ", g_SelectedGun[AK47][id])
  866.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunAWP = ^"%i^", ", g_SelectedGun[AWP][id])
  867.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunSCOUT = ^"%i^", ", g_SelectedGun[SCOUT][id])
  868.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunFAMAS = ^"%i^", ", g_SelectedGun[FAMAS][id])
  869.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunGALIL = ^"%i^", ", g_SelectedGun[GALIL][id])
  870.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunAUG = ^"%i^", ", g_SelectedGun[AUG][id])
  871.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunM3 = ^"%i^", ", g_SelectedGun[M3][id])
  872.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunXM1014 = ^"%i^", ", g_SelectedGun[XM1014][id])
  873.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunKNIFE = ^"%i^", ", g_SelectedGun[KNIFE][id])
  874.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunDEAGLE = ^"%i^", ", g_SelectedGun[DEAGLE][id])
  875.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunUSP = ^"%i^", ", g_SelectedGun[USP][id])
  876.     Len += formatex(Query[Len], charsmax(Query)-Len, "g_SelectedGunGLOCK = ^"%i^", ", g_SelectedGun[GLOCK][id])
  877.     Len += formatex(Query[Len], charsmax(Query)-Len, "olesek = ^"%i^" WHERE Steamid = ^"%s^";", olesek[id], Steam)
  878.     SQL_ThreadQuery(g_SqlTuple, "QuerySetData", Query)
  879. }
  880. public createTableThread(FailState, Handle:Query, Error[], Errcode, Data[], DataSize, Float:Queuetime) {
  881.     if(FailState == TQUERY_CONNECT_FAILED)
  882.         set_fail_state("[HIBA*] NEM TUDTAM CSATLAKOZNI AZ ADATBAZISHOZ!")
  883.     else if(FailState == TQUERY_QUERY_FAILED)
  884.         set_fail_state("Query Error")
  885.     if(Errcode)
  886.         log_amx("[HIBA*] HIBAT DOBTAM: %s",Error)
  887. }
  888. public QuerySetData(FailState, Handle:Query, Error[], Errcode, Data[], DataSize, Float:Queuetime) {
  889.     if(FailState == TQUERY_CONNECT_FAILED || FailState == TQUERY_QUERY_FAILED) {
  890.         log_amx("%s", Error);
  891.         return;
  892.     }
  893. }
  894. public client_putinserver(id)
  895. {
  896.    
  897.     if(!is_user_bot(id))
  898.     {
  899.         Load(id);
  900.     }
  901.     hudkibe[id] = true;
  902.     set_task(1.0, "hudrendszer", id, _, _, "b");
  903.     olesek[id] = 0
  904.     szint[id] = 0
  905.     g_uPoints[M4A1][id] = 0
  906.     g_uPoints[AK47][id] = 0
  907.     g_uPoints[AWP][id] = 0
  908.     g_uPoints[SCOUT][id] = 0
  909.     g_uPoints[FAMAS][id] = 0
  910.     g_uPoints[GALIL][id] = 0
  911.     g_uPoints[AUG][id] = 0
  912.     g_uPoints[M3][id] = 0
  913.     g_uPoints[XM1014][id] = 0
  914.     g_uPoints[KNIFE][id] = 0
  915.     g_uPoints[DEAGLE][id] = 0
  916.     g_uPoints[USP][id] = 0
  917.     g_uPoints[GLOCK][id] = 0
  918.     g_SelectedGun[M4A1][id] = 0
  919.     g_SelectedGun[AK47][id] = 0
  920.     g_SelectedGun[AWP][id] = 0
  921.     g_SelectedGun[SCOUT][id] = 0
  922.     g_SelectedGun[FAMAS][id] = 0
  923.     g_SelectedGun[GALIL][id] = 0
  924.     g_SelectedGun[AUG][id] = 0
  925.     g_SelectedGun[M3][id] = 0
  926.     g_SelectedGun[XM1014][id] = 0
  927.     g_SelectedGun[KNIFE][id] = 0
  928.     g_SelectedGun[DEAGLE][id] = 0
  929.     g_SelectedGun[USP][id] = 0
  930.     g_SelectedGun[GLOCK][id] = 0
  931.     if(!is_user_bot(id))
  932.     Load(id);
  933.     return PLUGIN_CONTINUE
  934. }
  935. public client_disconnect(id)
  936. {
  937.     if(!is_user_bot(id))
  938.     {
  939.         Update(id);
  940.     }
  941.     return PLUGIN_CONTINUE
  942. }
  943. public hudrendszer(id)
  944. {
  945.     if(!hudkibe[id])
  946.         return;
  947.     if(is_user_alive(id))
  948.     {
  949.         set_hudmessage(0, 85, 255, 0.01, 0.18, 0, 6.0, 12.0)
  950.         show_hudmessage(id, "Öléseid: %d^nRangod: %s^nParancsok: /rang, /hud", olesek[id], rangok[szint[id]]);
  951.     }
  952. }  
  953. public hudkibekapcs(id)
  954. {
  955.     if(hudkibe[id])
  956.     {
  957.         ColorChat(id, GREEN, "^4[%s] ^1Kikapcsoltad a hudot.", PREFIX);
  958.         hudkibe[id] = false;
  959.     }
  960.     else
  961.     {
  962.         ColorChat(id, GREEN, "^4[%s] ^1Bekapcsoltad a hudot.", PREFIX);
  963.         hudkibe[id] = true;
  964.     }
  965. }
  966. public showrang(id)
  967. {
  968.     if(szint[id] != ASD+1)
  969.     {
  970.         ColorChat(id, GREEN, "^4[%s] ^3Rang: ^4%s ^1| ^3Öléseid: ^4%d ^1| ^3Kell még: ^4%d", PREFIX, rangok[szint[id]], olesek[id], szamok[szint[id]]-olesek[id]);
  971.     }
  972.     else
  973.     {
  974.         ColorChat(id, GREEN, "^4[%s] ^3Rang: ^4%s ^1| ^3Öléseid: ^4%d", PREFIX, rangok[szint[id]], olesek[id]);
  975.         ColorChat(id, GREEN, "^4[%s] ^1Elérted a legmagasabb ^3Rangot.", PREFIX);
  976.     }
  977.     return PLUGIN_HANDLED;
  978. }
  979. public sayhook(id)
  980. {
  981.     new message[192], nev[32], none[2][32], chat[192];
  982.     read_args(message, 191);
  983.     remove_quotes(message);
  984.    
  985.     formatex(none[0], 31, ""), formatex(none[1], 31, " ");
  986.    
  987.     if (message[0] == '@' || message[0] == '/' || message[0] == '#' || message[0] == '!' || equal (message, ""))
  988.         return PLUGIN_HANDLED_MAIN;
  989.    
  990.     if(!equali(message, none[0]) && !equali(message, none[1]))
  991.     {
  992.         get_user_name(id, nev, 31);
  993.         if(is_user_alive(id))
  994.         {
  995.             if(get_user_flags(id) & TULAJ)
  996.                 formatex(chat, 191, "^x04[Tulajdonos][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  997.             else if(get_user_flags(id) & FOADMIN)
  998.                 formatex(chat, 191, "^x04[FőAdmin][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  999.             else if(get_user_flags(id) & ADMIN)
  1000.                 formatex(chat, 191, "^x04[Admin][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1001.             else if(get_user_flags(id) & VIP)
  1002.                 formatex(chat, 191, "^x04[VIP][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1003.             else
  1004.                 formatex(chat, 191, "^x04[%s]^3%s^x01: %s", rangok[szint[id]], nev, message);
  1005.         }
  1006.         else {
  1007.            
  1008.             if(get_user_flags(id) & TULAJ)
  1009.                 formatex(chat, 191, "^x01*Halott*^x04[Tulajdonos][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1010.             else if(get_user_flags(id) & FOADMIN)
  1011.                 formatex(chat, 191, "^x01*Halott*^x04[FőAdmin][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1012.             else if(get_user_flags(id) & ADMIN)
  1013.                 formatex(chat, 191, "^x01*Halott*^x04[Admin][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1014.             else if(get_user_flags(id) & VIP)
  1015.                 formatex(chat, 191, "^x01*Halott*^x04[VIP][%s]^3%s^x04: %s", rangok[szint[id]], nev, message);
  1016.             else
  1017.                 formatex(chat, 191, "^x01*Halott*^x04[%s]^3%s^x01: %s", rangok[szint[id]], nev, message);
  1018.         }
  1019.         if ( !is_user_connected(id) )
  1020.             return PLUGIN_CONTINUE;
  1021.        
  1022.         switch(cs_get_user_team(id)) //Prefix
  1023.         {
  1024.             case 1: ColorChat(0, RED, chat);
  1025.                 case 2: ColorChat(0, BLUE, chat);
  1026.             }
  1027.         if(cs_get_user_team(id) == CS_TEAM_SPECTATOR)
  1028.             ColorChat(0, GREY, chat);
  1029.         return PLUGIN_HANDLED_MAIN;
  1030.     }
  1031.     return PLUGIN_CONTINUE;
  1032. }
  1033. public sendmessage(color[])
  1034. {
  1035.     new teamName[32];
  1036.     for(new player = 1; player < get_maxplayers(); player++)
  1037.     {
  1038.         get_user_team (player, teamName, 9);
  1039.         teamf (player, color);
  1040.         elkuldes(player, Temp);
  1041.         teamf(player, teamName);
  1042.     }
  1043. }
  1044. public teamf(player, team[])
  1045. {
  1046.     message_begin(MSG_ONE, get_user_msgid("TeamInfo"), _, player);
  1047.     write_byte(player);
  1048.     write_string(team);
  1049.     message_end();
  1050. }
  1051. public elkuldes(player, Temp[])
  1052. {
  1053.     message_begin( MSG_ONE, get_user_msgid( "SayText" ), _, player);
  1054.     write_byte( player );
  1055.     write_string( Temp );
  1056.     message_end();
  1057. }
  1058. public plugin_end()
  1059. {
  1060.     SQL_FreeHandle(g_SqlTuple);
  1061. }



  1. L 02/17/2020 - 11:20:52: Start of error session.
  2. L 02/17/2020 - 11:20:52: Info (map "cs_sauna") (file "addons/amxmodx/logs/error_20200217.log")
  3. L 02/17/2020 - 11:20:52: [AMXX] Plugin ("darkdemonsmod.amxx") is setting itself as failed.
  4. L 02/17/2020 - 11:20:52: [AMXX] Plugin says: [HIBA*] NEM TUDTAM CSATLAKOZNI AZ ADATBAZISHOZ!
  5. L 02/17/2020 - 11:20:52: [AMXX] Displaying debug trace (plugin "darkdemonsmod.amxx", version "1.0")
  6. L 02/17/2020 - 11:20:52: [AMXX] Run time error 1: forced exit
  7. L 02/17/2020 - 11:20:52: [AMXX]    [0] 262dd4ba5d950596982b4013deced471.sma::createTableThread (line 906)
  8. L 02/17/2020 - 11:40:56: Start of error session.


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve: 2020.02.18. 17:04 
Offline
Őskövület
Avatar

Csatlakozott: 2012.03.22. 18:22
Hozzászólások: 2866
Megköszönt másnak: 104 alkalommal
Megköszönték neki: 346 alkalommal
Ez adatbázis hiba. Semmi köze sajnos az összeíráshoz. Rosszul adtál meg valamit

_________________
Blasenkampfwagen


Hozzászólás jelentése
Vissza a tetejére
   
Hozzászólások megjelenítése:  Rendezés  
Új téma nyitása  Hozzászólás a témához  [ 31 hozzászólás ]  Oldal 1 2 3 4 Következő


Ki van itt

Jelenlévő fórumozók: nincs regisztrált felhasználó valamint 2 vendég


Nyithatsz új témákat ebben a fórumban.
Válaszolhatsz egy témára ebben a fórumban.
Nem szerkesztheted a hozzászólásaidat ebben a fórumban.
Nem törölheted a hozzászólásaidat ebben a fórumban.
Nem küldhetsz csatolmányokat ebben a fórumban.

Keresés:
Ugrás:  
Powered by phpBB® Forum Software © phpBB Limited
Magyar fordítás © Magyar phpBB Közösség és a hlmod.hu csapata
Portal: Kiss Portal Extension © Michael O'Toole