@amxts/core 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (247) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +162 -0
  3. package/README.ru.md +162 -0
  4. package/amxmodx/base/include/amxconst.inc +594 -0
  5. package/amxmodx/base/include/amxmisc.inc +902 -0
  6. package/amxmodx/base/include/amxmodx.inc +3447 -0
  7. package/amxmodx/base/include/amxmodx_version.inc +20 -0
  8. package/amxmodx/base/include/cellarray.inc +525 -0
  9. package/amxmodx/base/include/cellstack.inc +166 -0
  10. package/amxmodx/base/include/celltrie.inc +412 -0
  11. package/amxmodx/base/include/core.inc +202 -0
  12. package/amxmodx/base/include/csstats.inc +298 -0
  13. package/amxmodx/base/include/csstats_const.inc +29 -0
  14. package/amxmodx/base/include/cstrike.inc +1287 -0
  15. package/amxmodx/base/include/cstrike_const.inc +521 -0
  16. package/amxmodx/base/include/csx.inc +259 -0
  17. package/amxmodx/base/include/cvars.inc +547 -0
  18. package/amxmodx/base/include/datapack.inc +161 -0
  19. package/amxmodx/base/include/dbi.inc +154 -0
  20. package/amxmodx/base/include/dodconst.inc +152 -0
  21. package/amxmodx/base/include/dodfun.inc +152 -0
  22. package/amxmodx/base/include/dodstats.inc +69 -0
  23. package/amxmodx/base/include/dodx.inc +161 -0
  24. package/amxmodx/base/include/engine.inc +1343 -0
  25. package/amxmodx/base/include/engine_const.inc +310 -0
  26. package/amxmodx/base/include/engine_stocks.inc +248 -0
  27. package/amxmodx/base/include/esf.inc +70 -0
  28. package/amxmodx/base/include/esf_const.inc +74 -0
  29. package/amxmodx/base/include/fakemeta.inc +1127 -0
  30. package/amxmodx/base/include/fakemeta_const.inc +793 -0
  31. package/amxmodx/base/include/fakemeta_stocks.inc +395 -0
  32. package/amxmodx/base/include/fakemeta_util.inc +882 -0
  33. package/amxmodx/base/include/file.inc +666 -0
  34. package/amxmodx/base/include/float.inc +422 -0
  35. package/amxmodx/base/include/fun.inc +333 -0
  36. package/amxmodx/base/include/gameconfig.inc +93 -0
  37. package/amxmodx/base/include/geoip.inc +264 -0
  38. package/amxmodx/base/include/ham_const.inc +4352 -0
  39. package/amxmodx/base/include/hamsandwich.inc +439 -0
  40. package/amxmodx/base/include/hlsdk_const.inc +808 -0
  41. package/amxmodx/base/include/json.inc +777 -0
  42. package/amxmodx/base/include/lang.inc +119 -0
  43. package/amxmodx/base/include/message_const.inc +1130 -0
  44. package/amxmodx/base/include/message_stocks.inc +161 -0
  45. package/amxmodx/base/include/messages.inc +604 -0
  46. package/amxmodx/base/include/newmenus.inc +387 -0
  47. package/amxmodx/base/include/ns.inc +754 -0
  48. package/amxmodx/base/include/ns_const.inc +196 -0
  49. package/amxmodx/base/include/nvault.inc +154 -0
  50. package/amxmodx/base/include/regex.inc +348 -0
  51. package/amxmodx/base/include/sockets.inc +183 -0
  52. package/amxmodx/base/include/sorting.inc +107 -0
  53. package/amxmodx/base/include/sqlx.inc +582 -0
  54. package/amxmodx/base/include/string.inc +786 -0
  55. package/amxmodx/base/include/string_const.inc +156 -0
  56. package/amxmodx/base/include/string_stocks.inc +325 -0
  57. package/amxmodx/base/include/textparse_ini.inc +214 -0
  58. package/amxmodx/base/include/textparse_smc.inc +261 -0
  59. package/amxmodx/base/include/tfcconst.inc +84 -0
  60. package/amxmodx/base/include/tfcstats.inc +62 -0
  61. package/amxmodx/base/include/tfcx.inc +148 -0
  62. package/amxmodx/base/include/time.inc +118 -0
  63. package/amxmodx/base/include/tsconst.inc +154 -0
  64. package/amxmodx/base/include/tsfun.inc +198 -0
  65. package/amxmodx/base/include/tsstats.inc +65 -0
  66. package/amxmodx/base/include/tsx.inc +88 -0
  67. package/amxmodx/base/include/vault.inc +60 -0
  68. package/amxmodx/base/include/vector.inc +131 -0
  69. package/amxmodx/base/include/xs.inc +1570 -0
  70. package/as/amxts.d.ts +153 -0
  71. package/as/constants.ts +4730 -0
  72. package/as/effects.ts +1449 -0
  73. package/as/entities.ts +5482 -0
  74. package/as/events.ts +3054 -0
  75. package/as/facade.ts +4639 -0
  76. package/as/flags.ts +299 -0
  77. package/as/fs.ts +287 -0
  78. package/as/hooks.ts +18536 -0
  79. package/as/kit.ts +25 -0
  80. package/as/lib/check.ts +86 -0
  81. package/as/modules/http.ts +184 -0
  82. package/as/natives.ts +11845 -0
  83. package/as/os.ts +30 -0
  84. package/as/promise.ts +1392 -0
  85. package/as/promise.types.d.ts +82 -0
  86. package/as/remote.ts +288 -0
  87. package/as/tsconfig.json +22 -0
  88. package/as/vector.ts +65 -0
  89. package/bin/amxts.mjs +10 -0
  90. package/includes/menu_core.inc +355 -0
  91. package/includes/order.txt +54 -0
  92. package/includes/sources.json +27 -0
  93. package/includes/universal_config.inc +355 -0
  94. package/lint/oxlint-plugin.mjs +77 -0
  95. package/node_modules/assemblyscript/LICENSE +201 -0
  96. package/node_modules/assemblyscript/NOTICE +93 -0
  97. package/node_modules/assemblyscript/package.json +63 -0
  98. package/node_modules/assemblyscript/std/README.md +6 -0
  99. package/node_modules/assemblyscript/std/assembly/array.ts +526 -0
  100. package/node_modules/assemblyscript/std/assembly/arraybuffer.ts +77 -0
  101. package/node_modules/assemblyscript/std/assembly/atomics.ts +127 -0
  102. package/node_modules/assemblyscript/std/assembly/bindings/asyncify.ts +16 -0
  103. package/node_modules/assemblyscript/std/assembly/bindings/dom.ts +291 -0
  104. package/node_modules/assemblyscript/std/assembly/bindings/node.ts +6 -0
  105. package/node_modules/assemblyscript/std/assembly/builtins.ts +2631 -0
  106. package/node_modules/assemblyscript/std/assembly/compat.ts +2 -0
  107. package/node_modules/assemblyscript/std/assembly/console.ts +42 -0
  108. package/node_modules/assemblyscript/std/assembly/crypto.ts +9 -0
  109. package/node_modules/assemblyscript/std/assembly/dataview.ts +181 -0
  110. package/node_modules/assemblyscript/std/assembly/date.ts +373 -0
  111. package/node_modules/assemblyscript/std/assembly/diagnostics.ts +11 -0
  112. package/node_modules/assemblyscript/std/assembly/error.ts +44 -0
  113. package/node_modules/assemblyscript/std/assembly/function.ts +38 -0
  114. package/node_modules/assemblyscript/std/assembly/index.d.ts +2822 -0
  115. package/node_modules/assemblyscript/std/assembly/iterator.ts +35 -0
  116. package/node_modules/assemblyscript/std/assembly/map.ts +260 -0
  117. package/node_modules/assemblyscript/std/assembly/math.ts +3289 -0
  118. package/node_modules/assemblyscript/std/assembly/memory.ts +123 -0
  119. package/node_modules/assemblyscript/std/assembly/number.ts +388 -0
  120. package/node_modules/assemblyscript/std/assembly/object.ts +36 -0
  121. package/node_modules/assemblyscript/std/assembly/performance.ts +9 -0
  122. package/node_modules/assemblyscript/std/assembly/polyfills.ts +27 -0
  123. package/node_modules/assemblyscript/std/assembly/process.ts +50 -0
  124. package/node_modules/assemblyscript/std/assembly/reference.ts +48 -0
  125. package/node_modules/assemblyscript/std/assembly/regexp.ts +12 -0
  126. package/node_modules/assemblyscript/std/assembly/rt/README.md +83 -0
  127. package/node_modules/assemblyscript/std/assembly/rt/common.ts +81 -0
  128. package/node_modules/assemblyscript/std/assembly/rt/index-incremental.ts +2 -0
  129. package/node_modules/assemblyscript/std/assembly/rt/index-minimal.ts +2 -0
  130. package/node_modules/assemblyscript/std/assembly/rt/index-stub.ts +1 -0
  131. package/node_modules/assemblyscript/std/assembly/rt/index.d.ts +37 -0
  132. package/node_modules/assemblyscript/std/assembly/rt/itcms.ts +419 -0
  133. package/node_modules/assemblyscript/std/assembly/rt/rtrace.ts +15 -0
  134. package/node_modules/assemblyscript/std/assembly/rt/stub.ts +133 -0
  135. package/node_modules/assemblyscript/std/assembly/rt/tcms.ts +254 -0
  136. package/node_modules/assemblyscript/std/assembly/rt/tlsf.ts +592 -0
  137. package/node_modules/assemblyscript/std/assembly/rt.ts +87 -0
  138. package/node_modules/assemblyscript/std/assembly/set.ts +220 -0
  139. package/node_modules/assemblyscript/std/assembly/shared/feature.ts +65 -0
  140. package/node_modules/assemblyscript/std/assembly/shared/runtime.ts +11 -0
  141. package/node_modules/assemblyscript/std/assembly/shared/target.ts +11 -0
  142. package/node_modules/assemblyscript/std/assembly/shared/tsconfig.json +11 -0
  143. package/node_modules/assemblyscript/std/assembly/shared/typeinfo.ts +72 -0
  144. package/node_modules/assemblyscript/std/assembly/staticarray.ts +401 -0
  145. package/node_modules/assemblyscript/std/assembly/string.ts +847 -0
  146. package/node_modules/assemblyscript/std/assembly/symbol.ts +114 -0
  147. package/node_modules/assemblyscript/std/assembly/table.ts +16 -0
  148. package/node_modules/assemblyscript/std/assembly/tsconfig.json +6 -0
  149. package/node_modules/assemblyscript/std/assembly/typedarray.ts +1945 -0
  150. package/node_modules/assemblyscript/std/assembly/uri.ts +17 -0
  151. package/node_modules/assemblyscript/std/assembly/util/bytes.ts +107 -0
  152. package/node_modules/assemblyscript/std/assembly/util/casemap.ts +497 -0
  153. package/node_modules/assemblyscript/std/assembly/util/error.ts +54 -0
  154. package/node_modules/assemblyscript/std/assembly/util/hash.ts +117 -0
  155. package/node_modules/assemblyscript/std/assembly/util/math.ts +1922 -0
  156. package/node_modules/assemblyscript/std/assembly/util/memory.ts +290 -0
  157. package/node_modules/assemblyscript/std/assembly/util/number.ts +873 -0
  158. package/node_modules/assemblyscript/std/assembly/util/sort.ts +313 -0
  159. package/node_modules/assemblyscript/std/assembly/util/string.ts +1202 -0
  160. package/node_modules/assemblyscript/std/assembly/util/uri.ts +275 -0
  161. package/node_modules/assemblyscript/std/assembly/vector.ts +4 -0
  162. package/node_modules/assemblyscript/std/assembly.json +16 -0
  163. package/node_modules/assemblyscript/std/portable/index.d.ts +462 -0
  164. package/node_modules/assemblyscript/std/portable/index.js +416 -0
  165. package/node_modules/assemblyscript/std/portable.json +11 -0
  166. package/node_modules/assemblyscript/std/types/assembly/index.d.ts +1 -0
  167. package/node_modules/assemblyscript/std/types/assembly/package.json +3 -0
  168. package/node_modules/assemblyscript/std/types/portable/index.d.ts +1 -0
  169. package/node_modules/assemblyscript/std/types/portable/package.json +3 -0
  170. package/node_modules/assemblyscript/tsconfig-base.json +13 -0
  171. package/package.json +112 -0
  172. package/runtime/deps/assemblyscript/LICENSE +201 -0
  173. package/runtime/deps/assemblyscript/NOTICE +93 -0
  174. package/runtime/deps/assemblyscript/bin/asc.js +35 -0
  175. package/runtime/deps/assemblyscript/dist/asc.js +25035 -0
  176. package/runtime/deps/assemblyscript/dist/assemblyscript.js +337 -0
  177. package/runtime/deps/assemblyscript/node_modules/binaryen/LICENSE +201 -0
  178. package/runtime/deps/assemblyscript/node_modules/binaryen/index.js +28905 -0
  179. package/runtime/deps/assemblyscript/node_modules/binaryen/package.json +50 -0
  180. package/runtime/deps/assemblyscript/node_modules/long/LICENSE +202 -0
  181. package/runtime/deps/assemblyscript/node_modules/long/index.js +1581 -0
  182. package/runtime/deps/assemblyscript/node_modules/long/package.json +58 -0
  183. package/runtime/deps/assemblyscript/package.json +114 -0
  184. package/runtime/host/amxts.inc +85 -0
  185. package/runtime/licenses/AMXX-LICENSE.txt +34 -0
  186. package/runtime/licenses/AssemblyScript-LICENSE +201 -0
  187. package/runtime/licenses/AssemblyScript-NOTICE +93 -0
  188. package/runtime/licenses/Binaryen-LICENSE +201 -0
  189. package/runtime/licenses/Bun-LICENSE.md +84 -0
  190. package/runtime/licenses/GPL-3.0.txt +674 -0
  191. package/runtime/licenses/LLVM-LICENSE.TXT +279 -0
  192. package/runtime/licenses/README.md +25 -0
  193. package/runtime/licenses/WAMR-LICENSE +219 -0
  194. package/runtime/natives.txt +1095 -0
  195. package/runtime/patches/README.md +59 -0
  196. package/runtime/patches/assemblyscript-0.28.20-amxts.patch +14174 -0
  197. package/runtime/patches/wamr-2.4.5-amxts.patch +364 -0
  198. package/scripts/apply-docs.ts +508 -0
  199. package/scripts/asc.ts +27 -0
  200. package/scripts/auto-imports.ts +258 -0
  201. package/scripts/build-wasm.ts +595 -0
  202. package/scripts/check.ts +93 -0
  203. package/scripts/compile-cache.ts +179 -0
  204. package/scripts/compile.ts +401 -0
  205. package/scripts/docker-server.ts +73 -0
  206. package/scripts/docs/as/amxts.ts +210 -0
  207. package/scripts/docs/as/effects.ts +1684 -0
  208. package/scripts/docs/as/facade.ts +3302 -0
  209. package/scripts/docs/as/fs.ts +173 -0
  210. package/scripts/docs/as/lib/check.ts +68 -0
  211. package/scripts/docs/as/modules/http.ts +66 -0
  212. package/scripts/docs/as/os.ts +16 -0
  213. package/scripts/docs/as/promise.ts +132 -0
  214. package/scripts/docs/as/promise.types.ts +63 -0
  215. package/scripts/docs/as/vector.ts +48 -0
  216. package/scripts/docs/entities.ts +2338 -0
  217. package/scripts/docs/events.ts +245 -0
  218. package/scripts/docs/game.ts +497 -0
  219. package/scripts/docs/messages.ts +148 -0
  220. package/scripts/file-contents.ts +74 -0
  221. package/scripts/includes.ts +134 -0
  222. package/scripts/player-fields.ts +866 -0
  223. package/scripts/plugin-cache.ts +92 -0
  224. package/scripts/plugin-natives.ts +1157 -0
  225. package/scripts/prebuilt.ts +268 -0
  226. package/scripts/prepare.ts +134 -0
  227. package/scripts/project.ts +973 -0
  228. package/scripts/run.ts +28 -0
  229. package/scripts/shared-modules.ts +906 -0
  230. package/scripts/system.ts +33 -0
  231. package/scripts/tracked-fs.ts +115 -0
  232. package/scripts/typed-configs.ts +788 -0
  233. package/scripts/ui.ts +77 -0
  234. package/src/cli-api.mjs +175 -0
  235. package/src/parser/include-parser.ts +506 -0
  236. package/src/system.mjs +155 -0
  237. package/src/testing/compile-cache.ts +31 -0
  238. package/src/testing/compile.ts +222 -0
  239. package/src/testing/coroutines.ts +191 -0
  240. package/src/testing/index.ts +39 -0
  241. package/src/testing/kits.ts +55 -0
  242. package/src/testing/memory.ts +125 -0
  243. package/src/testing/natives.ts +925 -0
  244. package/src/testing/server.ts +1874 -0
  245. package/src/testing/setup.ts +63 -0
  246. package/src/testing/tables.ts +139 -0
  247. package/src/types.ts +51 -0
@@ -0,0 +1,808 @@
1
+ // vim: set ts=4 sw=4 tw=99 noet:
2
+ //
3
+ // AMX Mod X, based on AMX Mod by Aleksander Naszko ("OLO").
4
+ // Copyright (C) The AMX Mod X Development Team.
5
+ //
6
+ // This software is licensed under the GNU General Public License, version 3 or higher.
7
+ // Additional exceptions apply. For full license details, see LICENSE.txt or visit:
8
+ // https://alliedmods.net/amxmodx-license
9
+
10
+ //
11
+ // Half-Life SDK Constants
12
+ //
13
+
14
+ #if defined _hlsdk_const_included
15
+ #endinput
16
+ #endif
17
+ #define _hlsdk_const_included
18
+
19
+ /**
20
+ * pev(entity, pev_button) or pev(entity, pev_oldbuttons) values
21
+ */
22
+ #define IN_ATTACK (1<<0)
23
+ #define IN_JUMP (1<<1)
24
+ #define IN_DUCK (1<<2)
25
+ #define IN_FORWARD (1<<3)
26
+ #define IN_BACK (1<<4)
27
+ #define IN_USE (1<<5)
28
+ #define IN_CANCEL (1<<6)
29
+ #define IN_LEFT (1<<7)
30
+ #define IN_RIGHT (1<<8)
31
+ #define IN_MOVELEFT (1<<9)
32
+ #define IN_MOVERIGHT (1<<10)
33
+ #define IN_ATTACK2 (1<<11)
34
+ #define IN_RUN (1<<12)
35
+ #define IN_RELOAD (1<<13)
36
+ #define IN_ALT1 (1<<14)
37
+ #define IN_SCORE (1<<15) // Used by client.dll for when scoreboard is held down
38
+
39
+ /**
40
+ * pev(entity, pev_flags) values
41
+ */
42
+ #define FL_FLY (1<<0) // Changes the SV_Movestep() behavior to not need to be on ground
43
+ #define FL_SWIM (1<<1) // Changes the SV_Movestep() behavior to not need to be on ground (but stay in water)
44
+ #define FL_CONVEYOR (1<<2)
45
+ #define FL_CLIENT (1<<3)
46
+ #define FL_INWATER (1<<4)
47
+ #define FL_MONSTER (1<<5)
48
+ #define FL_GODMODE (1<<6)
49
+ #define FL_NOTARGET (1<<7)
50
+ #define FL_SKIPLOCALHOST (1<<8) // Don't send entity to local host, it's predicting this entity itself
51
+ #define FL_ONGROUND (1<<9) // At rest / on the ground
52
+ #define FL_PARTIALGROUND (1<<10) // Not all corners are valid
53
+ #define FL_WATERJUMP (1<<11) // Player jumping out of water
54
+ #define FL_FROZEN (1<<12) // Player is frozen for 3rd person camera
55
+ #define FL_FAKECLIENT (1<<13) // JAC: fake client, simulated server side; don't send network messages to them
56
+ #define FL_DUCKING (1<<14) // Player flag -- Player is fully crouched
57
+ #define FL_FLOAT (1<<15) // Apply floating force to this entity when in water
58
+ #define FL_GRAPHED (1<<16) // Worldgraph has this ent listed as something that blocks a connection
59
+ #define FL_IMMUNE_WATER (1<<17)
60
+ #define FL_IMMUNE_SLIME (1<<18)
61
+ #define FL_IMMUNE_LAVA (1<<19)
62
+ #define FL_PROXY (1<<20) // This is a spectator proxy
63
+ #define FL_ALWAYSTHINK (1<<21) // Brush model flag -- call think every frame regardless of nextthink - ltime (for constantly changing velocity/path)
64
+ #define FL_BASEVELOCITY (1<<22) // Base velocity has been applied this frame (used to convert base velocity into momentum)
65
+ #define FL_MONSTERCLIP (1<<23) // Only collide in with monsters who have FL_MONSTERCLIP set
66
+ #define FL_ONTRAIN (1<<24) // Player is _controlling_ a train, so movement commands should be ignored on client during prediction.
67
+ #define FL_WORLDBRUSH (1<<25) // Not moveable/removeable brush entity (really part of the world, but represented as an entity for transparency or something)
68
+ #define FL_SPECTATOR (1<<26) // This client is a spectator, don't run touch functions, etc.
69
+ #define FL_CUSTOMENTITY (1<<29) // This is a custom entity
70
+ #define FL_KILLME (1<<30) // This entity is marked for death -- This allows the engine to kill ents at the appropriate time
71
+ #define FL_DORMANT (1<<31) // Entity is dormant, no updates to client
72
+
73
+ /**
74
+ * engfunc(EngFunc_WalkMove, entity, Float:yaw, Float:dist, iMode) iMode values
75
+ */
76
+ #define WALKMOVE_NORMAL 0 // Normal walkmove
77
+ #define WALKMOVE_WORLDONLY 1 // Doesn't hit ANY entities, no matter what the solid type
78
+ #define WALKMOVE_CHECKONLY 2 // Move, but don't touch triggers
79
+
80
+ /**
81
+ * engfunc(EngFunc_MoveToOrigin, entity, Float:goal[3], Float:distance, moveType) moveType values
82
+ */
83
+ #define MOVE_NORMAL 0 // normal move in the direction monster is facing
84
+ #define MOVE_STRAFE 1 // moves in direction specified, no matter which way monster is facing
85
+
86
+ /**
87
+ * pev(entity, pev_movetype) values
88
+ */
89
+ #define MOVETYPE_NONE 0 // Never moves
90
+ #define MOVETYPE_WALK 3 // Player only - moving on the ground
91
+ #define MOVETYPE_STEP 4 // Gravity, special edge handling -- monsters use this
92
+ #define MOVETYPE_FLY 5 // No gravity, but still collides with stuff
93
+ #define MOVETYPE_TOSS 6 // Gravity/Collisions
94
+ #define MOVETYPE_PUSH 7 // No clip to world, push and crush
95
+ #define MOVETYPE_NOCLIP 8 // No gravity, no collisions, still do velocity/avelocity
96
+ #define MOVETYPE_FLYMISSILE 9 // Extra size to monsters
97
+ #define MOVETYPE_BOUNCE 10 // Just like Toss, but reflect velocity when contacting surfaces
98
+ #define MOVETYPE_BOUNCEMISSILE 11 // Bounce w/o gravity
99
+ #define MOVETYPE_FOLLOW 12 // Track movement of aiment
100
+ #define MOVETYPE_PUSHSTEP 13 // BSP model that needs physics/world collisions (uses nearest hull for world collision)
101
+
102
+ /**
103
+ * pev(entity, pev_solid) values
104
+ *
105
+ * @note Some movetypes will cause collisions independent of SOLID_NOT and
106
+ * SOLID_TRIGGER when the entity moves. SOLID only effects OTHER entities
107
+ * colliding with this one when they move - UGH!
108
+ */
109
+ #define SOLID_NOT 0 // No interaction with other objects
110
+ #define SOLID_TRIGGER 1 // Touch on edge, but not blocking
111
+ #define SOLID_BBOX 2 // Touch on edge, block
112
+ #define SOLID_SLIDEBOX 3 // Touch on edge, but not an onground
113
+ #define SOLID_BSP 4 // BSP clip, touch on edge, block
114
+
115
+ /**
116
+ * pev(entity, pev_deadflag) values
117
+ */
118
+ #define DEAD_NO 0 // Alive
119
+ #define DEAD_DYING 1 // Playing death animation or still falling off of a ledge waiting to hit ground
120
+ #define DEAD_DEAD 2 // Dead, lying still
121
+ #define DEAD_RESPAWNABLE 3
122
+ #define DEAD_DISCARDBODY 4
123
+
124
+ /**
125
+ * new Float:takedamage, pev(entity, pev_takedamage, takedamage) values
126
+ */
127
+ #define DAMAGE_NO 0.0
128
+ #define DAMAGE_YES 1.0
129
+ #define DAMAGE_AIM 2.0
130
+
131
+ /**
132
+ * pev(entity, pev_effects) values
133
+ */
134
+ #define EF_BRIGHTFIELD 1 // Swirling cloud of particles
135
+ #define EF_MUZZLEFLASH 2 // Single frame ELIGHT on entity attachment 0
136
+ #define EF_BRIGHTLIGHT 4 // DLIGHT centered at entity origin
137
+ #define EF_DIMLIGHT 8 // Player flashlight
138
+ #define EF_INVLIGHT 16 // Get lighting from ceiling
139
+ #define EF_NOINTERP 32 // Don't interpolate the next frame
140
+ #define EF_LIGHT 64 // Rocket flare glow sprite
141
+ #define EF_NODRAW 128 // Don't draw entity
142
+
143
+ /**
144
+ * Spectating camera mode constants
145
+ *
146
+ * @note These constants are linked to different camera modes available when you
147
+ * are spectating (either dead or when in spectator team). Usually this is
148
+ * stored in the pev_iuser1 field in Counter-Strike and Half-Life games.
149
+ */
150
+ #define OBS_NONE 0
151
+ #define OBS_CHASE_LOCKED 1 // Locked Chase Cam
152
+ #define OBS_CHASE_FREE 2 // Free Chase Cam
153
+ #define OBS_ROAMING 3 // Free Look
154
+ #define OBS_IN_EYE 4 // First Person
155
+ #define OBS_MAP_FREE 5 // Free Overview
156
+ #define OBS_MAP_CHASE 6 // Chase Overview
157
+
158
+ /**
159
+ * engfunc(EngFunc_PointContents, Float:origin) return values
160
+ */
161
+ #define CONTENTS_EMPTY -1
162
+ #define CONTENTS_SOLID -2
163
+ #define CONTENTS_WATER -3
164
+ #define CONTENTS_SLIME -4
165
+ #define CONTENTS_LAVA -5
166
+ #define CONTENTS_SKY -6
167
+ #define CONTENTS_ORIGIN -7 // Removed at csg time
168
+ #define CONTENTS_CLIP -8 // Changed to contents_solid
169
+ #define CONTENTS_CURRENT_0 -9
170
+ #define CONTENTS_CURRENT_90 -10
171
+ #define CONTENTS_CURRENT_180 -11
172
+ #define CONTENTS_CURRENT_270 -12
173
+ #define CONTENTS_CURRENT_UP -13
174
+ #define CONTENTS_CURRENT_DOWN -14
175
+ #define CONTENTS_TRANSLUCENT -15
176
+ #define CONTENTS_LADDER -16
177
+ #define CONTENT_FLYFIELD -17
178
+ #define CONTENT_GRAVITY_FLYFIELD -18
179
+ #define CONTENT_FOG -19
180
+
181
+ /**
182
+ * Instant damage values for use with the 3rd parameter of the "Damage" client
183
+ * message.
184
+ */
185
+ #define DMG_GENERIC 0 // Generic damage was done
186
+ #define DMG_CRUSH (1<<0) // Crushed by falling or moving object
187
+ #define DMG_BULLET (1<<1) // Shot
188
+ #define DMG_SLASH (1<<2) // Cut, clawed, stabbed
189
+ #define DMG_BURN (1<<3) // Heat burned
190
+ #define DMG_FREEZE (1<<4) // Frozen
191
+ #define DMG_FALL (1<<5) // Fell too far
192
+ #define DMG_BLAST (1<<6) // Explosive blast damage
193
+ #define DMG_CLUB (1<<7) // Crowbar, punch, headbutt
194
+ #define DMG_SHOCK (1<<8) // Electric shock
195
+ #define DMG_SONIC (1<<9) // Sound pulse shockwave
196
+ #define DMG_ENERGYBEAM (1<<10) // Laser or other high energy beam
197
+ #define DMG_NEVERGIB (1<<12) // With this bit OR'd in, no damage type will be able to gib victims upon death
198
+ #define DMG_ALWAYSGIB (1<<13) // With this bit OR'd in, any damage type can be made to gib victims upon death.
199
+ #define DMG_DROWN (1<<14) // Drowning
200
+ #define DMG_PARALYZE (1<<15) // Slows affected creature down
201
+ #define DMG_NERVEGAS (1<<16) // Nerve toxins, very bad
202
+ #define DMG_POISON (1<<17) // Blood poisioning
203
+ #define DMG_RADIATION (1<<18) // Radiation exposure
204
+ #define DMG_DROWNRECOVER (1<<19) // Drowning recovery
205
+ #define DMG_ACID (1<<20) // Toxic chemicals or acid burns
206
+ #define DMG_SLOWBURN (1<<21) // In an oven
207
+ #define DMG_SLOWFREEZE (1<<22) // In a subzero freezer
208
+ #define DMG_MORTAR (1<<23) // Hit by air raid (done to distinguish grenade from mortar)
209
+ #define DMG_GRENADE (1<<24) // Counter-Strike only - Hit by HE grenade
210
+ #define DMG_TIMEBASED (~(0x3fff)) // Mask for time-based damage
211
+
212
+ /**
213
+ * Gib values used on client kill based on instant damage values
214
+ */
215
+ #define GIB_NORMAL 0 // Gib if entity was overkilled
216
+ #define GIB_NEVER 1 // Never gib, no matter how much death damage is done ( freezing, etc )
217
+ #define GIB_ALWAYS 2 // Always gib ( Houndeye Shock, Barnacle Bite )
218
+ #define GIB_TRY_HEALTH -9000 // Gib players if their health is under this value. (GIB_NEVER overrides this value)
219
+
220
+ /**
221
+ * Valid constants for fNoMonsters parameter of EngFunc_TraceLine,
222
+ * EngFunc_TraceMonsterHull, EngFunc_TraceHull and EngFunc_TraceSphere.
223
+ */
224
+ #define DONT_IGNORE_MONSTERS 0
225
+ #define IGNORE_MONSTERS 1
226
+ #define IGNORE_MISSILE 2
227
+ #define IGNORE_GLASS 0x100
228
+
229
+ /**
230
+ * The hullnumber paramater of EngFunc_TraceHull, EngFunc_TraceModel and
231
+ * DLLFunc_GetHullBounds
232
+ */
233
+ #define HULL_POINT 0
234
+ #define HULL_HUMAN 1
235
+ #define HULL_LARGE 2
236
+ #define HULL_HEAD 3
237
+
238
+ /**
239
+ * global_get(glb_trace_flags)
240
+ */
241
+ #define FTRACE_SIMPLEBOX (1<<0) // Traceline with a simple box
242
+
243
+ /**
244
+ * Used with get/set_es(es_handle, ES_eFlags, ...) (entity_state data structure)
245
+ */
246
+ #define EFLAG_SLERP 1 // Do studio interpolation of this entity
247
+
248
+ /**
249
+ * @section pev(entity, pev_spawnflags) values
250
+ */
251
+
252
+ /**
253
+ * func_train
254
+ */
255
+ #define SF_TRAIN_WAIT_RETRIGGER 1
256
+ #define SF_TRAIN_START_ON 4 // Train is initially moving
257
+ #define SF_TRAIN_PASSABLE 8 // Train is not solid -- used to make water trains
258
+
259
+ /**
260
+ * func_wall_toggle
261
+ */
262
+ #define SF_WALL_START_OFF 0x0001
263
+ #define SF_WALL_NOTSOLID 0x0008
264
+
265
+ /**
266
+ * func_converyor
267
+ */
268
+ #define SF_CONVEYOR_VISUAL 0x0001
269
+ #define SF_CONVEYOR_NOTSOLID 0x0002
270
+
271
+ /**
272
+ * func_button
273
+ */
274
+ #define SF_BUTTON_DONTMOVE 1
275
+ #define SF_BUTTON_TOGGLE 32 // Button stays pushed until reactivated
276
+ #define SF_BUTTON_SPARK_IF_OFF 64 // Button sparks in OFF state
277
+ #define SF_BUTTON_TOUCH_ONLY 256 // Button only fires as a result of USE key.
278
+
279
+ /**
280
+ * func_rot_button
281
+ */
282
+ #define SF_ROTBUTTON_NOTSOLID 1
283
+ #define SF_ROTBUTTON_BACKWARDS 2
284
+
285
+ /**
286
+ * env_global
287
+ */
288
+ #define SF_GLOBAL_SET 1 // Set global state to initial state on spawn
289
+
290
+ /**
291
+ * multisource
292
+ */
293
+ #define SF_MULTI_INIT 1
294
+
295
+ /**
296
+ * momentary_rot_button
297
+ */
298
+ #define SF_MOMENTARY_DOOR 0x0001
299
+
300
+ /**
301
+ * button_target
302
+ */
303
+ #define SF_BTARGET_USE 0x0001
304
+ #define SF_BTARGET_ON 0x0002
305
+
306
+ /**
307
+ * func_door, func_water, func_door_rotating, momementary_door
308
+ */
309
+ #define SF_DOOR_ROTATE_Y 0
310
+ #define SF_DOOR_START_OPEN 1
311
+ #define SF_DOOR_ROTATE_BACKWARDS 2
312
+ #define SF_DOOR_PASSABLE 8
313
+ #define SF_DOOR_ONEWAY 16
314
+ #define SF_DOOR_NO_AUTO_RETURN 32
315
+ #define SF_DOOR_ROTATE_Z 64
316
+ #define SF_DOOR_ROTATE_X 128
317
+ #define SF_DOOR_USE_ONLY 256 // Door must be opened by player's use button
318
+ #define SF_DOOR_NOMONSTERS 512 // Monster can't open
319
+ #define SF_DOOR_TOUCH_ONLY_CLIENTS 1024 // Only clients can touch
320
+ #define SF_DOOR_SILENT 0x80000000 // This bit marks that func_door are actually func_water
321
+
322
+ /**
323
+ * gibshooter
324
+ */
325
+ #define SF_GIBSHOOTER_REPEATABLE 1 // Allows a gibshooter to be refired
326
+
327
+ /**
328
+ * env_funnel
329
+ */
330
+ #define SF_FUNNEL_REVERSE 1 // Funnel effect repels particles instead of attracting them
331
+
332
+ /**
333
+ * env_bubbles
334
+ */
335
+ #define SF_BUBBLES_STARTOFF 0x0001
336
+
337
+ /**
338
+ * env_blood
339
+ */
340
+ #define SF_BLOOD_RANDOM 0x0001
341
+ #define SF_BLOOD_STREAM 0x0002
342
+ #define SF_BLOOD_PLAYER 0x0004
343
+ #define SF_BLOOD_DECAL 0x0008
344
+
345
+ /**
346
+ * env_shake
347
+ */
348
+ #define SF_SHAKE_EVERYONE 0x0001 // Don't check radius
349
+ #define SF_SHAKE_DISRUPT 0x0002 // Disrupt controls
350
+ #define SF_SHAKE_INAIR 0x0004 // Shake players in air
351
+
352
+ /**
353
+ * env_fade
354
+ */
355
+ #define SF_FADE_IN 0x0001 // Fade in, not out
356
+ #define SF_FADE_MODULATE 0x0002 // Modulate, don't blend
357
+ #define SF_FADE_ONLYONE 0x0004
358
+
359
+ /**
360
+ * env_beam, env_lightning
361
+ */
362
+ #define SF_BEAM_STARTON 0x0001
363
+ #define SF_BEAM_TOGGLE 0x0002
364
+ #define SF_BEAM_RANDOM 0x0004
365
+ #define SF_BEAM_RING 0x0008
366
+ #define SF_BEAM_SPARKSTART 0x0010
367
+ #define SF_BEAM_SPARKEND 0x0020
368
+ #define SF_BEAM_DECALS 0x0040
369
+ #define SF_BEAM_SHADEIN 0x0080
370
+ #define SF_BEAM_SHADEOUT 0x0100
371
+ #define SF_BEAM_TEMPORARY 0x8000
372
+
373
+ /**
374
+ * env_sprite
375
+ */
376
+ #define SF_SPRITE_STARTON 0x0001
377
+ #define SF_SPRITE_ONCE 0x0002
378
+ #define SF_SPRITE_TEMPORARY 0x8000
379
+
380
+ /**
381
+ * env_message
382
+ */
383
+ #define SF_MESSAGE_ONCE 0x0001 // Fade in, not out
384
+ #define SF_MESSAGE_ALL 0x0002 // Send to all clients
385
+
386
+ /**
387
+ * env_explosion
388
+ */
389
+ #define SF_ENVEXPLOSION_NODAMAGE (1<<0) // When set, ENV_EXPLOSION will not actually inflict damage
390
+ #define SF_ENVEXPLOSION_REPEATABLE (1<<1) // Can this entity be refired?
391
+ #define SF_ENVEXPLOSION_NOFIREBALL (1<<2) // Don't draw the fireball
392
+ #define SF_ENVEXPLOSION_NOSMOKE (1<<3) // Don't draw the smoke
393
+ #define SF_ENVEXPLOSION_NODECAL (1<<4) // Don't make a scorch mark
394
+ #define SF_ENVEXPLOSION_NOSPARKS (1<<5) // Don't make a scorch mark
395
+
396
+ /**
397
+ * func_tank
398
+ */
399
+ #define SF_TANK_ACTIVE 0x0001
400
+ #define SF_TANK_PLAYER 0x0002
401
+ #define SF_TANK_HUMANS 0x0004
402
+ #define SF_TANK_ALIENS 0x0008
403
+ #define SF_TANK_LINEOFSIGHT 0x0010
404
+ #define SF_TANK_CANCONTROL 0x0020
405
+ #define SF_TANK_SOUNDON 0x8000
406
+
407
+ /**
408
+ * grenade
409
+ */
410
+ #define SF_DETONATE 0x0001
411
+
412
+ /**
413
+ * item_suit
414
+ */
415
+ #define SF_SUIT_SHORTLOGON 0x0001
416
+
417
+ /**
418
+ * game_score
419
+ */
420
+ #define SF_SCORE_NEGATIVE 0x0001
421
+ #define SF_SCORE_TEAM 0x0002
422
+
423
+ /**
424
+ * game_text
425
+ */
426
+ #define SF_ENVTEXT_ALLPLAYERS 0x0001
427
+
428
+ /**
429
+ * game_team_master
430
+ */
431
+ #define SF_TEAMMASTER_FIREONCE 0x0001
432
+ #define SF_TEAMMASTER_ANYTEAM 0x0002
433
+
434
+ /**
435
+ * game_team_set
436
+ */
437
+ #define SF_TEAMSET_FIREONCE 0x0001
438
+ #define SF_TEAMSET_CLEARTEAM 0x0002
439
+
440
+ /**
441
+ * game_player_hurt
442
+ */
443
+ #define SF_PKILL_FIREONCE 0x0001
444
+
445
+ /**
446
+ * game_counter
447
+ */
448
+ #define SF_GAMECOUNT_FIREONCE 0x0001
449
+ #define SF_GAMECOUNT_RESET 0x0002
450
+
451
+ /**
452
+ * game_player_equip
453
+ */
454
+ #define SF_PLAYEREQUIP_USEONLY 0x0001
455
+
456
+ /**
457
+ * game_player_team
458
+ */
459
+ #define SF_PTEAM_FIREONCE 0x0001
460
+ #define SF_PTEAM_KILL 0x0002
461
+ #define SF_PTEAM_GIB 0x0004
462
+
463
+ /**
464
+ * func_trackchange
465
+ */
466
+ #define SF_PLAT_TOGGLE 0x0001
467
+ #define SF_TRACK_ACTIVATETRAIN 0x00000001
468
+ #define SF_TRACK_RELINK 0x00000002
469
+ #define SF_TRACK_ROTMOVE 0x00000004
470
+ #define SF_TRACK_STARTBOTTOM 0x00000008
471
+ #define SF_TRACK_DONT_MOVE 0x00000010
472
+
473
+ /**
474
+ * func_tracktrain
475
+ */
476
+ #define SF_TRACKTRAIN_NOPITCH 0x0001
477
+ #define SF_TRACKTRAIN_NOCONTROL 0x0002
478
+ #define SF_TRACKTRAIN_FORWARDONLY 0x0004
479
+ #define SF_TRACKTRAIN_PASSABLE 0x0008
480
+ #define SF_PATH_DISABLED 0x00000001
481
+ #define SF_PATH_FIREONCE 0x00000002
482
+ #define SF_PATH_ALTREVERSE 0x00000004
483
+ #define SF_PATH_DISABLE_TRAIN 0x00000008
484
+ #define SF_PATH_ALTERNATE 0x00008000
485
+ #define SF_CORNER_WAITFORTRIG 0x001
486
+ #define SF_CORNER_TELEPORT 0x002
487
+ #define SF_CORNER_FIREONCE 0x004
488
+
489
+ /**
490
+ * func_plat
491
+ */
492
+ #define SF_PLAT_TOGGLE 0x0001
493
+
494
+ /**
495
+ * path_track
496
+ */
497
+ #define SF_PATH_DISABLED 0x00000001
498
+ #define SF_PATH_FIREONCE 0x00000002
499
+ #define SF_PATH_ALTREVERSE 0x00000004
500
+ #define SF_PATH_DISABLE_TRAIN 0x00000008
501
+ #define SF_PATH_ALTERNATE 0x00008000
502
+
503
+ /**
504
+ * path_corner
505
+ */
506
+ #define SF_CORNER_WAITFORTRIG 0x001
507
+ #define SF_CORNER_TELEPORT 0x002
508
+ #define SF_CORNER_FIREONCE 0x004
509
+
510
+ /**
511
+ * trigger_push
512
+ */
513
+ #define SF_TRIGGER_PUSH_START_OFF 2 // Spawnflag that makes trigger_push spawn turned OFF
514
+
515
+ /**
516
+ * trigger_hurt
517
+ */
518
+ #define SF_TRIGGER_HURT_TARGETONCE 1 // Only fire hurt target once
519
+ #define SF_TRIGGER_HURT_START_OFF 2 // Spawnflag that makes trigger_push spawn turned OFF
520
+ #define SF_TRIGGER_HURT_NO_CLIENTS 8 // Spawnflag that makes trigger_push spawn turned OFF
521
+ #define SF_TRIGGER_HURT_CLIENTONLYFIRE 16 // Trigger hurt will only fire its target if it is hurting a client
522
+ #define SF_TRIGGER_HURT_CLIENTONLYTOUCH 32 // Only clients may touch this trigger
523
+
524
+ /**
525
+ * trigger_auto
526
+ */
527
+ #define SF_AUTO_FIREONCE 0x0001
528
+ #define SF_AUTO_NORESET 0x0002
529
+
530
+ /**
531
+ * trigger_relay
532
+ */
533
+ #define SF_RELAY_FIREONCE 0x0001
534
+
535
+ /**
536
+ * multi_manager
537
+ */
538
+ #define SF_MULTIMAN_CLONE 0x80000000
539
+ #define SF_MULTIMAN_THREAD 0x00000001
540
+
541
+ /**
542
+ * env_render
543
+ * @note These are flags to indicate masking off various render parameters that
544
+ * are usually copied to the targets
545
+ */
546
+ #define SF_RENDER_MASKFX (1<<0)
547
+ #define SF_RENDER_MASKAMT (1<<1)
548
+ #define SF_RENDER_MASKMODE (1<<2)
549
+ #define SF_RENDER_MASKCOLOR (1<<3)
550
+
551
+ /**
552
+ * trigger_changelevel
553
+ */
554
+ #define SF_CHANGELEVEL_USEONLY 0x0002
555
+
556
+ /**
557
+ * trigger_endsection
558
+ */
559
+ #define SF_ENDSECTION_USEONLY 0x0001
560
+
561
+ /**
562
+ * trigger_camera
563
+ */
564
+ #define SF_CAMERA_PLAYER_POSITION 1
565
+ #define SF_CAMERA_PLAYER_TARGET 2
566
+ #define SF_CAMERA_PLAYER_TAKECONTROL 4
567
+
568
+ /**
569
+ * func_rotating
570
+ */
571
+ #define SF_BRUSH_ROTATE_Y_AXIS 0
572
+ #define SF_BRUSH_ROTATE_INSTANT 1
573
+ #define SF_BRUSH_ROTATE_BACKWARDS 2
574
+ #define SF_BRUSH_ROTATE_Z_AXIS 4
575
+ #define SF_BRUSH_ROTATE_X_AXIS 8
576
+ #define SF_PENDULUM_AUTO_RETURN 16
577
+ #define SF_PENDULUM_PASSABLE 32
578
+ #define SF_BRUSH_ROTATE_SMALLRADIUS 128
579
+ #define SF_BRUSH_ROTATE_MEDIUMRADIUS 256
580
+ #define SF_BRUSH_ROTATE_LARGERADIUS 512
581
+
582
+ /**
583
+ * triggers
584
+ */
585
+ #define SF_TRIGGER_ALLOWMONSTERS 1 // Monsters allowed to fire this trigger
586
+ #define SF_TRIGGER_NOCLIENTS 2 // Players not allowed to fire this trigger
587
+ #define SF_TRIGGER_PUSHABLES 4 // Only pushables can fire this trigger
588
+
589
+ #define SF_TRIG_PUSH_ONCE 1
590
+
591
+ /**
592
+ * trigger_multiple
593
+ */
594
+ #define SF_TRIGGER_MULTIPLE_NOTOUCH 0x0001
595
+
596
+ /**
597
+ * trigger_counter
598
+ */
599
+ #define SF_TRIGGER_COUNTER_NOMESSAGE 0x0001
600
+
601
+ /**
602
+ * func_breakable
603
+ */
604
+ #define SF_BREAK_TRIGGER_ONLY 1 // May only be broken by trigger
605
+ #define SF_BREAK_TOUCH 2 // Can be 'crashed through' by running player (plate glass)
606
+ #define SF_BREAK_PRESSURE 4 // Can be broken by a player standing on it
607
+ #define SF_BREAK_CROWBAR 256 // Instant break if hit with crowbar
608
+
609
+ /**
610
+ * func_pushable (also func_breakable, so don't collide with those flags)
611
+ */
612
+ #define SF_PUSH_BREAKABLE 128
613
+
614
+ /**
615
+ * light_spawn
616
+ */
617
+ #define SF_LIGHT_START_OFF 1
618
+ #define SPAWNFLAG_NOMESSAGE 1
619
+ #define SPAWNFLAG_NOTOUCH 1
620
+ #define SPAWNFLAG_DROIDONLY 4
621
+ #define SPAWNFLAG_USEONLY 1 // Can't be touched, must be used (buttons)
622
+
623
+ /**
624
+ * Monster Spawnflags
625
+ */
626
+ #define SF_MONSTER_WAIT_TILL_SEEN 1 // Spawnflag that makes monsters wait until player can see them before attacking
627
+ #define SF_MONSTER_GAG 2 // No idle noises from this monster
628
+ #define SF_MONSTER_HITMONSTERCLIP 4
629
+ #define SF_MONSTER_PRISONER 16 // Monster won't attack anyone, no one will attacke him
630
+ #define SF_MONSTER_WAIT_FOR_SCRIPT 128 // Spawnflag that makes monsters wait to check for attacking until the script is done or they've been attacked
631
+ #define SF_MONSTER_PREDISASTER 256 // This is a predisaster scientist or barney; influences how they speak
632
+ #define SF_MONSTER_FADECORPSE 512 // Fade out corpse after death
633
+ #define SF_MONSTER_FALL_TO_GROUND 0x80000000
634
+ #define SF_MONSTER_TURRET_AUTOACTIVATE 32
635
+ #define SF_MONSTER_TURRET_STARTINACTIVE 64
636
+ #define SF_MONSTER_WAIT_UNTIL_PROVOKED 64 // Don't attack the player unless provoked
637
+
638
+ /**
639
+ * info_decal
640
+ */
641
+ #define SF_DECAL_NOTINDEATHMATCH 2048
642
+
643
+ /**
644
+ * worldspawn
645
+ */
646
+ #define SF_WORLD_DARK 0x0001 // Fade from black at startup
647
+ #define SF_WORLD_TITLE 0x0002 // Display game title at startup
648
+ #define SF_WORLD_FORCETEAM 0x0004 // Force teams
649
+
650
+ /**
651
+ * Set this bit on guns and stuff that should never respawn
652
+ */
653
+ #define SF_NORESPAWN (1<<30)
654
+
655
+ /**
656
+ * @endsection
657
+ */
658
+
659
+ /**
660
+ * Train status values
661
+ */
662
+ #define TRAIN_ACTIVE 0x80
663
+ #define TRAIN_NEW 0xc0
664
+
665
+ #define TRAIN_OFF 0x00
666
+ #define TRAIN_NEUTRAL 0x01
667
+ #define TRAIN_SLOW 0x02
668
+ #define TRAIN_MEDIUM 0x03
669
+ #define TRAIN_FAST 0x04
670
+ #define TRAIN_BACK 0x05
671
+
672
+ /**
673
+ * Valve Mod Weapon Constants
674
+ */
675
+ #define HLI_HEALTHKIT 1
676
+ #define HLI_ANTIDOTE 2
677
+ #define HLI_SECURITY 3
678
+ #define HLI_BATTERY 4
679
+
680
+ #define HLW_NONE 0
681
+ #define HLW_CROWBAR 1
682
+ #define HLW_GLOCK 2
683
+ #define HLW_PYTHON 3
684
+ #define HLW_MP5 4
685
+ #define HLW_CHAINGUN 5
686
+ #define HLW_CROSSBOW 6
687
+ #define HLW_SHOTGUN 7
688
+ #define HLW_RPG 8
689
+ #define HLW_GAUSS 9
690
+ #define HLW_EGON 10
691
+ #define HLW_HORNETGUN 11
692
+ #define HLW_HANDGRENADE 12
693
+ #define HLW_TRIPMINE 13
694
+ #define HLW_SATCHEL 14
695
+ #define HLW_SNARK 15
696
+ #define HLW_SUIT 31
697
+ #define HLW_ALLWEAPONS (~(1<<HLW_SUIT))
698
+
699
+ /**
700
+ * Item's flags
701
+ */
702
+ #define ITEM_FLAG_SELECTONEMPTY (1<<0)
703
+ #define ITEM_FLAG_NOAUTORELOAD (1<<1)
704
+ #define ITEM_FLAG_NOAUTOSWITCHEMPTY (1<<2)
705
+ #define ITEM_FLAG_LIMITINWORLD (1<<3)
706
+ #define ITEM_FLAG_EXHAUSTIBLE (1<<4)
707
+
708
+ /**
709
+ * PlaybackEvent flags
710
+ */
711
+ #define FEV_NOTHOST (1<<0) // Skip local host for event send.
712
+ #define FEV_RELIABLE (1<<1) // Send the event reliably. You must specify the origin and angles
713
+ // for this to work correctly on the server for anything
714
+ // that depends on the event origin/angles. I.e., the origin/angles are not
715
+ // taken from the invoking edict for reliable events.
716
+ #define FEV_GLOBAL (1<<2) // Don't restrict to PAS/PVS, send this event to _everybody_ on the server ( useful for stopping CHAN_STATIC
717
+ // sounds started by client event when client is not in PVS anymore ( hwguy in TFC e.g. ).
718
+ #define FEV_UPDATE (1<<3) // If this client already has one of these events in its queue, just update the event instead of sending it as a duplicate
719
+ #define FEV_HOSTONLY (1<<4) // Only send to entity specified as the invoker
720
+ #define FEV_SERVER (1<<5) // Only send if the event was created on the server.
721
+ #define FEV_CLIENT (1<<6) // Only issue event client side ( from shared code )
722
+
723
+ /**
724
+ * Cap bits to indicate what an object's capabilities are, currently used for
725
+ * save/restore and level transitions.
726
+ */
727
+ #define FCAP_CUSTOMSAVE 0x00000001
728
+ #define FCAP_ACROSS_TRANSITION 0x00000002 // should transfer between transitions
729
+ #define FCAP_MUST_SPAWN 0x00000004 // Spawn after restore
730
+ #define FCAP_DONT_SAVE 0x80000000 // Don't save this
731
+ #define FCAP_IMPULSE_USE 0x00000008 // can be used by the player
732
+ #define FCAP_CONTINUOUS_USE 0x00000010 // can be used by the player
733
+ #define FCAP_ONOFF_USE 0x00000020 // can be used by the player
734
+ #define FCAP_DIRECTIONAL_USE 0x00000040 // Player sends +/- 1 when using (currently only tracktrains)
735
+ #define FCAP_MASTER 0x00000080 // Can be used to "master" other entities (like multisource)
736
+ #define FCAP_MUST_RESET 0x00000100 // Should reset on the new round
737
+ #define FCAP_MUST_RELEASE 0x00000200 // Should release on the new round
738
+ #define FCAP_DONT_SAVE 0x80000000 // Don't save this
739
+
740
+ // UNDONE: This will ignore transition volumes (trigger_transition), but not the PVS!!!
741
+ #define FCAP_FORCE_TRANSITION 0x00000080 // ALWAYS goes across transitions
742
+
743
+ /**
744
+ * All monsters need this data
745
+ */
746
+ #define DONT_BLEED -1
747
+ #define BLOOD_COLOR_RED 247
748
+ #define BLOOD_COLOR_YELLOW 195
749
+ #define BLOOD_COLOR_GREEN BLOOD_COLOR_YELLOW
750
+
751
+ /**
752
+ * Player physics flags
753
+ */
754
+ #define PFLAG_ONLADDER (1<<0)
755
+ #define PFLAG_ONSWING (1<<0)
756
+ #define PFLAG_ONTRAIN (1<<1)
757
+ #define PFLAG_ONBARNACLE (1<<2)
758
+ #define PFLAG_DUCKING (1<<3) // In the process of ducking, but totally squatted yet
759
+ #define PFLAG_USING (1<<4) // Using a continuous entity
760
+ #define PFLAG_OBSERVER (1<<5) // Player is locked in stationary cam mode. Spectators can move, observers can't.
761
+
762
+ /**
763
+ * Player hide HUD values
764
+ */
765
+ #define HIDEHUD_WEAPONS (1<<0)
766
+ #define HIDEHUD_FLASHLIGHT (1<<1)
767
+ #define HIDEHUD_ALL (1<<2)
768
+ #define HIDEHUD_HEALTH (1<<3)
769
+ #define HIDEHUD_TIMER (1<<4)
770
+ #define HIDEHUD_MONEY (1<<5)
771
+ #define HIDEHUD_CROSSHAIR (1<<6)
772
+ #define HIDEHUD_OBSERVER_CROSSHAIR (1<<7)
773
+
774
+ /**
775
+ * Entity classification
776
+ */
777
+ #define CLASS_NONE 0
778
+ #define CLASS_MACHINE 1
779
+ #define CLASS_PLAYER 2
780
+ #define CLASS_HUMAN_PASSIVE 3
781
+ #define CLASS_HUMAN_MILITARY 4
782
+ #define CLASS_ALIEN_MILITARY 5
783
+ #define CLASS_ALIEN_PASSIVE 6
784
+ #define CLASS_ALIEN_MONSTER 7
785
+ #define CLASS_ALIEN_PREY 8
786
+ #define CLASS_ALIEN_PREDATOR 9
787
+ #define CLASS_INSECT 10
788
+ #define CLASS_PLAYER_ALLY 11
789
+ #define CLASS_PLAYER_BIOWEAPON 12 // hornets and snarks.launched by players
790
+ #define CLASS_ALIEN_BIOWEAPON 13 // hornets and snarks.launched by the alien menace
791
+ #define CLASS_VEHICLE 14
792
+ #define CLASS_BARNACLE 99 // special because no one pays attention to it, and it eats a wide cross-section of creatures.
793
+
794
+ /**
795
+ * Entities that toggle (buttons/triggers/doors) need this
796
+ */
797
+ #define TS_AT_TOP 0
798
+ #define TS_AT_BOTTOM 1
799
+ #define TS_GOING_UP 2
800
+ #define TS_GOING_DOWN 3
801
+
802
+ /**
803
+ * Entity use states (buttons/triggers/platforms)
804
+ */
805
+ #define USE_OFF 0
806
+ #define USE_ON 1
807
+ #define USE_SET 2
808
+ #define USE_TOGGLE 3