Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

469 lines
19 KiB

  1. //========= Copyright (c) 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //
  7. //=============================================================================//
  8. #ifndef CONST_H
  9. #define CONST_H
  10. #ifdef _WIN32
  11. #pragma once
  12. #endif
  13. // the command line param that tells the engine to use steam
  14. #define STEAM_PARM "-steam"
  15. // the command line param to tell dedicated server to restart
  16. // if they are out of date
  17. #define AUTO_RESTART "-autoupdate"
  18. // the message a server sends when a clients steam login is expired
  19. #define INVALID_STEAM_TICKET "Invalid STEAM UserID Ticket\n"
  20. #define INVALID_STEAM_LOGON "No Steam logon\n"
  21. #define INVALID_STEAM_VACBANSTATE "VAC banned from secure server\n"
  22. #define INVALID_STEAM_LOGGED_IN_ELSEWHERE "This Steam account is being used in another location\n"
  23. #define DEFAULT_TICK_INTERVAL_X360 (1.0 / 29.970030) // This matches x360 refresh, but is not critical
  24. #define DEFAULT_TICK_INTERVAL_PS3 (1.0 / 30.0)
  25. #define DEFAULT_TICK_INTERVAL_PC (1.0 / 64.0)
  26. // This is the default, see shareddefs.h for mod-specific value, which can override this
  27. #if defined( _X360 )
  28. #define DEFAULT_TICK_INTERVAL DEFAULT_TICK_INTERVAL_X360
  29. #elif defined( _PS3 )
  30. #define DEFAULT_TICK_INTERVAL DEFAULT_TICK_INTERVAL_PS3
  31. #else
  32. #define DEFAULT_TICK_INTERVAL DEFAULT_TICK_INTERVAL_PC
  33. #endif
  34. #define MINIMUM_TICK_INTERVAL (4.0f / 512.0f) // 128 fps
  35. #define MAXIMUM_TICK_INTERVAL (25.0f / 512.0f) // 20.48 fps
  36. // This is the max # of players the engine can handle
  37. // Note, must be power of 2
  38. #define ABSOLUTE_PLAYER_LIMIT 255
  39. #define ABSOLUTE_PLAYER_LIMIT_DW ( (ABSOLUTE_PLAYER_LIMIT/32) + 1 )
  40. #if ABSOLUTE_PLAYER_LIMIT > 32
  41. #define CPlayerBitVec CBitVec<ABSOLUTE_PLAYER_LIMIT>
  42. #else
  43. #define CPlayerBitVec CDWordBitVec
  44. #endif
  45. // a player name may have 31 chars + 0 on the PC.
  46. // the 360 only allows 15 char + 0, but stick with the larger PC size for cross-platform communication
  47. #define MAX_PLAYER_NAME_LENGTH 128
  48. #ifdef _X360
  49. #define MAX_PLAYERS_PER_CLIENT XUSER_MAX_COUNT // Xbox 360 supports 4 players per console
  50. #else
  51. #define MAX_PLAYERS_PER_CLIENT 1 // One player per PC
  52. #endif
  53. #define MAX_MAP_NAME 64
  54. #define MAX_NETWORKID_LENGTH 64 // num chars for a network (i.e steam) ID
  55. // BUGBUG: Reconcile with or derive this from the engine's internal definition!
  56. // FIXME: Somebody added an extra bit because they needed to make it signed, not sure why?
  57. // Anyways must have this value in sync(+1) with qlimits.h and effect_dispatch_data.cpp
  58. #define SP_MODEL_INDEX_BITS 13
  59. // How many bits to use to encode an edict.
  60. #define MAX_EDICT_BITS 11 // # of bits needed to represent max edicts
  61. // Max # of edicts in a level
  62. #define MAX_EDICTS (1<<MAX_EDICT_BITS)
  63. // How many bits to use to encode an server class index
  64. #define MAX_SERVER_CLASS_BITS 9
  65. // Max # of networkable server classes
  66. #define MAX_SERVER_CLASSES (1<<MAX_SERVER_CLASS_BITS)
  67. #define SIGNED_GUID_LEN 32 // Hashed CD Key (32 hex alphabetic chars + 0 terminator )
  68. // Used for networking ehandles.
  69. #define NUM_ENT_ENTRY_BITS (MAX_EDICT_BITS + 2)
  70. #define NUM_ENT_ENTRIES (1 << NUM_ENT_ENTRY_BITS)
  71. #define INVALID_EHANDLE_INDEX 0xFFFFFFFF
  72. #define NUM_SERIAL_NUM_BITS 16 // (32 - NUM_ENT_ENTRY_BITS)
  73. #define NUM_SERIAL_NUM_SHIFT_BITS (32 - NUM_SERIAL_NUM_BITS)
  74. #define ENT_ENTRY_MASK (( 1 << NUM_SERIAL_NUM_BITS) - 1)
  75. // Networked ehandles use less bits to encode the serial number.
  76. #define NUM_NETWORKED_EHANDLE_SERIAL_NUMBER_BITS 10
  77. #define NUM_NETWORKED_EHANDLE_BITS (MAX_EDICT_BITS + NUM_NETWORKED_EHANDLE_SERIAL_NUMBER_BITS)
  78. #define INVALID_NETWORKED_EHANDLE_VALUE ((1 << NUM_NETWORKED_EHANDLE_BITS) - 1)
  79. // This is the maximum amount of data a PackedEntity can have. Having a limit allows us
  80. // to use static arrays sometimes instead of allocating memory all over the place.
  81. #define MAX_PACKEDENTITY_DATA (16384)
  82. // This is the maximum number of properties that can be delta'd. Must be evenly divisible by 8.
  83. #define MAX_PACKEDENTITY_PROPS (4096)
  84. // a client can have up to 4 customization files (logo, sounds, models, txt).
  85. #define MAX_CUSTOM_FILES 4 // max 4 files
  86. #define MAX_CUSTOM_FILE_SIZE 524288 // Half a megabyte
  87. //
  88. // Constants shared by the engine and dlls
  89. // This header file included by engine files and DLL files.
  90. // Most came from server.h
  91. // CBaseEntity::m_fFlags
  92. // PLAYER SPECIFIC FLAGS FIRST BECAUSE WE USE ONLY A FEW BITS OF NETWORK PRECISION
  93. #define FL_ONGROUND (1<<0) // At rest / on the ground
  94. #define FL_DUCKING (1<<1) // Player flag -- Player is fully crouched
  95. #define FL_ANIMDUCKING (1<<2) // Player flag -- Player is in the process of crouching or uncrouching but could be in transition
  96. // examples: Fully ducked: FL_DUCKING & FL_ANIMDUCKING
  97. // Previously fully ducked, unducking in progress: FL_DUCKING & !FL_ANIMDUCKING
  98. // Fully unducked: !FL_DUCKING & !FL_ANIMDUCKING
  99. // Previously fully unducked, ducking in progress: !FL_DUCKING & FL_ANIMDUCKING
  100. #define FL_WATERJUMP (1<<3) // player jumping out of water
  101. #define FL_ONTRAIN (1<<4) // Player is _controlling_ a train, so movement commands should be ignored on client during prediction.
  102. #define FL_INRAIN (1<<5) // Indicates the entity is standing in rain
  103. #define FL_FROZEN (1<<6) // Player is frozen for 3rd person camera
  104. #define FL_ATCONTROLS (1<<7) // Player can't move, but keeps key inputs for controlling another entity
  105. #define FL_CLIENT (1<<8) // Is a player
  106. #define FL_FAKECLIENT (1<<9) // Fake client, simulated server side; don't send network messages to them
  107. // NON-PLAYER SPECIFIC (i.e., not used by GameMovement or the client .dll ) -- Can still be applied to players, though
  108. #define FL_INWATER (1<<10) // In water
  109. // NOTE if you move things up, make sure to change this value
  110. #define PLAYER_FLAG_BITS 11
  111. #define FL_FLY (1<<11) // Changes the SV_Movestep() behavior to not need to be on ground
  112. #define FL_SWIM (1<<12) // Changes the SV_Movestep() behavior to not need to be on ground (but stay in water)
  113. #define FL_CONVEYOR (1<<13)
  114. #define FL_NPC (1<<14)
  115. #define FL_GODMODE (1<<15)
  116. #define FL_NOTARGET (1<<16)
  117. #define FL_AIMTARGET (1<<17) // set if the crosshair needs to aim onto the entity
  118. #define FL_PARTIALGROUND (1<<18) // not all corners are valid
  119. #define FL_STATICPROP (1<<19) // Eetsa static prop!
  120. #ifdef PORTAL2
  121. #define FL_AFFECTED_BY_PAINT (1<<20)
  122. #else
  123. #define FL_GRAPHED (1<<20) // worldgraph has this ent listed as something that blocks a connection
  124. #endif
  125. #define FL_GRENADE (1<<21)
  126. #define FL_STEPMOVEMENT (1<<22) // Changes the SV_Movestep() behavior to not do any processing
  127. #define FL_DONTTOUCH (1<<23) // Doesn't generate touch functions, generates Untouch() for anything it was touching when this flag was set
  128. #define FL_BASEVELOCITY (1<<24) // Base velocity has been applied this frame (used to convert base velocity into momentum)
  129. #define FL_WORLDBRUSH (1<<25) // Not moveable/removeable brush entity (really part of the world, but represented as an entity for transparency or something)
  130. #define FL_OBJECT (1<<26) // Terrible name. This is an object that NPCs should see. Missiles, for example.
  131. #define FL_KILLME (1<<27) // This entity is marked for death -- will be freed by game DLL
  132. #define FL_ONFIRE (1<<28) // You know...
  133. #define FL_DISSOLVING (1<<29) // We're dissolving!
  134. #define FL_TRANSRAGDOLL (1<<30) // In the process of turning into a client side ragdoll.
  135. #define FL_UNBLOCKABLE_BY_PLAYER (1<<31) // pusher that can't be blocked by the player
  136. // FIXME[HPE]: this won't actually work - we're out of bits. :(
  137. #ifdef PORTAL2
  138. #define FL_UNPAINTABLE (1<<32) // Unpaintable entities!
  139. #else
  140. #define FL_FREEZING (1<<32) // We're becoming frozen!
  141. #endif
  142. // edict->movetype values
  143. enum MoveType_t
  144. {
  145. MOVETYPE_NONE = 0, // never moves
  146. MOVETYPE_ISOMETRIC, // For players -- in TF2 commander view, etc.
  147. MOVETYPE_WALK, // Player only - moving on the ground
  148. MOVETYPE_STEP, // gravity, special edge handling -- monsters use this
  149. MOVETYPE_FLY, // No gravity, but still collides with stuff
  150. MOVETYPE_FLYGRAVITY, // flies through the air + is affected by gravity
  151. MOVETYPE_VPHYSICS, // uses VPHYSICS for simulation
  152. MOVETYPE_PUSH, // no clip to world, push and crush
  153. MOVETYPE_NOCLIP, // No gravity, no collisions, still do velocity/avelocity
  154. MOVETYPE_LADDER, // Used by players only when going onto a ladder
  155. MOVETYPE_OBSERVER, // Observer movement, depends on player's observer mode
  156. MOVETYPE_CUSTOM, // Allows the entity to describe its own physics
  157. // should always be defined as the last item in the list
  158. MOVETYPE_LAST = MOVETYPE_CUSTOM,
  159. MOVETYPE_MAX_BITS = 4
  160. };
  161. // edict->movecollide values
  162. enum MoveCollide_t
  163. {
  164. MOVECOLLIDE_DEFAULT = 0,
  165. // These ones only work for MOVETYPE_FLY + MOVETYPE_FLYGRAVITY
  166. MOVECOLLIDE_FLY_BOUNCE, // bounces, reflects, based on elasticity of surface and object - applies friction (adjust velocity)
  167. MOVECOLLIDE_FLY_CUSTOM, // Touch() will modify the velocity however it likes
  168. MOVECOLLIDE_FLY_SLIDE, // slides along surfaces (no bounce) - applies friciton (adjusts velocity)
  169. MOVECOLLIDE_COUNT, // Number of different movecollides
  170. // When adding new movecollide types, make sure this is correct
  171. MOVECOLLIDE_MAX_BITS = 3
  172. };
  173. // edict->solid values
  174. // NOTE: Some movetypes will cause collisions independent of SOLID_NOT/SOLID_TRIGGER when the entity moves
  175. // SOLID only effects OTHER entities colliding with this one when they move - UGH!
  176. // Solid type basically describes how the bounding volume of the object is represented
  177. // NOTE: SOLID_BBOX MUST BE 2, and SOLID_VPHYSICS MUST BE 6
  178. // NOTE: These numerical values are used in the FGD by the prop code (see prop_dynamic)
  179. enum SolidType_t
  180. {
  181. SOLID_NONE = 0, // no solid model
  182. SOLID_BSP = 1, // a BSP tree
  183. SOLID_BBOX = 2, // an AABB
  184. SOLID_OBB = 3, // an OBB (not implemented yet)
  185. SOLID_OBB_YAW = 4, // an OBB, constrained so that it can only yaw
  186. SOLID_CUSTOM = 5, // Always call into the entity for tests
  187. SOLID_VPHYSICS = 6, // solid vphysics object, get vcollide from the model and collide with that
  188. SOLID_LAST,
  189. };
  190. enum SolidFlags_t
  191. {
  192. FSOLID_CUSTOMRAYTEST = 0x0001, // Ignore solid type + always call into the entity for ray tests
  193. FSOLID_CUSTOMBOXTEST = 0x0002, // Ignore solid type + always call into the entity for swept box tests
  194. FSOLID_NOT_SOLID = 0x0004, // Are we currently not solid?
  195. FSOLID_TRIGGER = 0x0008, // This is something may be collideable but fires touch functions
  196. // even when it's not collideable (when the FSOLID_NOT_SOLID flag is set)
  197. FSOLID_NOT_STANDABLE = 0x0010, // You can't stand on this
  198. FSOLID_VOLUME_CONTENTS = 0x0020, // Contains volumetric contents (like water)
  199. FSOLID_FORCE_WORLD_ALIGNED = 0x0040, // Forces the collision rep to be world-aligned even if it's SOLID_BSP or SOLID_VPHYSICS
  200. FSOLID_USE_TRIGGER_BOUNDS = 0x0080, // Uses a special trigger bounds separate from the normal OBB
  201. FSOLID_ROOT_PARENT_ALIGNED = 0x0100, // Collisions are defined in root parent's local coordinate space
  202. FSOLID_TRIGGER_TOUCH_DEBRIS = 0x0200, // This trigger will touch debris objects
  203. FSOLID_TRIGGER_TOUCH_PLAYER = 0x0400, // This trigger will touch only players
  204. FSOLID_NOT_MOVEABLE = 0x0800, // Assume this object will not move
  205. FSOLID_MAX_BITS = 12
  206. };
  207. //-----------------------------------------------------------------------------
  208. // A couple of inline helper methods
  209. //-----------------------------------------------------------------------------
  210. inline bool IsSolid( SolidType_t solidType, int nSolidFlags )
  211. {
  212. return (solidType != SOLID_NONE) && ((nSolidFlags & FSOLID_NOT_SOLID) == 0);
  213. }
  214. // m_lifeState values
  215. #define LIFE_ALIVE 0 // alive
  216. #define LIFE_DYING 1 // playing death animation or still falling off of a ledge waiting to hit ground
  217. #define LIFE_DEAD 2 // dead. lying still.
  218. #define LIFE_RESPAWNABLE 3
  219. #define LIFE_DISCARDBODY 4
  220. // entity effects
  221. enum
  222. {
  223. EF_BONEMERGE = 0x001, // Performs bone merge on client side
  224. EF_BRIGHTLIGHT = 0x002, // DLIGHT centered at entity origin
  225. EF_DIMLIGHT = 0x004, // player flashlight
  226. EF_NOINTERP = 0x008, // don't interpolate the next frame
  227. EF_NOSHADOW = 0x010, // Don't cast no shadow
  228. EF_NODRAW = 0x020, // don't draw entity
  229. EF_NORECEIVESHADOW = 0x040, // Don't receive no shadow
  230. EF_BONEMERGE_FASTCULL = 0x080, // For use with EF_BONEMERGE. If this is set, then it places this ent's origin at its
  231. // parent and uses the parent's bbox + the max extents of the aiment.
  232. // Otherwise, it sets up the parent's bones every frame to figure out where to place
  233. // the aiment, which is inefficient because it'll setup the parent's bones even if
  234. // the parent is not in the PVS.
  235. EF_ITEM_BLINK = 0x100, // blink an item so that the user notices it.
  236. EF_PARENT_ANIMATES = 0x200, // always assume that the parent entity is animating
  237. EF_MARKED_FOR_FAST_REFLECTION = 0x400, // marks an entity for reflection rendering when using $reflectonlymarkedentities material variable
  238. EF_NOSHADOWDEPTH = 0x800, // Indicates this entity does not render into any shadow depthmap
  239. EF_SHADOWDEPTH_NOCACHE = 0x1000, // Indicates this entity cannot be cached in shadow depthmap and should render every frame
  240. EF_NOFLASHLIGHT = 0x2000,
  241. EF_NOCSM = 0x4000, // Indicates this entity does not render into the cascade shadow depthmap
  242. EF_MAX_BITS = 15
  243. };
  244. #define EF_PARITY_BITS 3
  245. #define EF_PARITY_MASK ((1<<EF_PARITY_BITS)-1)
  246. // How many bits does the muzzle flash parity thing get?
  247. #define EF_MUZZLEFLASH_BITS 2
  248. // plats
  249. #define PLAT_LOW_TRIGGER 1
  250. // Trains
  251. #define SF_TRAIN_WAIT_RETRIGGER 1
  252. #define SF_TRAIN_PASSABLE 8 // Train is not solid -- used to make water trains
  253. // view angle update types for CPlayerState::fixangle
  254. #define FIXANGLE_NONE 0
  255. #define FIXANGLE_ABSOLUTE 1
  256. #define FIXANGLE_RELATIVE 2
  257. // Break Model Defines
  258. #define BREAK_GLASS 0x01
  259. #define BREAK_METAL 0x02
  260. #define BREAK_FLESH 0x04
  261. #define BREAK_WOOD 0x08
  262. #define BREAK_SMOKE 0x10
  263. #define BREAK_TRANS 0x20
  264. #define BREAK_CONCRETE 0x40
  265. // If this is set, then we share a lighting origin with the last non-slave breakable sent down to the client
  266. #define BREAK_SLAVE 0x80
  267. // Colliding temp entity sounds
  268. #define BOUNCE_GLASS BREAK_GLASS
  269. #define BOUNCE_METAL BREAK_METAL
  270. #define BOUNCE_FLESH BREAK_FLESH
  271. #define BOUNCE_WOOD BREAK_WOOD
  272. #define BOUNCE_SHRAP 0x10
  273. #define BOUNCE_SHELL 0x20
  274. #define BOUNCE_CONCRETE BREAK_CONCRETE
  275. #define BOUNCE_SHOTSHELL 0x80
  276. // Temp entity bounce sound types
  277. #define TE_BOUNCE_NULL 0
  278. #define TE_BOUNCE_SHELL 1
  279. #define TE_BOUNCE_SHOTSHELL 2
  280. // Rendering constants
  281. // if this is changed, update common/MaterialSystem/Sprite.cpp
  282. enum RenderMode_t
  283. {
  284. kRenderNormal = 0, // src
  285. kRenderTransColor, // c*a+dest*(1-a)
  286. kRenderTransTexture, // src*a+dest*(1-a)
  287. kRenderGlow, // src*a+dest -- No Z buffer checks -- Fixed size in screen space
  288. kRenderTransAlpha, // src*srca+dest*(1-srca)
  289. kRenderTransAdd, // src*a+dest
  290. kRenderEnvironmental, // not drawn, used for environmental effects
  291. kRenderTransAddFrameBlend, // use a fractional frame value to blend between animation frames
  292. kRenderTransAlphaAdd, // src + dest*(1-a)
  293. kRenderWorldGlow, // Same as kRenderGlow but not fixed size in screen space
  294. kRenderNone, // Don't render.
  295. kRenderModeCount, // must be last
  296. };
  297. enum RenderFx_t
  298. {
  299. kRenderFxNone = 0,
  300. kRenderFxPulseSlow,
  301. kRenderFxPulseFast,
  302. kRenderFxPulseSlowWide,
  303. kRenderFxPulseFastWide,
  304. kRenderFxFadeSlow,
  305. kRenderFxFadeFast,
  306. kRenderFxSolidSlow,
  307. kRenderFxSolidFast,
  308. kRenderFxStrobeSlow,
  309. kRenderFxStrobeFast,
  310. kRenderFxStrobeFaster,
  311. kRenderFxFlickerSlow,
  312. kRenderFxFlickerFast,
  313. kRenderFxNoDissipation,
  314. kRenderFxFadeOut,
  315. kRenderFxFadeIn,
  316. kRenderFxPulseFastWider,
  317. kRenderFxGlowShell, // Glowing Shell
  318. kRenderFxMax
  319. };
  320. enum Collision_Group_t
  321. {
  322. COLLISION_GROUP_NONE = 0,
  323. COLLISION_GROUP_DEBRIS, // Collides with nothing but world and static stuff
  324. COLLISION_GROUP_DEBRIS_TRIGGER, // Same as debris, but hits triggers
  325. COLLISION_GROUP_INTERACTIVE_DEBRIS, // Collides with everything except other interactive debris or debris
  326. COLLISION_GROUP_INTERACTIVE, // Collides with everything except interactive debris or debris
  327. COLLISION_GROUP_PLAYER,
  328. COLLISION_GROUP_BREAKABLE_GLASS,
  329. COLLISION_GROUP_VEHICLE,
  330. COLLISION_GROUP_PLAYER_MOVEMENT, // For HL2, same as Collision_Group_Player, for
  331. // TF2, this filters out other players and CBaseObjects
  332. COLLISION_GROUP_NPC, // Generic NPC group
  333. COLLISION_GROUP_IN_VEHICLE, // for any entity inside a vehicle
  334. COLLISION_GROUP_WEAPON, // for any weapons that need collision detection
  335. COLLISION_GROUP_VEHICLE_CLIP, // vehicle clip brush to restrict vehicle movement
  336. COLLISION_GROUP_PROJECTILE, // Projectiles!
  337. COLLISION_GROUP_DOOR_BLOCKER, // Blocks entities not permitted to get near moving doors
  338. COLLISION_GROUP_PASSABLE_DOOR, // Doors that the player shouldn't collide with
  339. COLLISION_GROUP_DISSOLVING, // Things that are dissolving are in this group
  340. COLLISION_GROUP_PUSHAWAY, // Nonsolid on client and server, pushaway in player code
  341. COLLISION_GROUP_NPC_ACTOR, // Used so NPCs in scripts ignore the player.
  342. COLLISION_GROUP_NPC_SCRIPTED, // USed for NPCs in scripts that should not collide with each other
  343. COLLISION_GROUP_PZ_CLIP,
  344. #ifdef PORTAL2
  345. COLLISION_GROUP_CAMERA_SOLID, // Solid only to the camera's test trace
  346. COLLISION_GROUP_PLACEMENT_SOLID, // Solid only to the placement tool's test trace
  347. COLLISION_GROUP_PLAYER_HELD, // Held objects that shouldn't collide with players
  348. COLLISION_GROUP_WEIGHTED_CUBE, // Cubes need a collision group that acts roughly like COLLISION_GROUP_NONE but doesn't collide with debris or interactive
  349. #endif // PORTAL2
  350. COLLISION_GROUP_DEBRIS_BLOCK_PROJECTILE, // Only collides with bullets
  351. LAST_SHARED_COLLISION_GROUP
  352. };
  353. #include "basetypes.h"
  354. #define SOUND_NORMAL_CLIP_DIST 1000.0f
  355. // max number of cached build/draw views to support parallel building of World/Renderlists on SPU
  356. #define MAX_CONCURRENT_BUILDVIEWS 10
  357. //-----------------------------------------------------------------------------
  358. // Base light indices to avoid index collision
  359. //-----------------------------------------------------------------------------
  360. enum
  361. {
  362. LIGHT_INDEX_TE_DYNAMIC = 0x10000000,
  363. LIGHT_INDEX_PLAYER_BRIGHT = 0x20000000,
  364. LIGHT_INDEX_MUZZLEFLASH = 0x40000000,
  365. LIGHT_INDEX_LOW_PRIORITY = 0x64000000,
  366. };
  367. // How many networked area portals do we allow?
  368. #define MAX_AREA_STATE_BYTES 32
  369. #define MAX_AREA_PORTAL_STATE_BYTES 24
  370. // user message max payload size (note, this value is used by the engine, so MODs cannot change it)
  371. #define MAX_USER_MSG_BITS 12
  372. #define MAX_USER_MSG_DATA ( ( 1 << ( MAX_USER_MSG_BITS - 3 ) ) - 1 )
  373. #define MAX_ENTITY_MSG_DATA 255
  374. #define SOURCE_MT
  375. #ifdef SOURCE_MT
  376. class CThreadMutex;
  377. typedef CThreadMutex CSourceMutex;
  378. #else
  379. class CThreadNullMutex;
  380. typedef CThreadNullMutex CSourceMutex;
  381. #endif
  382. #if defined( CLIENT_DLL )
  383. #define IsServerDll() false
  384. #define IsClientDll() true
  385. #elif defined( GAME_DLL )
  386. #define IsServerDll() true
  387. #define IsClientDll() false
  388. #else
  389. #define IsServerDll() false
  390. #define IsClientDll() false
  391. #endif
  392. #endif
  393. #define IsValveDedicated() false