Team Fortress 2 Source Code as on 22/4/2020
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.

2815 lines
94 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // NOTE: Inserting to most or all of the enums in this file will BREAK DEMOS -
  4. // please add to the end instead.
  5. //
  6. //=============================================================================
  7. #ifndef TF_SHAREDDEFS_H
  8. #define TF_SHAREDDEFS_H
  9. #ifdef _WIN32
  10. #pragma once
  11. #endif
  12. #include "shareddefs.h"
  13. #include "mp_shareddefs.h"
  14. #include "tf_matchmaking_shared.h"
  15. // Using MAP_DEBUG mode?
  16. #ifdef MAP_DEBUG
  17. #define MDEBUG(x) x
  18. #else
  19. #define MDEBUG(x)
  20. #endif
  21. #define MAX_MVM_WAVE_STRING 256
  22. //-----------------------------------------------------------------------------
  23. // Teams.
  24. //-----------------------------------------------------------------------------
  25. enum
  26. {
  27. TF_TEAM_RED = LAST_SHARED_TEAM+1,
  28. TF_TEAM_BLUE,
  29. TF_TEAM_COUNT
  30. };
  31. #define TF_TEAM_AUTOASSIGN (TF_TEAM_COUNT + 1 )
  32. #define TF_TEAM_HALLOWEEN TF_TEAM_AUTOASSIGN
  33. #define TF_TEAM_PVE_INVADERS TF_TEAM_BLUE // invading bot team in mann vs machine
  34. #define TF_TEAM_PVE_DEFENDERS TF_TEAM_RED // defending player team in mann vs machine
  35. #define TF_TEAM_PVE_INVADERS_GIANTS 4 // hack for replacing visuals via itemdef
  36. extern const char *g_aTeamNames[TF_TEAM_COUNT];
  37. extern color32 g_aTeamColors[TF_TEAM_COUNT];
  38. #define COLOR_TF_SPECTATOR Color( 245, 229, 196, 255 )
  39. #define COLOR_TF_RED Color( 175, 73, 73, 255 )
  40. #define COLOR_TF_BLUE Color( 79, 117, 143, 255 )
  41. #define CONTENTS_REDTEAM CONTENTS_TEAM1
  42. #define CONTENTS_BLUETEAM CONTENTS_TEAM2
  43. enum
  44. {
  45. TF_ARENA_NOTIFICATION_CAREFUL = 0,
  46. TF_ARENA_NOTIFICATION_SITOUT,
  47. TF_ARENA_NOTIFICATION_NOPLAYERS,
  48. };
  49. // Team roles
  50. enum
  51. {
  52. TEAM_ROLE_NONE = 0,
  53. TEAM_ROLE_DEFENDERS,
  54. TEAM_ROLE_ATTACKERS,
  55. NUM_TEAM_ROLES,
  56. };
  57. enum HalloweenBossType
  58. {
  59. HALLOWEEN_BOSS_INVALID = 0,
  60. HALLOWEEN_BOSS_HHH = 1,
  61. HALLOWEEN_BOSS_MONOCULUS = 2,
  62. HALLOWEEN_BOSS_MERASMUS = 3,
  63. };
  64. // common utility
  65. inline int GetEnemyTeam( int team )
  66. {
  67. if ( team == TF_TEAM_RED )
  68. return TF_TEAM_BLUE;
  69. if ( team == TF_TEAM_BLUE )
  70. return TF_TEAM_RED;
  71. // no enemy team
  72. return team;
  73. }
  74. // Is this a active in-game team, vs spectator/unassigned/special-values/etc.
  75. inline bool BIsGameTeam( int team )
  76. {
  77. return team >= FIRST_GAME_TEAM;
  78. }
  79. inline bool BAreTeamsEnemies( int team, int otherTeam )
  80. {
  81. // Right now all game teams are enemies in TF -- We may want to change this in the future for special mechanics/etc.
  82. return BIsGameTeam( team ) && BIsGameTeam( otherTeam ) && team != otherTeam;
  83. }
  84. enum PowerupBottleType_t
  85. {
  86. POWERUP_BOTTLE_NONE,
  87. POWERUP_BOTTLE_CRITBOOST,
  88. POWERUP_BOTTLE_UBERCHARGE,
  89. POWERUP_BOTTLE_RECALL,
  90. POWERUP_BOTTLE_REFILL_AMMO,
  91. POWERUP_BOTTLE_BUILDINGS_INSTANT_UPGRADE,
  92. POWERUP_BOTTLE_RADIUS_STEALTH,
  93. #ifdef STAGING_ONLY
  94. POWERUP_BOTTLE_SEE_CASH_THROUGH_WALL,
  95. #endif
  96. POWERUP_BOTTLE_TOTAL
  97. };
  98. enum
  99. {
  100. MVM_EVENT_POPFILE_NONE = 0,
  101. MVM_EVENT_POPFILE_HALLOWEEN,
  102. MVM_EVENT_POPFILE_MAX_TYPES,
  103. };
  104. enum
  105. {
  106. DRAW_ARROW_UP,
  107. DRAW_ARROW_LEFT,
  108. DRAW_ARROW_RIGHT
  109. };
  110. //-----------------------------------------------------------------------------
  111. // CVar replacements
  112. //-----------------------------------------------------------------------------
  113. #define TF_DAMAGE_CRIT_CHANCE 0.02f
  114. #define TF_DAMAGE_CRIT_CHANCE_RAPID 0.02f
  115. #define TF_DAMAGE_CRIT_DURATION_RAPID 2.0f
  116. #define TF_DAMAGE_CRIT_CHANCE_MELEE 0.15f
  117. #define TF_DAMAGE_CRITMOD_MAXTIME 20
  118. #define TF_DAMAGE_CRITMOD_MINTIME 2
  119. #define TF_DAMAGE_CRITMOD_DAMAGE 800
  120. #define TF_DAMAGE_CRITMOD_MAXMULT 6
  121. #define TF_DAMAGE_CRIT_MULTIPLIER 3.0f
  122. #define TF_DAMAGE_MINICRIT_MULTIPLIER 1.35f
  123. //-----------------------------------------------------------------------------
  124. // TF-specific viewport panels
  125. //-----------------------------------------------------------------------------
  126. #define PANEL_CLASS_BLUE "class_blue"
  127. #define PANEL_CLASS_RED "class_red"
  128. #define PANEL_MAPINFO "mapinfo"
  129. #define PANEL_ROUNDINFO "roundinfo"
  130. #define PANEL_CHARACTER_INFO "character_info"
  131. #define PANEL_ARENA_WIN "arenawinpanel"
  132. #define PANEL_ARENA_TEAM "arenateampanel"
  133. #define PANEL_PVE_WIN "pvewinpanel"
  134. #define PANEL_GIVEAWAY_ITEM "giveaway_item"
  135. #define PANEL_MAINMENUOVERRIDE "MainMenuOverride"
  136. #define PANEL_QUEST_LOG "QuestLog"
  137. // file we'll save our list of viewed intro movies in
  138. #define MOVIES_FILE "viewed.res"
  139. #define TF_WEAPON_TAUNT_FRONTIER_JUSTICE_GUITAR_MODEL "models/player/items/engineer/guitar.mdl"
  140. //-----------------------------------------------------------------------------
  141. // Used in calculating the health percentage of a player
  142. //-----------------------------------------------------------------------------
  143. #define TF_HEALTH_UNDEFINED 1
  144. //-----------------------------------------------------------------------------
  145. // Used to mark a spy's disguise attribute (team or class) as "unused"
  146. //-----------------------------------------------------------------------------
  147. #define TF_SPY_UNDEFINED TEAM_UNASSIGNED
  148. //-----------------------------------------------------------------------------
  149. // Player Classes.
  150. //-----------------------------------------------------------------------------
  151. #define TF_CLASS_COUNT ( TF_CLASS_COUNT_ALL )
  152. #define TF_FIRST_NORMAL_CLASS ( TF_CLASS_UNDEFINED + 1 )
  153. #define TF_LAST_NORMAL_CLASS ( TF_CLASS_CIVILIAN )
  154. #define TF_CLASS_MENU_BUTTONS ( TF_CLASS_RANDOM + 1 )
  155. enum
  156. {
  157. TF_CLASS_UNDEFINED = 0,
  158. TF_CLASS_SCOUT, // TF_FIRST_NORMAL_CLASS
  159. TF_CLASS_SNIPER,
  160. TF_CLASS_SOLDIER,
  161. TF_CLASS_DEMOMAN,
  162. TF_CLASS_MEDIC,
  163. TF_CLASS_HEAVYWEAPONS,
  164. TF_CLASS_PYRO,
  165. TF_CLASS_SPY,
  166. TF_CLASS_ENGINEER,
  167. // Add any new classes after Engineer
  168. TF_CLASS_CIVILIAN, // TF_LAST_NORMAL_CLASS
  169. TF_CLASS_COUNT_ALL,
  170. TF_CLASS_RANDOM
  171. };
  172. inline bool IsValidTFPlayerClass( int iClass ) { return iClass >= TF_FIRST_NORMAL_CLASS && iClass < TF_LAST_NORMAL_CLASS; }
  173. inline bool IsValidTFTeam( int iTeam ) { return iTeam == TF_TEAM_RED || iTeam == TF_TEAM_BLUE; }
  174. #define FOR_EACH_NORMAL_PLAYER_CLASS( _i ) for ( int _i = TF_FIRST_NORMAL_CLASS; _i < TF_LAST_NORMAL_CLASS; _i++ )
  175. extern const char *g_aPlayerClassNames[TF_CLASS_MENU_BUTTONS]; // localization keys
  176. extern const char *g_aPlayerClassNames_NonLocalized[TF_CLASS_MENU_BUTTONS]; // non-localized class names
  177. extern const char *g_aRawPlayerClassNamesShort[TF_CLASS_MENU_BUTTONS]; // raw class names, useful for formatting resource/material filenames - "heavy" instead of "heavyweapons" and "demo" instead of "demoman"
  178. extern const char *g_aRawPlayerClassNames[TF_CLASS_MENU_BUTTONS]; // raw class names, useful for formatting resource/material filenames
  179. extern const char g_szPlayerRobotModels[TF_LAST_NORMAL_CLASS][ MAX_PATH ];
  180. extern const char g_szBotModels[TF_LAST_NORMAL_CLASS][ MAX_PATH ];
  181. extern const char g_szBotBossModels[TF_LAST_NORMAL_CLASS][ MAX_PATH ];
  182. extern const char g_szBotBossSentryBusterModel[ MAX_PATH ];
  183. extern const char g_szRomePromoItems_Hat[TF_LAST_NORMAL_CLASS][ MAX_PATH ];
  184. extern const char g_szRomePromoItems_Misc[TF_LAST_NORMAL_CLASS][ MAX_PATH ];
  185. int GetClassIndexFromString( const char *pClassName, int nLastClassIndex = TF_LAST_NORMAL_CLASS );
  186. // menu buttons are not in the same order as the defines
  187. extern int iRemapIndexToClass[TF_CLASS_MENU_BUTTONS];
  188. int GetRemappedMenuIndexForClass( int iClass );
  189. extern const char *g_pszBreadModels[];
  190. //-----------------------------------------------------------------------------
  191. // For entity_capture_flags to use when placed in the world
  192. // NOTE: Inserting to most or all of the enums in this file will BREAK DEMOS -
  193. // please add to the end instead.
  194. //-----------------------------------------------------------------------------
  195. enum ETFFlagType
  196. {
  197. TF_FLAGTYPE_CTF = 0,
  198. TF_FLAGTYPE_ATTACK_DEFEND,
  199. TF_FLAGTYPE_TERRITORY_CONTROL,
  200. TF_FLAGTYPE_INVADE,
  201. TF_FLAGTYPE_RESOURCE_CONTROL,
  202. TF_FLAGTYPE_ROBOT_DESTRUCTION,
  203. TF_FLAGTYPE_PLAYER_DESTRUCTION
  204. //
  205. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  206. //
  207. };
  208. //-----------------------------------------------------------------------------
  209. // For the game rules to determine which type of game we're playing
  210. //
  211. // NOTE: Inserting to most or all of the enums in this file will BREAK DEMOS -
  212. // please add to the end instead.
  213. //-----------------------------------------------------------------------------
  214. enum ETFGameType
  215. {
  216. TF_GAMETYPE_UNDEFINED = 0,
  217. TF_GAMETYPE_CTF,
  218. TF_GAMETYPE_CP,
  219. TF_GAMETYPE_ESCORT,
  220. TF_GAMETYPE_ARENA,
  221. TF_GAMETYPE_MVM,
  222. TF_GAMETYPE_RD,
  223. TF_GAMETYPE_PASSTIME,
  224. TF_GAMETYPE_PD,
  225. //
  226. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  227. //
  228. TF_GAMETYPE_COUNT
  229. };
  230. const char *GetGameTypeName( ETFGameType gameType );
  231. const char *GetEnumGameTypeName( ETFGameType gameType );
  232. ETFGameType GetGameTypeFromName( const char *pszGameType );
  233. //=============================================================================
  234. // HPE_BEGIN:
  235. // [msmith] Added a HUD type so that we can have the hud independent from the
  236. // game type. This is useful in training where we want a training hud
  237. // Instead of the other types of HUD.
  238. //=============================================================================
  239. enum
  240. {
  241. TF_HUDTYPE_UNDEFINED = 0,
  242. TF_HUDTYPE_CTF,
  243. TF_HUDTYPE_CP,
  244. TF_HUDTYPE_ESCORT,
  245. TF_HUDTYPE_ARENA,
  246. TF_HUDTYPE_TRAINING,
  247. //
  248. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  249. //
  250. };
  251. //=============================================================================
  252. // HPE_END
  253. //=============================================================================
  254. //-----------------------------------------------------------------------------
  255. // Buildings.
  256. //-----------------------------------------------------------------------------
  257. enum
  258. {
  259. TF_BUILDING_SENTRY = (1<<0),
  260. TF_BUILDING_DISPENSER = (1<<1),
  261. TF_BUILDING_TELEPORT = (1<<2),
  262. //
  263. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  264. //
  265. };
  266. //-----------------------------------------------------------------------------
  267. // Items.
  268. //-----------------------------------------------------------------------------
  269. enum
  270. {
  271. TF_ITEM_UNDEFINED = 0,
  272. TF_ITEM_CAPTURE_FLAG = (1<<0),
  273. TF_ITEM_HEALTH_KIT = (1<<1),
  274. TF_ITEM_ARMOR = (1<<2),
  275. TF_ITEM_AMMO_PACK = (1<<3),
  276. TF_ITEM_GRENADE_PACK = (1<<4),
  277. //
  278. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  279. //
  280. };
  281. //-----------------------------------------------------------------------------
  282. // Ammo.
  283. //-----------------------------------------------------------------------------
  284. enum ETFAmmoType
  285. {
  286. TF_AMMO_DUMMY = 0, // Dummy index to make the CAmmoDef indices correct for the other ammo types.
  287. TF_AMMO_PRIMARY,
  288. TF_AMMO_SECONDARY,
  289. TF_AMMO_METAL,
  290. TF_AMMO_GRENADES1,
  291. TF_AMMO_GRENADES2,
  292. TF_AMMO_GRENADES3, // Utility Slot Grenades
  293. TF_AMMO_COUNT,
  294. //
  295. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  296. //
  297. };
  298. const char *GetAmmoName( int iAmmoType );
  299. //-----------------------------------------------------------------------------
  300. // Weapons.
  301. //-----------------------------------------------------------------------------
  302. #define TF_PLAYER_WEAPON_COUNT 6
  303. #define TF_PLAYER_GRENADE_COUNT 2
  304. #define TF_PLAYER_BUILDABLE_COUNT 3
  305. #define TF_PLAYER_BLUEPRINT_COUNT 6
  306. #define TF_WEAPON_PRIMARY_MODE 0
  307. #define TF_WEAPON_SECONDARY_MODE 1
  308. #define TF_WEAPON_GRENADE_FRICTION 0.6f
  309. #define TF_WEAPON_GRENADE_GRAVITY 0.81f
  310. #define TF_WEAPON_GRENADE_INITPRIME 0.8f
  311. #define TF_WEAPON_GRENADE_CONCUSSION_TIME 15.0f
  312. #define TF_WEAPON_GRENADE_MIRV_BOMB_COUNT 4
  313. #define TF_WEAPON_GRENADE_CALTROP_TIME 8.0f
  314. #define TF_WEAPON_PIPEBOMB_WORLD_COUNT 15
  315. #define TF_WEAPON_PIPEBOMB_COUNT 8
  316. #define TF_WEAPON_PIPEBOMB_INTERVAL 0.6f
  317. #define TF_WEAPON_ROCKET_INTERVAL 0.8f
  318. #define TF_WEAPON_FLAMETHROWER_INTERVAL 0.15f
  319. #define TF_WEAPON_FLAMETHROWER_ROCKET_INTERVAL 0.8f
  320. #define TF_WEAPON_ZOOM_FOV 20
  321. //
  322. // NOTE: Inserting to most or all of the enums in this file will BREAK DEMOS -
  323. // please add to the end instead.
  324. //
  325. enum ETFWeaponType
  326. {
  327. TF_WEAPON_NONE = 0,
  328. TF_WEAPON_BAT,
  329. TF_WEAPON_BAT_WOOD,
  330. TF_WEAPON_BOTTLE,
  331. TF_WEAPON_FIREAXE,
  332. TF_WEAPON_CLUB,
  333. TF_WEAPON_CROWBAR,
  334. TF_WEAPON_KNIFE,
  335. TF_WEAPON_FISTS,
  336. TF_WEAPON_SHOVEL,
  337. TF_WEAPON_WRENCH,
  338. TF_WEAPON_BONESAW,
  339. TF_WEAPON_SHOTGUN_PRIMARY,
  340. TF_WEAPON_SHOTGUN_SOLDIER,
  341. TF_WEAPON_SHOTGUN_HWG,
  342. TF_WEAPON_SHOTGUN_PYRO,
  343. TF_WEAPON_SCATTERGUN,
  344. TF_WEAPON_SNIPERRIFLE,
  345. TF_WEAPON_MINIGUN,
  346. TF_WEAPON_SMG,
  347. TF_WEAPON_SYRINGEGUN_MEDIC,
  348. TF_WEAPON_TRANQ,
  349. TF_WEAPON_ROCKETLAUNCHER,
  350. TF_WEAPON_GRENADELAUNCHER,
  351. TF_WEAPON_PIPEBOMBLAUNCHER,
  352. TF_WEAPON_FLAMETHROWER,
  353. TF_WEAPON_GRENADE_NORMAL,
  354. TF_WEAPON_GRENADE_CONCUSSION,
  355. TF_WEAPON_GRENADE_NAIL,
  356. TF_WEAPON_GRENADE_MIRV,
  357. TF_WEAPON_GRENADE_MIRV_DEMOMAN,
  358. TF_WEAPON_GRENADE_NAPALM,
  359. TF_WEAPON_GRENADE_GAS,
  360. TF_WEAPON_GRENADE_EMP,
  361. TF_WEAPON_GRENADE_CALTROP,
  362. TF_WEAPON_GRENADE_PIPEBOMB,
  363. TF_WEAPON_GRENADE_SMOKE_BOMB,
  364. TF_WEAPON_GRENADE_HEAL,
  365. TF_WEAPON_GRENADE_STUNBALL,
  366. TF_WEAPON_GRENADE_JAR,
  367. TF_WEAPON_GRENADE_JAR_MILK,
  368. TF_WEAPON_PISTOL,
  369. TF_WEAPON_PISTOL_SCOUT,
  370. TF_WEAPON_REVOLVER,
  371. TF_WEAPON_NAILGUN,
  372. TF_WEAPON_PDA,
  373. TF_WEAPON_PDA_ENGINEER_BUILD,
  374. TF_WEAPON_PDA_ENGINEER_DESTROY,
  375. TF_WEAPON_PDA_SPY,
  376. TF_WEAPON_BUILDER,
  377. TF_WEAPON_MEDIGUN,
  378. TF_WEAPON_GRENADE_MIRVBOMB,
  379. TF_WEAPON_FLAMETHROWER_ROCKET,
  380. TF_WEAPON_GRENADE_DEMOMAN,
  381. TF_WEAPON_SENTRY_BULLET,
  382. TF_WEAPON_SENTRY_ROCKET,
  383. TF_WEAPON_DISPENSER,
  384. TF_WEAPON_INVIS,
  385. TF_WEAPON_FLAREGUN,
  386. TF_WEAPON_LUNCHBOX,
  387. TF_WEAPON_JAR,
  388. TF_WEAPON_COMPOUND_BOW,
  389. TF_WEAPON_BUFF_ITEM,
  390. TF_WEAPON_PUMPKIN_BOMB,
  391. TF_WEAPON_SWORD,
  392. TF_WEAPON_ROCKETLAUNCHER_DIRECTHIT,
  393. TF_WEAPON_LIFELINE,
  394. TF_WEAPON_LASER_POINTER,
  395. TF_WEAPON_DISPENSER_GUN,
  396. TF_WEAPON_SENTRY_REVENGE,
  397. TF_WEAPON_JAR_MILK,
  398. TF_WEAPON_HANDGUN_SCOUT_PRIMARY,
  399. TF_WEAPON_BAT_FISH,
  400. TF_WEAPON_CROSSBOW,
  401. TF_WEAPON_STICKBOMB,
  402. TF_WEAPON_HANDGUN_SCOUT_SECONDARY,
  403. TF_WEAPON_SODA_POPPER,
  404. TF_WEAPON_SNIPERRIFLE_DECAP,
  405. TF_WEAPON_RAYGUN,
  406. TF_WEAPON_PARTICLE_CANNON,
  407. TF_WEAPON_MECHANICAL_ARM,
  408. TF_WEAPON_DRG_POMSON,
  409. TF_WEAPON_BAT_GIFTWRAP,
  410. TF_WEAPON_GRENADE_ORNAMENT_BALL,
  411. TF_WEAPON_FLAREGUN_REVENGE,
  412. TF_WEAPON_PEP_BRAWLER_BLASTER,
  413. TF_WEAPON_CLEAVER,
  414. TF_WEAPON_GRENADE_CLEAVER,
  415. TF_WEAPON_STICKY_BALL_LAUNCHER,
  416. TF_WEAPON_GRENADE_STICKY_BALL,
  417. TF_WEAPON_SHOTGUN_BUILDING_RESCUE,
  418. TF_WEAPON_CANNON,
  419. TF_WEAPON_THROWABLE,
  420. TF_WEAPON_GRENADE_THROWABLE,
  421. TF_WEAPON_PDA_SPY_BUILD,
  422. TF_WEAPON_GRENADE_WATERBALLOON,
  423. TF_WEAPON_HARVESTER_SAW,
  424. TF_WEAPON_SPELLBOOK,
  425. TF_WEAPON_SPELLBOOK_PROJECTILE,
  426. TF_WEAPON_SNIPERRIFLE_CLASSIC,
  427. TF_WEAPON_PARACHUTE,
  428. TF_WEAPON_GRAPPLINGHOOK,
  429. TF_WEAPON_PASSTIME_GUN,
  430. #ifdef STAGING_ONLY
  431. TF_WEAPON_SNIPERRIFLE_REVOLVER,
  432. #endif
  433. TF_WEAPON_CHARGED_SMG,
  434. //
  435. // ADD NEW WEAPONS HERE TO AVOID BREAKING DEMOS
  436. //
  437. TF_WEAPON_COUNT
  438. };
  439. extern const char *g_aWeaponNames[TF_WEAPON_COUNT];
  440. extern int g_aWeaponDamageTypes[TF_WEAPON_COUNT];
  441. int GetWeaponId( const char *pszWeaponName );
  442. #ifdef GAME_DLL
  443. int GetWeaponFromDamage( const CTakeDamageInfo &info );
  444. #endif
  445. int GetBuildableId( const char *pszBuildableName );
  446. const char *WeaponIdToAlias( int iWeapon );
  447. // Only TF specific classes that derives from CBaseProjectile should OVERRIDE GetBaseProjectileType()
  448. enum BaseProjectileType_t
  449. {
  450. TF_BASE_PROJECTILE_GRENADE, // CTFWeaponBaseGrenadeProj
  451. // add new entries here!
  452. };
  453. // Item definitions look into this array by hard-coded indices, so do not add entries
  454. // anywhere except the end!
  455. enum ProjectileType_t
  456. {
  457. TF_PROJECTILE_NONE,
  458. TF_PROJECTILE_BULLET,
  459. TF_PROJECTILE_ROCKET,
  460. TF_PROJECTILE_PIPEBOMB,
  461. TF_PROJECTILE_PIPEBOMB_REMOTE,
  462. TF_PROJECTILE_SYRINGE,
  463. TF_PROJECTILE_FLARE,
  464. TF_PROJECTILE_JAR,
  465. TF_PROJECTILE_ARROW,
  466. TF_PROJECTILE_FLAME_ROCKET,
  467. TF_PROJECTILE_JAR_MILK,
  468. TF_PROJECTILE_HEALING_BOLT,
  469. TF_PROJECTILE_ENERGY_BALL,
  470. TF_PROJECTILE_ENERGY_RING,
  471. TF_PROJECTILE_PIPEBOMB_PRACTICE,
  472. TF_PROJECTILE_CLEAVER,
  473. TF_PROJECTILE_STICKY_BALL,
  474. TF_PROJECTILE_CANNONBALL,
  475. TF_PROJECTILE_BUILDING_REPAIR_BOLT,
  476. TF_PROJECTILE_FESTIVE_ARROW,
  477. TF_PROJECTILE_THROWABLE,
  478. TF_PROJECTILE_SPELL,
  479. TF_PROJECTILE_FESTIVE_JAR,
  480. TF_PROJECTILE_FESTIVE_HEALING_BOLT,
  481. TF_PROJECTILE_BREADMONSTER_JARATE,
  482. TF_PROJECTILE_BREADMONSTER_MADMILK,
  483. TF_PROJECTILE_GRAPPLINGHOOK,
  484. TF_PROJECTILE_SENTRY_ROCKET,
  485. TF_PROJECTILE_BREAD_MONSTER,
  486. #ifdef STAGING_ONLY
  487. // STAGING ONLY
  488. TF_PROJECTILE_TRANQ,
  489. TF_PROJECTILE_SNIPERBULLET,
  490. TF_PROJECTILE_THROWING_KNIFE,
  491. TF_PROJECTILE_GRENADE_CONCUSSION,
  492. TF_PROJECTILE_GRENADE_TELEPORT,
  493. TF_PROJECTILE_MILK_BOLT,
  494. #endif
  495. // Add new entries here!
  496. TF_NUM_PROJECTILES
  497. };
  498. extern const char *g_szProjectileNames[];
  499. enum medigun_charge_types
  500. {
  501. MEDIGUN_CHARGE_INVALID = -1,
  502. MEDIGUN_CHARGE_INVULN = 0,
  503. MEDIGUN_CHARGE_CRITICALBOOST,
  504. MEDIGUN_CHARGE_MEGAHEAL,
  505. MEDIGUN_CHARGE_BULLET_RESIST,
  506. MEDIGUN_CHARGE_BLAST_RESIST,
  507. MEDIGUN_CHARGE_FIRE_RESIST,
  508. MEDIGUN_NUM_CHARGE_TYPES,
  509. };
  510. enum arrow_models
  511. {
  512. MODEL_ARROW_REGULAR,
  513. MODEL_ARROW_BUILDING_REPAIR,
  514. MODEL_SNOWBALL,
  515. MODEL_FESTIVE_ARROW_REGULAR,
  516. MODEL_SYRINGE,
  517. MODEL_FESTIVE_HEALING_BOLT,
  518. MODEL_BREAD_MONSTER,
  519. MODEL_GRAPPLINGHOOK,
  520. // Staging
  521. MODEL_THROWING_KNIFE,
  522. TF_ARROW_MODEL_COUNT
  523. };
  524. extern const char *g_pszArrowModels[];
  525. //-----------------------------------------------------------------------------
  526. // Dead Calling Cards
  527. //-----------------------------------------------------------------------------
  528. enum death_calling_card_models
  529. {
  530. CALLING_CARD_NONE = 0, // Empty at zero
  531. CALLING_CARD_MILKMAN = 1, // Scout PolyCount Set
  532. CALLING_CARD_CROC, // Sniper PolyCount Set
  533. CALLING_CARD_TANKBUSTER, // Solider PolyCount Set
  534. CALLING_CARD_GASJOCKEY, // Pyro PolyCount Set
  535. TF_CALLING_CARD_MODEL_COUNT
  536. };
  537. extern const char *g_pszDeathCallingCardModels[TF_CALLING_CARD_MODEL_COUNT];
  538. #ifdef TF_CLIENT_DLL
  539. extern const char *g_pszInvasionMaps[];
  540. bool IsPlayingInvasionMap( void );
  541. #define SCOREBOARD_DOMINATION_ICONS 17
  542. #define SCOREBOARD_CLASS_ICONS 19
  543. #define SCOREBOARD_PING_ICONS 6
  544. extern const char *g_pszClassIcons[];
  545. extern const char *g_pszClassIconsAlt[];
  546. extern const char *g_pszCompetitiveMedalImages[];
  547. extern const char *g_pszItemClassImagesRed[];
  548. extern const char *g_pszItemClassImagesBlue[];
  549. #endif // TF_CLIENT_DLL
  550. //-----------------------------------------------------------------------------
  551. // Attributes.
  552. //-----------------------------------------------------------------------------
  553. #define TF_PLAYER_VIEW_OFFSET Vector( 0, 0, 64.0 ) //--> see GetViewVectors()
  554. //-----------------------------------------------------------------------------
  555. // TF Player Condition.
  556. //-----------------------------------------------------------------------------
  557. // Burning
  558. #define TF_BURNING_FREQUENCY 0.5f
  559. #define TF_BURNING_FLAME_LIFE 10.0
  560. #define TF_BURNING_FLAME_LIFE_PYRO 0.25 // pyro only displays burning effect momentarily
  561. #define TF_BURNING_FLAME_LIFE_FLARE 10.0
  562. #define TF_BURNING_FLAME_LIFE_PLASMA 6.0
  563. #define TF_BURNING_DMG 3
  564. // Bleeding
  565. #define TF_BLEEDING_FREQUENCY 0.5f
  566. #define TF_BLEEDING_DMG 4
  567. // disguising
  568. #define TF_TIME_TO_DISGUISE 2.0f
  569. #define TF_TIME_TO_QUICK_DISGUISE 0.5f
  570. #define TF_TIME_TO_SHOW_DISGUISED_FINISHED_EFFECT 5.0
  571. // phasing
  572. #define TF_SCOUT_NUMBEROFPHASEATTACHMENTS 5
  573. #define SHOW_DISGUISE_EFFECT 1
  574. #define TF_DISGUISE_TARGET_INDEX_NONE ( MAX_PLAYERS + 1 )
  575. #define TF_PLAYER_INDEX_NONE ( MAX_PLAYERS + 1 )
  576. //
  577. // ADD NEW WEAPONS HERE TO AVOID BREAKING DEMOS
  578. //
  579. enum ETFCond
  580. {
  581. TF_COND_INVALID = -1,
  582. TF_COND_AIMING = 0, // Sniper aiming, Heavy minigun.
  583. TF_COND_ZOOMED,
  584. TF_COND_DISGUISING,
  585. TF_COND_DISGUISED,
  586. TF_COND_STEALTHED, // Spy specific
  587. TF_COND_INVULNERABLE,
  588. TF_COND_TELEPORTED,
  589. TF_COND_TAUNTING,
  590. TF_COND_INVULNERABLE_WEARINGOFF,
  591. TF_COND_STEALTHED_BLINK,
  592. TF_COND_SELECTED_TO_TELEPORT,
  593. TF_COND_CRITBOOSTED, // DO NOT RE-USE THIS -- THIS IS FOR KRITZKRIEG AND REVENGE CRITS ONLY
  594. TF_COND_TMPDAMAGEBONUS,
  595. TF_COND_FEIGN_DEATH,
  596. TF_COND_PHASE,
  597. TF_COND_STUNNED, // Any type of stun. Check iStunFlags for more info.
  598. TF_COND_OFFENSEBUFF,
  599. TF_COND_SHIELD_CHARGE,
  600. TF_COND_DEMO_BUFF,
  601. TF_COND_ENERGY_BUFF,
  602. TF_COND_RADIUSHEAL,
  603. TF_COND_HEALTH_BUFF,
  604. TF_COND_BURNING,
  605. TF_COND_HEALTH_OVERHEALED,
  606. TF_COND_URINE,
  607. TF_COND_BLEEDING,
  608. TF_COND_DEFENSEBUFF, // 35% defense! No crit damage.
  609. TF_COND_MAD_MILK,
  610. TF_COND_MEGAHEAL,
  611. TF_COND_REGENONDAMAGEBUFF,
  612. TF_COND_MARKEDFORDEATH,
  613. TF_COND_NOHEALINGDAMAGEBUFF,
  614. TF_COND_SPEED_BOOST, // = 32
  615. TF_COND_CRITBOOSTED_PUMPKIN, // Brandon hates bits
  616. TF_COND_CRITBOOSTED_USER_BUFF,
  617. TF_COND_CRITBOOSTED_DEMO_CHARGE,
  618. TF_COND_SODAPOPPER_HYPE,
  619. TF_COND_CRITBOOSTED_FIRST_BLOOD, // arena mode first blood
  620. TF_COND_CRITBOOSTED_BONUS_TIME,
  621. TF_COND_CRITBOOSTED_CTF_CAPTURE,
  622. TF_COND_CRITBOOSTED_ON_KILL, // =40. KGB, etc.
  623. TF_COND_CANNOT_SWITCH_FROM_MELEE,
  624. TF_COND_DEFENSEBUFF_NO_CRIT_BLOCK, // 35% defense! Still damaged by crits.
  625. TF_COND_REPROGRAMMED, // Bots only
  626. TF_COND_CRITBOOSTED_RAGE_BUFF,
  627. TF_COND_DEFENSEBUFF_HIGH, // 75% defense! Still damaged by crits.
  628. TF_COND_SNIPERCHARGE_RAGE_BUFF, // Sniper Rage - Charge time speed up
  629. TF_COND_DISGUISE_WEARINGOFF, // Applied for half-second post-disguise
  630. TF_COND_MARKEDFORDEATH_SILENT, // Sans sound
  631. TF_COND_DISGUISED_AS_DISPENSER,
  632. TF_COND_SAPPED, // =50. Bots only
  633. TF_COND_INVULNERABLE_HIDE_UNLESS_DAMAGED,
  634. TF_COND_INVULNERABLE_USER_BUFF,
  635. TF_COND_HALLOWEEN_BOMB_HEAD,
  636. TF_COND_HALLOWEEN_THRILLER,
  637. TF_COND_RADIUSHEAL_ON_DAMAGE,
  638. TF_COND_CRITBOOSTED_CARD_EFFECT,
  639. TF_COND_INVULNERABLE_CARD_EFFECT,
  640. TF_COND_MEDIGUN_UBER_BULLET_RESIST,
  641. TF_COND_MEDIGUN_UBER_BLAST_RESIST,
  642. TF_COND_MEDIGUN_UBER_FIRE_RESIST, // =60
  643. TF_COND_MEDIGUN_SMALL_BULLET_RESIST,
  644. TF_COND_MEDIGUN_SMALL_BLAST_RESIST,
  645. TF_COND_MEDIGUN_SMALL_FIRE_RESIST,
  646. TF_COND_STEALTHED_USER_BUFF, // Any class can have this
  647. TF_COND_MEDIGUN_DEBUFF,
  648. TF_COND_STEALTHED_USER_BUFF_FADING,
  649. TF_COND_BULLET_IMMUNE,
  650. TF_COND_BLAST_IMMUNE,
  651. TF_COND_FIRE_IMMUNE,
  652. TF_COND_PREVENT_DEATH, // =70
  653. TF_COND_MVM_BOT_STUN_RADIOWAVE, // Bots only
  654. TF_COND_HALLOWEEN_SPEED_BOOST,
  655. TF_COND_HALLOWEEN_QUICK_HEAL,
  656. TF_COND_HALLOWEEN_GIANT,
  657. TF_COND_HALLOWEEN_TINY,
  658. TF_COND_HALLOWEEN_IN_HELL,
  659. TF_COND_HALLOWEEN_GHOST_MODE, // =77
  660. TF_COND_MINICRITBOOSTED_ON_KILL,
  661. TF_COND_OBSCURED_SMOKE,
  662. TF_COND_PARACHUTE_DEPLOYED, // =80
  663. TF_COND_BLASTJUMPING,
  664. TF_COND_HALLOWEEN_KART,
  665. TF_COND_HALLOWEEN_KART_DASH,
  666. TF_COND_BALLOON_HEAD, // =84 larger head, lower-gravity-feeling jumps
  667. TF_COND_MELEE_ONLY, // =85 melee only
  668. TF_COND_SWIMMING_CURSE, // player movement become swimming movement
  669. TF_COND_FREEZE_INPUT, // freezes player input
  670. TF_COND_HALLOWEEN_KART_CAGE, // attach cage model to player while in kart
  671. TF_COND_DONOTUSE_0,
  672. TF_COND_RUNE_STRENGTH,
  673. TF_COND_RUNE_HASTE,
  674. TF_COND_RUNE_REGEN,
  675. TF_COND_RUNE_RESIST,
  676. TF_COND_RUNE_VAMPIRE,
  677. TF_COND_RUNE_REFLECT,
  678. TF_COND_RUNE_PRECISION,
  679. TF_COND_RUNE_AGILITY,
  680. TF_COND_GRAPPLINGHOOK,
  681. TF_COND_GRAPPLINGHOOK_SAFEFALL,
  682. TF_COND_GRAPPLINGHOOK_LATCHED,
  683. TF_COND_GRAPPLINGHOOK_BLEEDING,
  684. TF_COND_AFTERBURN_IMMUNE,
  685. TF_COND_RUNE_KNOCKOUT,
  686. TF_COND_RUNE_IMBALANCE,
  687. TF_COND_CRITBOOSTED_RUNE_TEMP,
  688. TF_COND_PASSTIME_INTERCEPTION,
  689. TF_COND_SWIMMING_NO_EFFECTS, // =107_DNOC_FT
  690. TF_COND_PURGATORY,
  691. TF_COND_RUNE_KING,
  692. TF_COND_RUNE_PLAGUE,
  693. TF_COND_RUNE_SUPERNOVA,
  694. TF_COND_PLAGUE,
  695. TF_COND_KING_BUFFED,
  696. TF_COND_TEAM_GLOWS, // used to show team glows to living players
  697. TF_COND_KNOCKED_INTO_AIR,
  698. TF_COND_COMPETITIVE_WINNER,
  699. TF_COND_COMPETITIVE_LOSER,
  700. TF_COND_HEALING_DEBUFF,
  701. TF_COND_PASSTIME_PENALTY_DEBUFF, // when carrying the ball without any teammates nearby
  702. TF_COND_GRAPPLED_TO_PLAYER,
  703. TF_COND_GRAPPLED_BY_PLAYER,
  704. //
  705. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  706. //
  707. // ******** Keep this block last! ********
  708. // Keep experimental conditions below and graduate out of it before shipping
  709. #ifdef STAGING_ONLY
  710. TF_COND_NO_COMBAT_SPEED_BOOST, // STAGING_ENGY
  711. TF_COND_TRANQ_SPY_BOOST, // STAGING_SPY
  712. TF_COND_TRANQ_MARKED,
  713. // TF_COND_SPACE_GRAVITY,
  714. // TF_COND_SELF_CONC,
  715. TF_COND_ROCKETPACK,
  716. TF_COND_STEALTHED_PHASE,
  717. TF_COND_CLIP_OVERLOAD,
  718. TF_COND_SPY_CLASS_STEAL,
  719. #endif // STAGING_ONLY
  720. TF_COND_LAST
  721. };
  722. const char *GetTFConditionName( ETFCond eCond );
  723. ETFCond GetTFConditionFromName( const char *pszCondName );
  724. // If you want your condition to expire faster under healing,
  725. // add it to this function in tf_shareddefs.cpp
  726. bool ConditionExpiresFast( ETFCond eCond );
  727. // Some attributes specify conditions to be or'd. The problem there is that if we add conditions
  728. // to the above list, they get hosed. So we maintain this separate list as a translation table.
  729. // When you add conditions to the above list, add them TO THE BOTTOM of this list.
  730. extern ETFCond condition_to_attribute_translation[];
  731. extern ETFCond g_aDebuffConditions[];
  732. //-----------------------------------------------------------------------------
  733. // TF Player State.
  734. //-----------------------------------------------------------------------------
  735. enum
  736. {
  737. TF_STATE_ACTIVE = 0, // Happily running around in the game.
  738. TF_STATE_WELCOME, // First entering the server (shows level intro screen).
  739. TF_STATE_OBSERVER, // Game observer mode.
  740. TF_STATE_DYING, // Player is dying.
  741. TF_STATE_COUNT
  742. //
  743. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  744. //
  745. };
  746. //-----------------------------------------------------------------------------
  747. // TF FlagInfo State.
  748. //-----------------------------------------------------------------------------
  749. #define TF_FLAGINFO_HOME 0
  750. #define TF_FLAGINFO_STOLEN (1<<0)
  751. #define TF_FLAGINFO_DROPPED (1<<1)
  752. enum ETFFlagEventTypes
  753. {
  754. TF_FLAGEVENT_PICKUP = 1,
  755. TF_FLAGEVENT_CAPTURE,
  756. TF_FLAGEVENT_DEFEND,
  757. TF_FLAGEVENT_DROPPED,
  758. TF_FLAGEVENT_RETURNED,
  759. //
  760. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  761. //
  762. TF_NUM_FLAG_EVENTS
  763. };
  764. const char *GetCTFEventName( ETFFlagEventTypes iEventType );
  765. ETFFlagEventTypes GetCTFEventTypeFromName( const char *pszName );
  766. //-----------------------------------------------------------------------------
  767. // TF Robot Destruction Score Methods
  768. //-----------------------------------------------------------------------------
  769. enum RDScoreMethod_t
  770. {
  771. SCORE_UNDEFINED = -1,
  772. SCORE_REACTOR_CAPTURED,
  773. SCORE_CORES_COLLECTED,
  774. SCORE_REACTOR_RETURNED,
  775. SCORE_REACTOR_STEAL,
  776. NUM_SCORE_TYPES
  777. };
  778. const char *GetRDScoreMethodName( RDScoreMethod_t iScoreMethod );
  779. RDScoreMethod_t GetRDScoreMethodFromName( const char *pszName );
  780. //-----------------------------------------------------------------------------
  781. // Class data
  782. //-----------------------------------------------------------------------------
  783. #define TF_REGEN_TIME 1.0 // Number of seconds between each regen.
  784. #define TF_REGEN_AMOUNT 3 // Amount of health regenerated each regen.
  785. #define TF_REGEN_TIME_RUNE 0.25 // Number of seconds between each regen generated by a powerup.
  786. //-----------------------------------------------------------------------------
  787. // Assist-damage constants
  788. //-----------------------------------------------------------------------------
  789. #define TF_TIME_ASSIST_KILL 3.0f // Time window for a recent damager to get credit for an assist for a kill
  790. #define TF_TIME_SUICIDE_KILL_CREDIT 10.0f // Time window for a recent damager to get credit for a kill if target suicides
  791. //-----------------------------------------------------------------------------
  792. // Domination/nemesis constants
  793. //-----------------------------------------------------------------------------
  794. #define TF_KILLS_DOMINATION 4 // # of unanswered kills to dominate another player
  795. //-----------------------------------------------------------------------------
  796. // Taunt attacks
  797. //-----------------------------------------------------------------------------
  798. enum taunt_attack_t
  799. {
  800. TAUNTATK_NONE = 0,
  801. TAUNTATK_PYRO_HADOUKEN,
  802. TAUNTATK_HEAVY_EAT,
  803. TAUNTATK_HEAVY_RADIAL_BUFF,
  804. TAUNTATK_HEAVY_HIGH_NOON,
  805. TAUNTATK_SCOUT_DRINK,
  806. TAUNTATK_SCOUT_GRAND_SLAM,
  807. TAUNTATK_MEDIC_INHALE,
  808. TAUNTATK_SPY_FENCING_SLASH_A,
  809. TAUNTATK_SPY_FENCING_SLASH_B,
  810. TAUNTATK_SPY_FENCING_STAB,
  811. TAUNTATK_RPS_KILL,
  812. TAUNTATK_SNIPER_ARROW_STAB_IMPALE,
  813. TAUNTATK_SNIPER_ARROW_STAB_KILL,
  814. TAUNTATK_SOLDIER_GRENADE_KILL,
  815. TAUNTATK_DEMOMAN_BARBARIAN_SWING,
  816. TAUNTATK_MEDIC_UBERSLICE_IMPALE,
  817. TAUNTATK_MEDIC_UBERSLICE_KILL,
  818. TAUNTATK_FLIP_LAND_PARTICLE,
  819. TAUNTATK_RPS_PARTICLE,
  820. TAUNTATK_HIGHFIVE_PARTICLE,
  821. TAUNTATK_ENGINEER_GUITAR_SMASH,
  822. TAUNTATK_ENGINEER_ARM_IMPALE,
  823. TAUNTATK_ENGINEER_ARM_KILL,
  824. TAUNTATK_ENGINEER_ARM_BLEND,
  825. TAUNTATK_SOLDIER_GRENADE_KILL_WORMSIGN,
  826. TAUNTATK_SHOW_ITEM,
  827. TAUNTATK_MEDIC_RELEASE_DOVES,
  828. TAUNTATK_PYRO_ARMAGEDDON,
  829. TAUNTATK_PYRO_SCORCHSHOT,
  830. TAUNTATK_ALLCLASS_GUITAR_RIFF,
  831. TAUNTATK_MEDIC_HEROIC_TAUNT,
  832. //
  833. // INSERT NEW ITEMS HERE TO AVOID BREAKING DEMOS
  834. //
  835. TAUNTATK_COUNT
  836. };
  837. taunt_attack_t GetTauntAttackByName( const char* pszTauntAttackName );
  838. //-----------------------------------------------------------------------------
  839. // TF Hints
  840. //-----------------------------------------------------------------------------
  841. enum
  842. {
  843. HINT_FRIEND_SEEN = 0, // #Hint_spotted_a_friend
  844. HINT_ENEMY_SEEN, // #Hint_spotted_an_enemy
  845. HINT_ENEMY_KILLED, // #Hint_killing_enemies_is_good
  846. HINT_AMMO_EXHAUSTED, // #Hint_out_of_ammo
  847. HINT_TURN_OFF_HINTS, // #Hint_turn_off_hints
  848. HINT_PICKUP_AMMO, // #Hint_pickup_ammo
  849. HINT_CANNOT_TELE_WITH_FLAG, // #Hint_Cannot_Teleport_With_Flag
  850. HINT_CANNOT_CLOAK_WITH_FLAG, // #Hint_Cannot_Cloak_With_Flag
  851. HINT_CANNOT_DISGUISE_WITH_FLAG, // #Hint_Cannot_Disguise_With_Flag
  852. HINT_CANNOT_ATTACK_WHILE_CLOAKED, // #Hint_Cannot_Attack_While_Cloaked
  853. HINT_CLASSMENU, // #Hint_ClassMenu
  854. // Grenades
  855. HINT_GREN_CALTROPS, // #Hint_gren_caltrops
  856. HINT_GREN_CONCUSSION, // #Hint_gren_concussion
  857. HINT_GREN_EMP, // #Hint_gren_emp
  858. HINT_GREN_GAS, // #Hint_gren_gas
  859. HINT_GREN_MIRV, // #Hint_gren_mirv
  860. HINT_GREN_NAIL, // #Hint_gren_nail
  861. HINT_GREN_NAPALM, // #Hint_gren_napalm
  862. HINT_GREN_NORMAL, // #Hint_gren_normal
  863. // Weapon alt-fires
  864. HINT_ALTFIRE_SNIPERRIFLE, // #Hint_altfire_sniperrifle
  865. HINT_ALTFIRE_FLAMETHROWER, // #Hint_altfire_flamethrower
  866. HINT_ALTFIRE_GRENADELAUNCHER, // #Hint_altfire_grenadelauncher
  867. HINT_ALTFIRE_PIPEBOMBLAUNCHER, // #Hint_altfire_pipebomblauncher
  868. HINT_ALTFIRE_ROTATE_BUILDING, // #Hint_altfire_rotate_building
  869. // Class specific
  870. // Soldier
  871. HINT_SOLDIER_RPG_RELOAD, // #Hint_Soldier_rpg_reload
  872. // Engineer
  873. HINT_ENGINEER_USE_WRENCH_ONOWN, // "#Hint_Engineer_use_wrench_onown",
  874. HINT_ENGINEER_USE_WRENCH_ONOTHER, // "#Hint_Engineer_use_wrench_onother",
  875. HINT_ENGINEER_USE_WRENCH_FRIEND, // "#Hint_Engineer_use_wrench_onfriend",
  876. HINT_ENGINEER_BUILD_SENTRYGUN, // "#Hint_Engineer_build_sentrygun"
  877. HINT_ENGINEER_BUILD_DISPENSER, // "#Hint_Engineer_build_dispenser"
  878. HINT_ENGINEER_BUILD_TELEPORTERS, // "#Hint_Engineer_build_teleporters"
  879. HINT_ENGINEER_PICKUP_METAL, // "#Hint_Engineer_pickup_metal"
  880. HINT_ENGINEER_REPAIR_OBJECT, // "#Hint_Engineer_repair_object"
  881. HINT_ENGINEER_METAL_TO_UPGRADE, // "#Hint_Engineer_metal_to_upgrade"
  882. HINT_ENGINEER_UPGRADE_SENTRYGUN, // "#Hint_Engineer_upgrade_sentrygun"
  883. HINT_OBJECT_HAS_SAPPER, // "#Hint_object_has_sapper"
  884. HINT_OBJECT_YOUR_OBJECT_SAPPED, // "#Hint_object_your_object_sapped"
  885. HINT_OBJECT_ENEMY_USING_DISPENSER, // "#Hint_enemy_using_dispenser"
  886. HINT_OBJECT_ENEMY_USING_TP_ENTRANCE, // "#Hint_enemy_using_tp_entrance"
  887. HINT_OBJECT_ENEMY_USING_TP_EXIT, // "#Hint_enemy_using_tp_exit"
  888. HINT_CANNOT_PHASE_WITH_FLAG, // #Hint_Cannot_Phase_With_Flag
  889. HINT_CANNOT_ATTACK_WHILE_FEIGN_ARMED, // #Hint_Cannot_Attack_While_Feign_Armed
  890. HINT_CANNOT_ARM_FEIGN_NOW, // #Hint_Cannot_Arm_Feign_Now
  891. //
  892. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  893. //
  894. NUM_HINTS
  895. };
  896. extern const char *g_pszHintMessages[];
  897. /*======================*/
  898. // Menu stuff //
  899. /*======================*/
  900. #define MENU_DEFAULT 1
  901. #define MENU_TEAM 2
  902. #define MENU_CLASS 3
  903. #define MENU_MAPBRIEFING 4
  904. #define MENU_INTRO 5
  905. #define MENU_CLASSHELP 6
  906. #define MENU_CLASSHELP2 7
  907. #define MENU_REPEATHELP 8
  908. #define MENU_SPECHELP 9
  909. #define MENU_SPY 12
  910. #define MENU_SPY_SKIN 13
  911. #define MENU_SPY_COLOR 14
  912. #define MENU_ENGINEER 15
  913. #define MENU_ENGINEER_FIX_DISPENSER 16
  914. #define MENU_ENGINEER_FIX_SENTRYGUN 17
  915. #define MENU_ENGINEER_FIX_MORTAR 18
  916. #define MENU_DISPENSER 19
  917. #define MENU_CLASS_CHANGE 20
  918. #define MENU_TEAM_CHANGE 21
  919. #define MENU_REFRESH_RATE 25
  920. #define MENU_VOICETWEAK 50
  921. // Additional classes
  922. // NOTE: adding them onto the Class_T's in baseentity.h is cheesy, but so is
  923. // having an #ifdef for each mod in baseentity.h.
  924. #define CLASS_TFGOAL ((Class_T)NUM_AI_CLASSES)
  925. #define CLASS_TFGOAL_TIMER ((Class_T)(NUM_AI_CLASSES+1))
  926. #define CLASS_TFGOAL_ITEM ((Class_T)(NUM_AI_CLASSES+2))
  927. #define CLASS_TFSPAWN ((Class_T)(NUM_AI_CLASSES+3))
  928. #define CLASS_MACHINE ((Class_T)(NUM_AI_CLASSES+4))
  929. // TeamFortress State Flags
  930. #define TFSTATE_GRENPRIMED 0x000001 // Whether the player has a primed grenade
  931. #define TFSTATE_RELOADING 0x000002 // Whether the player is reloading
  932. #define TFSTATE_ALTKILL 0x000004 // #TRUE if killed with a weapon not in self.weapon: NOT USED ANYMORE
  933. #define TFSTATE_RANDOMPC 0x000008 // Whether Playerclass is random, new one each respawn
  934. #define TFSTATE_INFECTED 0x000010 // set when player is infected by the bioweapon
  935. #define TFSTATE_INVINCIBLE 0x000020 // Player has permanent Invincibility (Usually by GoalItem)
  936. #define TFSTATE_INVISIBLE 0x000040 // Player has permanent Invisibility (Usually by GoalItem)
  937. #define TFSTATE_QUAD 0x000080 // Player has permanent Quad Damage (Usually by GoalItem)
  938. #define TFSTATE_RADSUIT 0x000100 // Player has permanent Radsuit (Usually by GoalItem)
  939. #define TFSTATE_BURNING 0x000200 // Is on fire
  940. #define TFSTATE_GRENTHROWING 0x000400 // is throwing a grenade
  941. #define TFSTATE_AIMING 0x000800 // is using the laser sight
  942. #define TFSTATE_ZOOMOFF 0x001000 // doesn't want the FOV changed when zooming
  943. #define TFSTATE_RESPAWN_READY 0x002000 // is waiting for respawn, and has pressed fire
  944. #define TFSTATE_HALLUCINATING 0x004000 // set when player is hallucinating
  945. #define TFSTATE_TRANQUILISED 0x008000 // set when player is tranquilised
  946. #define TFSTATE_CANT_MOVE 0x010000 // player isn't allowed to move
  947. #define TFSTATE_RESET_FLAMETIME 0x020000 // set when the player has to have his flames increased in health
  948. #define TFSTATE_HIGHEST_VALUE TFSTATE_RESET_FLAMETIME
  949. // items
  950. #define IT_SHOTGUN (1<<0)
  951. #define IT_SUPER_SHOTGUN (1<<1)
  952. #define IT_NAILGUN (1<<2)
  953. #define IT_SUPER_NAILGUN (1<<3)
  954. #define IT_GRENADE_LAUNCHER (1<<4)
  955. #define IT_ROCKET_LAUNCHER (1<<5)
  956. #define IT_LIGHTNING (1<<6)
  957. #define IT_EXTRA_WEAPON (1<<7)
  958. #define IT_SHELLS (1<<8)
  959. #define IT_BULLETS (1<<9)
  960. #define IT_ROCKETS (1<<10)
  961. #define IT_CELLS (1<<11)
  962. #define IT_AXE (1<<12)
  963. #define IT_ARMOR1 (1<<13)
  964. #define IT_ARMOR2 (1<<14)
  965. #define IT_ARMOR3 (1<<15)
  966. #define IT_SUPERHEALTH (1<<16)
  967. #define IT_KEY1 (1<<17)
  968. #define IT_KEY2 (1<<18)
  969. #define IT_INVISIBILITY (1<<19)
  970. #define IT_INVULNERABILITY (1<<20)
  971. #define IT_SUIT (1<<21)
  972. #define IT_QUAD (1<<22)
  973. #define IT_HOOK (1<<23)
  974. #define IT_KEY3 (1<<24) // Stomp invisibility
  975. #define IT_KEY4 (1<<25) // Stomp invulnerability
  976. #define IT_LAST_ITEM IT_KEY4
  977. /*==================================================*/
  978. /* New Weapon Related Defines */
  979. /*==================================================*/
  980. // Medikit
  981. #define WEAP_MEDIKIT_OVERHEAL 50 // Amount of superhealth over max_health the medikit will dispense
  982. #define WEAP_MEDIKIT_HEAL 200 // Amount medikit heals per hit
  983. //--------------
  984. // TF Specific damage flags
  985. //--------------
  986. //#define DMG_UNUSED (DMG_LASTGENERICFLAG<<2)
  987. // We can't add anymore dmg flags, because we'd be over the 32 bit limit.
  988. // So lets re-use some of the old dmg flags in TF
  989. #define DMG_USE_HITLOCATIONS (DMG_AIRBOAT)
  990. #define DMG_HALF_FALLOFF (DMG_RADIATION)
  991. #define DMG_CRITICAL (DMG_ACID)
  992. #define DMG_RADIUS_MAX (DMG_ENERGYBEAM)
  993. #define DMG_IGNITE (DMG_PLASMA)
  994. #define DMG_USEDISTANCEMOD (DMG_SLOWBURN) // NEED TO REMOVE CALTROPS
  995. #define DMG_NOCLOSEDISTANCEMOD (DMG_POISON)
  996. #define DMG_FROM_OTHER_SAPPER (DMG_IGNITE) // USED TO DAMAGE SAPPERS ON MATCHED TELEPORTERS
  997. #define DMG_MELEE (DMG_BLAST_SURFACE)
  998. #define DMG_DONT_COUNT_DAMAGE_TOWARDS_CRIT_RATE (DMG_DISSOLVE) // DON'T USE THIS FOR EXPLOSION DAMAGE YOU WILL MAKE BRANDON SAD AND KYLE SADDER
  999. // This can only ever be used on a TakeHealth call, since it re-uses a dmg flag that means something else
  1000. #define DMG_IGNORE_MAXHEALTH (DMG_BULLET)
  1001. #define DMG_IGNORE_DEBUFFS (DMG_SLASH)
  1002. // Special Damage types
  1003. // Also update g_szSpecialDamageNames
  1004. enum ETFDmgCustom
  1005. {
  1006. TF_DMG_CUSTOM_NONE = 0,
  1007. TF_DMG_CUSTOM_HEADSHOT,
  1008. TF_DMG_CUSTOM_BACKSTAB,
  1009. TF_DMG_CUSTOM_BURNING,
  1010. TF_DMG_WRENCH_FIX,
  1011. TF_DMG_CUSTOM_MINIGUN,
  1012. TF_DMG_CUSTOM_SUICIDE,
  1013. TF_DMG_CUSTOM_TAUNTATK_HADOUKEN,
  1014. TF_DMG_CUSTOM_BURNING_FLARE,
  1015. TF_DMG_CUSTOM_TAUNTATK_HIGH_NOON,
  1016. TF_DMG_CUSTOM_TAUNTATK_GRAND_SLAM,
  1017. TF_DMG_CUSTOM_PENETRATE_MY_TEAM,
  1018. TF_DMG_CUSTOM_PENETRATE_ALL_PLAYERS,
  1019. TF_DMG_CUSTOM_TAUNTATK_FENCING,
  1020. TF_DMG_CUSTOM_PENETRATE_NONBURNING_TEAMMATE,
  1021. TF_DMG_CUSTOM_TAUNTATK_ARROW_STAB,
  1022. TF_DMG_CUSTOM_TELEFRAG,
  1023. TF_DMG_CUSTOM_BURNING_ARROW,
  1024. TF_DMG_CUSTOM_FLYINGBURN,
  1025. TF_DMG_CUSTOM_PUMPKIN_BOMB,
  1026. TF_DMG_CUSTOM_DECAPITATION,
  1027. TF_DMG_CUSTOM_TAUNTATK_GRENADE,
  1028. TF_DMG_CUSTOM_BASEBALL,
  1029. TF_DMG_CUSTOM_CHARGE_IMPACT,
  1030. TF_DMG_CUSTOM_TAUNTATK_BARBARIAN_SWING,
  1031. TF_DMG_CUSTOM_AIR_STICKY_BURST,
  1032. TF_DMG_CUSTOM_DEFENSIVE_STICKY,
  1033. TF_DMG_CUSTOM_PICKAXE,
  1034. TF_DMG_CUSTOM_ROCKET_DIRECTHIT,
  1035. TF_DMG_CUSTOM_TAUNTATK_UBERSLICE,
  1036. TF_DMG_CUSTOM_PLAYER_SENTRY,
  1037. TF_DMG_CUSTOM_STANDARD_STICKY,
  1038. TF_DMG_CUSTOM_SHOTGUN_REVENGE_CRIT,
  1039. TF_DMG_CUSTOM_TAUNTATK_ENGINEER_GUITAR_SMASH,
  1040. TF_DMG_CUSTOM_BLEEDING,
  1041. TF_DMG_CUSTOM_GOLD_WRENCH,
  1042. TF_DMG_CUSTOM_CARRIED_BUILDING,
  1043. TF_DMG_CUSTOM_COMBO_PUNCH,
  1044. TF_DMG_CUSTOM_TAUNTATK_ENGINEER_ARM_KILL,
  1045. TF_DMG_CUSTOM_FISH_KILL,
  1046. TF_DMG_CUSTOM_TRIGGER_HURT,
  1047. TF_DMG_CUSTOM_DECAPITATION_BOSS,
  1048. TF_DMG_CUSTOM_STICKBOMB_EXPLOSION,
  1049. TF_DMG_CUSTOM_AEGIS_ROUND,
  1050. TF_DMG_CUSTOM_FLARE_EXPLOSION,
  1051. TF_DMG_CUSTOM_BOOTS_STOMP,
  1052. TF_DMG_CUSTOM_PLASMA,
  1053. TF_DMG_CUSTOM_PLASMA_CHARGED,
  1054. TF_DMG_CUSTOM_PLASMA_GIB,
  1055. TF_DMG_CUSTOM_PRACTICE_STICKY,
  1056. TF_DMG_CUSTOM_EYEBALL_ROCKET,
  1057. TF_DMG_CUSTOM_HEADSHOT_DECAPITATION,
  1058. TF_DMG_CUSTOM_TAUNTATK_ARMAGEDDON,
  1059. TF_DMG_CUSTOM_FLARE_PELLET,
  1060. TF_DMG_CUSTOM_CLEAVER,
  1061. TF_DMG_CUSTOM_CLEAVER_CRIT,
  1062. TF_DMG_CUSTOM_SAPPER_RECORDER_DEATH,
  1063. TF_DMG_CUSTOM_MERASMUS_PLAYER_BOMB,
  1064. TF_DMG_CUSTOM_MERASMUS_GRENADE,
  1065. TF_DMG_CUSTOM_MERASMUS_ZAP,
  1066. TF_DMG_CUSTOM_MERASMUS_DECAPITATION,
  1067. TF_DMG_CUSTOM_CANNONBALL_PUSH,
  1068. TF_DMG_CUSTOM_TAUNTATK_ALLCLASS_GUITAR_RIFF,
  1069. TF_DMG_CUSTOM_THROWABLE,
  1070. TF_DMG_CUSTOM_THROWABLE_KILL,
  1071. TF_DMG_CUSTOM_SPELL_TELEPORT,
  1072. TF_DMG_CUSTOM_SPELL_SKELETON,
  1073. TF_DMG_CUSTOM_SPELL_MIRV,
  1074. TF_DMG_CUSTOM_SPELL_METEOR,
  1075. TF_DMG_CUSTOM_SPELL_LIGHTNING,
  1076. TF_DMG_CUSTOM_SPELL_FIREBALL,
  1077. TF_DMG_CUSTOM_SPELL_MONOCULUS,
  1078. TF_DMG_CUSTOM_SPELL_BLASTJUMP,
  1079. TF_DMG_CUSTOM_SPELL_BATS,
  1080. TF_DMG_CUSTOM_SPELL_TINY,
  1081. TF_DMG_CUSTOM_KART,
  1082. TF_DMG_CUSTOM_GIANT_HAMMER,
  1083. TF_DMG_CUSTOM_RUNE_REFLECT,
  1084. //
  1085. // INSERT NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1086. //
  1087. TF_DMG_CUSTOM_END // END
  1088. };
  1089. const char *GetCustomDamageName( ETFDmgCustom eDmgCustom );
  1090. ETFDmgCustom GetCustomDamageFromName( const char *pszCustomDmgName );
  1091. inline bool IsTauntDmg( int iType )
  1092. {
  1093. return (iType == TF_DMG_CUSTOM_TAUNTATK_HADOUKEN ||
  1094. iType == TF_DMG_CUSTOM_TAUNTATK_HIGH_NOON ||
  1095. iType == TF_DMG_CUSTOM_TAUNTATK_GRAND_SLAM ||
  1096. iType == TF_DMG_CUSTOM_TAUNTATK_FENCING ||
  1097. iType == TF_DMG_CUSTOM_TAUNTATK_ARROW_STAB ||
  1098. iType == TF_DMG_CUSTOM_TAUNTATK_GRENADE ||
  1099. iType == TF_DMG_CUSTOM_TAUNTATK_BARBARIAN_SWING ||
  1100. iType == TF_DMG_CUSTOM_TAUNTATK_UBERSLICE ||
  1101. iType == TF_DMG_CUSTOM_TAUNTATK_ENGINEER_GUITAR_SMASH ||
  1102. iType == TF_DMG_CUSTOM_TAUNTATK_ARMAGEDDON ||
  1103. iType == TF_DMG_CUSTOM_TAUNTATK_ALLCLASS_GUITAR_RIFF ||
  1104. iType == TF_DMG_CUSTOM_TAUNTATK_ENGINEER_ARM_KILL );
  1105. }
  1106. inline bool IsDOTDmg( int iType )
  1107. {
  1108. if ( iType == TF_DMG_CUSTOM_BURNING ||
  1109. iType == TF_DMG_CUSTOM_BURNING_FLARE ||
  1110. iType == TF_DMG_CUSTOM_BURNING_ARROW ||
  1111. iType == TF_DMG_CUSTOM_BLEEDING )
  1112. {
  1113. return true;
  1114. }
  1115. else
  1116. {
  1117. return false;
  1118. }
  1119. }
  1120. inline bool IsHeadshot( int iType )
  1121. {
  1122. return (iType == TF_DMG_CUSTOM_HEADSHOT || iType == TF_DMG_CUSTOM_HEADSHOT_DECAPITATION);
  1123. }
  1124. enum
  1125. {
  1126. TF_COLLISIONGROUP_GRENADES = LAST_SHARED_COLLISION_GROUP,
  1127. TFCOLLISION_GROUP_OBJECT,
  1128. TFCOLLISION_GROUP_OBJECT_SOLIDTOPLAYERMOVEMENT,
  1129. TFCOLLISION_GROUP_COMBATOBJECT,
  1130. TFCOLLISION_GROUP_ROCKETS, // Solid to players, but not player movement. ensures touch calls are originating from rocket
  1131. TFCOLLISION_GROUP_RESPAWNROOMS,
  1132. TFCOLLISION_GROUP_TANK,
  1133. TFCOLLISION_GROUP_ROCKET_BUT_NOT_WITH_OTHER_ROCKETS,
  1134. //
  1135. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1136. //
  1137. };
  1138. // Stun flags
  1139. #define TF_STUN_NONE 0
  1140. #define TF_STUN_MOVEMENT (1<<0)
  1141. #define TF_STUN_CONTROLS (1<<1)
  1142. #define TF_STUN_MOVEMENT_FORWARD_ONLY (1<<2)
  1143. #define TF_STUN_SPECIAL_SOUND (1<<3)
  1144. #define TF_STUN_DODGE_COOLDOWN (1<<4)
  1145. #define TF_STUN_NO_EFFECTS (1<<5)
  1146. #define TF_STUN_LOSER_STATE (1<<6)
  1147. #define TF_STUN_BY_TRIGGER (1<<7)
  1148. #define TF_STUN_BOTH TF_STUN_MOVEMENT | TF_STUN_CONTROLS
  1149. //-----------------
  1150. // TF Objects Info
  1151. //-----------------
  1152. #define SENTRYGUN_UPGRADE_COST 130
  1153. #define SENTRYGUN_UPGRADE_METAL 200
  1154. #define SENTRYGUN_EYE_OFFSET_LEVEL_1 Vector( 0, 0, 32 )
  1155. #define SENTRYGUN_EYE_OFFSET_LEVEL_2 Vector( 0, 0, 40 )
  1156. #define SENTRYGUN_EYE_OFFSET_LEVEL_3 Vector( 0, 0, 46 )
  1157. #define SENTRYGUN_MAX_SHELLS_1 150
  1158. #define SENTRYGUN_MAX_SHELLS_2 200
  1159. #define SENTRYGUN_MAX_SHELLS_3 200
  1160. #define SENTRYGUN_MAX_ROCKETS 20
  1161. // Dispenser's maximum carrying capability
  1162. #define DISPENSER_MAX_METAL_AMMO 400
  1163. #define MAX_DISPENSER_HEALING_TARGETS 32
  1164. #define MINI_DISPENSER_MAX_METAL 200
  1165. //--------------------------------------------------------------------------
  1166. // OBJECTS
  1167. //--------------------------------------------------------------------------
  1168. enum ObjectType_t
  1169. {
  1170. OBJ_DISPENSER=0,
  1171. OBJ_TELEPORTER,
  1172. OBJ_SENTRYGUN,
  1173. // Attachment Objects
  1174. OBJ_ATTACHMENT_SAPPER,
  1175. // If you add a new object, you need to add it to the g_ObjectInfos array
  1176. // in tf_shareddefs.cpp, and add it's data to the scripts/object.txt
  1177. //
  1178. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1179. //
  1180. #ifdef STAGING_ONLY
  1181. OBJ_CATAPULT,
  1182. OBJ_SPY_TRAP,
  1183. #endif
  1184. OBJ_LAST,
  1185. };
  1186. #define BUILDING_MODE_ANY -1
  1187. enum
  1188. {
  1189. MODE_TELEPORTER_ENTRANCE=0,
  1190. MODE_TELEPORTER_EXIT,
  1191. #ifdef STAGING_ONLY
  1192. MODE_TELEPORTER_SPEED,
  1193. MODE_TELEPORTER_SPEED2,
  1194. #endif
  1195. };
  1196. enum
  1197. {
  1198. MODE_SENTRYGUN_NORMAL = 0,
  1199. MODE_SENTRYGUN_DISPOSABLE,
  1200. };
  1201. enum
  1202. {
  1203. MODE_SAPPER_NORMAL = 0,
  1204. MODE_SAPPER_ANTI_ROBOT,
  1205. MODE_SAPPER_ANTI_ROBOT_RADIUS,
  1206. };
  1207. enum ESpyTrapType_t
  1208. {
  1209. MODE_SPY_TRAP_RADIUS_STEALTH = 0,
  1210. MODE_SPY_TRAP_REPROGRAM,
  1211. MODE_SPY_TRAP_MAGNET,
  1212. // MODE_SPY_TRAP_REPULSOR,
  1213. };
  1214. // Warning levels for buildings in the building hud, in priority order
  1215. typedef enum
  1216. {
  1217. BUILDING_HUD_ALERT_NONE = 0,
  1218. BUILDING_HUD_ALERT_LOW_AMMO,
  1219. BUILDING_HUD_ALERT_LOW_HEALTH,
  1220. BUILDING_HUD_ALERT_VERY_LOW_AMMO,
  1221. BUILDING_HUD_ALERT_VERY_LOW_HEALTH,
  1222. BUILDING_HUD_ALERT_SAPPER,
  1223. //
  1224. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1225. //
  1226. MAX_BUILDING_HUD_ALERT_LEVEL
  1227. } BuildingHudAlert_t;
  1228. typedef enum
  1229. {
  1230. BUILDING_DAMAGE_LEVEL_NONE = 0, // 100%
  1231. BUILDING_DAMAGE_LEVEL_LIGHT, // 75% - 99%
  1232. BUILDING_DAMAGE_LEVEL_MEDIUM, // 50% - 76%
  1233. BUILDING_DAMAGE_LEVEL_HEAVY, // 25% - 49%
  1234. BUILDING_DAMAGE_LEVEL_CRITICAL, // 0% - 24%
  1235. //
  1236. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1237. //
  1238. MAX_BUILDING_DAMAGE_LEVEL
  1239. } BuildingDamageLevel_t;
  1240. //--------------
  1241. // Scoring
  1242. //--------------
  1243. #define TF_SCORE_KILL 1
  1244. #define TF_SCORE_DEATH 0
  1245. #define TF_SCORE_CAPTURE 2
  1246. #define TF_SCORE_DEFEND 1
  1247. #define TF_SCORE_DESTROY_BUILDING 1
  1248. #define TF_SCORE_HEADSHOT_DIVISOR 2
  1249. #define TF_SCORE_BACKSTAB 1
  1250. #define TF_SCORE_INVULN 1
  1251. #define TF_SCORE_REVENGE 1
  1252. #define TF_SCORE_KILL_ASSISTS_PER_POINT 2
  1253. #define TF_SCORE_TELEPORTS_PER_POINT 2
  1254. #define TF_SCORE_HEAL_HEALTHUNITS_PER_POINT 600
  1255. #define TF_SCORE_BONUS_POINT_DIVISOR 10
  1256. #define TF_SCORE_DAMAGE 250
  1257. #define TF_SCORE_CURRENCY_COLLECTED 20
  1258. #define TF_SCORE_CAPTURE_POWERUPMODE 10 // With these CTF rules capturing flags is tougher, hence the higher scoring for flag events
  1259. #define TF_SCORE_FLAG_RETURN 4
  1260. #define TF_SCORE_KILL_RUNECARRIER 1
  1261. //-------------------------
  1262. // Shared Teleporter State
  1263. //-------------------------
  1264. enum
  1265. {
  1266. DISPENSER_STATE_IDLE,
  1267. DISPENSER_STATE_UPGRADING,
  1268. //
  1269. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1270. //
  1271. };
  1272. //-------------------------
  1273. // Shared Teleporter State
  1274. //-------------------------
  1275. enum
  1276. {
  1277. TELEPORTER_STATE_BUILDING = 0, // Building, not active yet
  1278. TELEPORTER_STATE_IDLE, // Does not have a matching teleporter yet
  1279. TELEPORTER_STATE_READY, // Found match, charged and ready
  1280. TELEPORTER_STATE_SENDING, // Teleporting a player away
  1281. TELEPORTER_STATE_RECEIVING,
  1282. TELEPORTER_STATE_RECEIVING_RELEASE,
  1283. TELEPORTER_STATE_RECHARGING, // Waiting for recharge
  1284. TELEPORTER_STATE_UPGRADING,
  1285. //
  1286. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1287. //
  1288. };
  1289. #define TELEPORTER_TYPE_ENTRANCE 0
  1290. #define TELEPORTER_TYPE_EXIT 1
  1291. //-------------------------
  1292. // Shared Sentry State
  1293. //-------------------------
  1294. enum
  1295. {
  1296. SENTRY_STATE_INACTIVE = 0,
  1297. SENTRY_STATE_SEARCHING,
  1298. SENTRY_STATE_ATTACKING,
  1299. SENTRY_STATE_UPGRADING,
  1300. //
  1301. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1302. //
  1303. SENTRY_NUM_STATES,
  1304. };
  1305. //--------------------------------------------------------------------------
  1306. // OBJECT FLAGS
  1307. //--------------------------------------------------------------------------
  1308. enum
  1309. {
  1310. OF_ALLOW_REPEAT_PLACEMENT = 0x01,
  1311. OF_MUST_BE_BUILT_ON_ATTACHMENT = 0x02,
  1312. OF_DOESNT_HAVE_A_MODEL = 0x04,
  1313. OF_PLAYER_DESTRUCTION = 0x08,
  1314. //
  1315. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1316. //
  1317. OF_BIT_COUNT = 4
  1318. };
  1319. //--------------------------------------------------------------------------
  1320. // Builder "weapon" states
  1321. //--------------------------------------------------------------------------
  1322. enum
  1323. {
  1324. BS_IDLE = 0,
  1325. BS_SELECTING,
  1326. BS_PLACING,
  1327. BS_PLACING_INVALID
  1328. //
  1329. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1330. //
  1331. };
  1332. //--------------------------------------------------------------------------
  1333. // Builder object id...
  1334. //--------------------------------------------------------------------------
  1335. enum
  1336. {
  1337. BUILDER_OBJECT_BITS = 8,
  1338. BUILDER_INVALID_OBJECT = ((1 << BUILDER_OBJECT_BITS) - 1)
  1339. };
  1340. // Analyzer state
  1341. enum
  1342. {
  1343. AS_INACTIVE = 0,
  1344. AS_SUBVERTING,
  1345. AS_ANALYZING
  1346. };
  1347. // Max number of objects a team can have
  1348. #define MAX_OBJECTS_PER_PLAYER 6
  1349. //#define MAX_OBJECTS_PER_TEAM 128
  1350. // sanity check that commands send via user command are somewhat valid
  1351. #define MAX_OBJECT_SCREEN_INPUT_DISTANCE 100
  1352. //--------------------------------------------------------------------------
  1353. // BUILDING
  1354. //--------------------------------------------------------------------------
  1355. // Build checks will return one of these for a player
  1356. enum
  1357. {
  1358. CB_CAN_BUILD, // Player is allowed to build this object
  1359. CB_CANNOT_BUILD, // Player is not allowed to build this object
  1360. CB_LIMIT_REACHED, // Player has reached the limit of the number of these objects allowed
  1361. CB_NEED_RESOURCES, // Player doesn't have enough resources to build this object
  1362. CB_NEED_ADRENALIN, // Commando doesn't have enough adrenalin to build a rally flag
  1363. CB_UNKNOWN_OBJECT, // Error message, tried to build unknown object
  1364. //
  1365. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1366. //
  1367. };
  1368. // Build animation events
  1369. #define TF_OBJ_ENABLEBODYGROUP 6000
  1370. #define TF_OBJ_DISABLEBODYGROUP 6001
  1371. #define TF_OBJ_ENABLEALLBODYGROUPS 6002
  1372. #define TF_OBJ_DISABLEALLBODYGROUPS 6003
  1373. #define TF_OBJ_PLAYBUILDSOUND 6004
  1374. #define TF_AE_CIGARETTE_THROW 7000
  1375. #define TF_AE_GUN_SALUTE 7001
  1376. #define TF_AE_PICKAXE_THROW 7002
  1377. #define OBJECT_COST_MULTIPLIER_PER_OBJECT 3
  1378. #define OBJECT_UPGRADE_COST_MULTIPLIER_PER_LEVEL 3
  1379. //--------------------------------------------------------------------------
  1380. // Powerups
  1381. //--------------------------------------------------------------------------
  1382. enum
  1383. {
  1384. POWERUP_BOOST, // Medic, buff station
  1385. POWERUP_EMP, // Technician
  1386. POWERUP_RUSH, // Rally flag
  1387. POWERUP_POWER, // Object power
  1388. //
  1389. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1390. //
  1391. MAX_POWERUPS
  1392. };
  1393. #define MAX_CABLE_CONNECTIONS 4
  1394. bool IsObjectAnUpgrade( int iObjectType );
  1395. bool IsObjectAVehicle( int iObjectType );
  1396. bool IsObjectADefensiveBuilding( int iObjectType );
  1397. class CHudTexture;
  1398. #define OBJECT_MAX_GIB_MODELS 9
  1399. #ifdef STAGING_ONLY
  1400. #define OBJECT_MAX_MODES 4
  1401. #else
  1402. #define OBJECT_MAX_MODES 3
  1403. #endif
  1404. // This should be moved into its own header.
  1405. class CObjectInfo
  1406. {
  1407. public:
  1408. CObjectInfo( const char *pObjectName );
  1409. ~CObjectInfo();
  1410. // This is initialized by the code and matched with a section in objects.txt
  1411. const char *m_pObjectName;
  1412. // This stuff all comes from objects.txt
  1413. char *m_pClassName; // Code classname (in LINK_ENTITY_TO_CLASS).
  1414. char *m_pStatusName; // Shows up when crosshairs are on the object.
  1415. float m_flBuildTime;
  1416. int m_nMaxObjects; // Maximum number of objects per player
  1417. int m_Cost; // Base object resource cost
  1418. float m_CostMultiplierPerInstance; // Cost multiplier
  1419. int m_UpgradeCost; // Base object resource cost for upgrading
  1420. int m_MaxUpgradeLevel; // Max object upgrade level
  1421. char *m_pBuilderWeaponName; // Names shown for each object onscreen when using the builder weapon
  1422. char *m_pBuilderPlacementString; // String shown to player during placement of this object
  1423. int m_SelectionSlot; // Weapon selection slots for objects
  1424. int m_SelectionPosition; // Weapon selection positions for objects
  1425. bool m_bSolidToPlayerMovement;
  1426. bool m_bUseItemInfo; // Use default item appearance info.
  1427. char *m_pViewModel; // View model to show in builder weapon for this object
  1428. char *m_pPlayerModel; // World model to show attached to the player
  1429. int m_iDisplayPriority; // Priority for ordering in the hud display ( higher is closer to top )
  1430. bool m_bVisibleInWeaponSelection; // should show up and be selectable via the weapon selection?
  1431. char *m_pExplodeSound; // gamesound to play when object explodes
  1432. char *m_pExplosionParticleEffect; // particle effect to play when object explodes
  1433. bool m_bAutoSwitchTo; // should we let players switch back to the builder weapon representing this?
  1434. char *m_pUpgradeSound; // gamesound to play when object is upgraded
  1435. float m_flUpgradeDuration; // time it takes to upgrade to the next level
  1436. int m_iBuildCount; // number of these that can be carried at one time
  1437. int m_iNumAltModes; // whether the item has more than one mode (ex: teleporter exit/entrance)
  1438. struct
  1439. {
  1440. char* pszStatusName;
  1441. char* pszModeName;
  1442. char* pszIconMenu;
  1443. } m_AltModes[OBJECT_MAX_MODES];
  1444. // HUD weapon selection menu icon ( from hud_textures.txt )
  1445. char *m_pIconActive;
  1446. char *m_pIconInactive;
  1447. char *m_pIconMenu;
  1448. // HUD building status icon
  1449. char *m_pHudStatusIcon;
  1450. // gibs
  1451. int m_iMetalToDropInGibs;
  1452. // unique builder
  1453. bool m_bRequiresOwnBuilder; // if object needs to instantiate its' own builder
  1454. };
  1455. // Loads the objects.txt script.
  1456. class IBaseFileSystem;
  1457. void LoadObjectInfos( IBaseFileSystem *pFileSystem );
  1458. // Get a CObjectInfo from a TFOBJ_ define.
  1459. const CObjectInfo* GetObjectInfo( int iObject );
  1460. // Object utility funcs
  1461. bool ClassCanBuild( int iClass, int iObjectType );
  1462. int InternalCalculateObjectCost( int iObjectType /*, int iNumberOfObjects, int iTeam, bool bLast = false*/ );
  1463. int CalculateObjectUpgrade( int iObjectType, int iObjectLevel );
  1464. // Shell ejections
  1465. enum
  1466. {
  1467. EJECTBRASS_PISTOL,
  1468. EJECTBRASS_MINIGUN,
  1469. //
  1470. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1471. //
  1472. };
  1473. // Win panel styles
  1474. enum
  1475. {
  1476. WINPANEL_BASIC = 0,
  1477. };
  1478. #define TF_DEATH_ANIMATION_TIME 2.0
  1479. enum HudNotification_t
  1480. {
  1481. HUD_NOTIFY_YOUR_FLAG_TAKEN,
  1482. HUD_NOTIFY_YOUR_FLAG_DROPPED,
  1483. HUD_NOTIFY_YOUR_FLAG_RETURNED,
  1484. HUD_NOTIFY_YOUR_FLAG_CAPTURED,
  1485. HUD_NOTIFY_ENEMY_FLAG_TAKEN,
  1486. HUD_NOTIFY_ENEMY_FLAG_DROPPED,
  1487. HUD_NOTIFY_ENEMY_FLAG_RETURNED,
  1488. HUD_NOTIFY_ENEMY_FLAG_CAPTURED,
  1489. HUD_NOTIFY_TOUCHING_ENEMY_CTF_CAP,
  1490. HUD_NOTIFY_NO_INVULN_WITH_FLAG,
  1491. HUD_NOTIFY_NO_TELE_WITH_FLAG,
  1492. HUD_NOTIFY_SPECIAL,
  1493. HUD_NOTIFY_GOLDEN_WRENCH,
  1494. HUD_NOTIFY_RD_ROBOT_UNDER_ATTACK,
  1495. HUD_NOTIFY_HOW_TO_CONTROL_GHOST,
  1496. HUD_NOTIFY_HOW_TO_CONTROL_KART,
  1497. HUD_NOTIFY_PASSTIME_HOWTO,
  1498. HUD_NOTIFY_PASSTIME_NO_TELE,
  1499. HUD_NOTIFY_PASSTIME_NO_CARRY,
  1500. HUD_NOTIFY_PASSTIME_NO_INVULN,
  1501. HUD_NOTIFY_PASSTIME_NO_DISGUISE,
  1502. HUD_NOTIFY_PASSTIME_NO_CLOAK,
  1503. HUD_NOTIFY_PASSTIME_NO_OOB, // out of bounds
  1504. HUD_NOTIFY_PASSTIME_NO_HOLSTER,
  1505. HUD_NOTIFY_PASSTIME_NO_TAUNT,
  1506. HUD_NOTIFY_COMPETITIVE_GC_DOWN,
  1507. HUD_NOTIFY_TRUCE_START,
  1508. HUD_NOTIFY_TRUCE_END,
  1509. HUD_NOTIFY_HOW_TO_CONTROL_GHOST_NO_RESPAWN,
  1510. //
  1511. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1512. //
  1513. NUM_STOCK_NOTIFICATIONS
  1514. };
  1515. // HudAlerts don't set HIDEHUD_MISCSTATUS, so they appear with the win panel, etc
  1516. typedef enum
  1517. {
  1518. HUD_ALERT_SCRAMBLE_TEAMS,
  1519. //
  1520. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1521. //
  1522. NUM_STOCK_ALERTS
  1523. } HudAlert_t;
  1524. //-----------------------------------------------------------------------------
  1525. // Item testing
  1526. //-----------------------------------------------------------------------------
  1527. enum testitem_botanims_t
  1528. {
  1529. TI_BOTANIM_IDLE,
  1530. TI_BOTANIM_CROUCH,
  1531. TI_BOTANIM_RUN,
  1532. TI_BOTANIM_CROUCH_WALK,
  1533. TI_BOTANIM_JUMP,
  1534. TI_BOTANIM_COUNT,
  1535. };
  1536. #define TF_DEATH_DOMINATION 0x0001 // killer is dominating victim
  1537. #define TF_DEATH_ASSISTER_DOMINATION 0x0002 // assister is dominating victim
  1538. #define TF_DEATH_REVENGE 0x0004 // killer got revenge on victim
  1539. #define TF_DEATH_ASSISTER_REVENGE 0x0008 // assister got revenge on victim
  1540. #define TF_DEATH_FIRST_BLOOD 0x0010 // death triggered a first blood
  1541. #define TF_DEATH_FEIGN_DEATH 0x0020 // feign death
  1542. #define TF_DEATH_INTERRUPTED 0x0040 // interrupted a player doing an important game event (like capping or carrying flag)
  1543. #define TF_DEATH_GIBBED 0x0080 // player was gibbed
  1544. #define TF_DEATH_PURGATORY 0x0100 // player died while in purgatory
  1545. #define TF_DEATH_MINIBOSS 0x0200 // player killed was a miniboss
  1546. #define TF_DEATH_AUSTRALIUM 0x0400 // player killed by a Australium Weapon
  1547. #define MAX_DECAPITATIONS 4
  1548. extern const char *TranslateWeaponEntForClass( const char *pszName, int iClass );
  1549. // Item Giveaways
  1550. #define PLAYER_ROLL_MIN 1
  1551. #define PLAYER_ROLL_MAX 500
  1552. // Generalized Jump State
  1553. #define TF_PLAYER_ROCKET_JUMPED ( 1 << 0 )
  1554. #define TF_PLAYER_STICKY_JUMPED ( 1 << 1 )
  1555. #define TF_PLAYER_ENEMY_BLASTED_ME ( 1 << 2 )
  1556. enum taunts_t
  1557. {
  1558. TAUNT_BASE_WEAPON, // The standard taunt we shipped with. Taunts based on your currently held weapon
  1559. TAUNT_MISC_ITEM, // Taunts based on the item you have equipped in your Misc slot.
  1560. TAUNT_SHOW_ITEM, // Show off an item to everyone nearby
  1561. TAUNT_LONG, // Press-and-hold taunt
  1562. TAUNT_SPECIAL, // Special-case taunts called explicitly from code
  1563. //
  1564. // ADD NEW ITEMS HERE TO AVOID BREAKING DEMOS
  1565. //
  1566. };
  1567. enum eEurekaTeleportTargets
  1568. {
  1569. EUREKA_FIRST_TARGET = 0,
  1570. EUREKA_TELEPORT_HOME = 0,
  1571. EUREKA_TELEPORT_TELEPORTER_EXIT,
  1572. EUREKA_LAST_TARGET = EUREKA_TELEPORT_TELEPORTER_EXIT,
  1573. EUREKA_NUM_TARGETS
  1574. };
  1575. #define TF_HIGHFIVE_HINT_MASK ( 0x10100 ) // annotations have id ( TF_HIGHFIVE_HINT_MASK | entindex )
  1576. enum BombDeployingState_t
  1577. {
  1578. TF_BOMB_DEPLOYING_NONE,
  1579. TF_BOMB_DEPLOYING_DELAY,
  1580. TF_BOMB_DEPLOYING_ANIMATING,
  1581. TF_BOMB_DEPLOYING_COMPLETE,
  1582. TF_BOMB_DEPLOYING_NOT_COUNT,
  1583. };
  1584. enum EHorriblePyroVisionHack
  1585. {
  1586. kHorriblePyroVisionHack_KillAssisterType_Default = 0,
  1587. kHorriblePyroVisionHack_KillAssisterType_CustomName = 'a',
  1588. kHorriblePyroVisionHack_KillAssisterType_LocalizationString = 'b',
  1589. kHorriblePyroVisionHack_KillAssisterType_CustomName_First = 'c',
  1590. kHorriblePyroVisionHack_KillAssisterType_LocalizationString_First = 'd',
  1591. };
  1592. enum EAttackBonusEffects_t
  1593. {
  1594. kBonusEffect_None = 4, // Must be 4. Yep.
  1595. kBonusEffect_Crit = 0,
  1596. kBonusEffect_MiniCrit,
  1597. kBonusEffect_DoubleDonk,
  1598. kBonusEffect_WaterBalloonSploosh,
  1599. kBonusEffect_Count, // Must be 2nd to last
  1600. };
  1601. //-----------------------------------------------------------------------------
  1602. // PVE MODE
  1603. //-----------------------------------------------------------------------------
  1604. // In-game currency
  1605. enum CurrencyRewards_t
  1606. {
  1607. TF_CURRENCY_KILLED_PLAYER,
  1608. TF_CURRENCY_KILLED_OBJECT,
  1609. TF_CURRENCY_ASSISTED_PLAYER,
  1610. TF_CURRENCY_BONUS_POINTS,
  1611. TF_CURRENCY_CAPTURED_OBJECTIVE,
  1612. TF_CURRENCY_ESCORT_REWARD,
  1613. TF_CURRENCY_PACK_SMALL,
  1614. TF_CURRENCY_PACK_MEDIUM,
  1615. TF_CURRENCY_PACK_LARGE,
  1616. TF_CURRENCY_PACK_CUSTOM,
  1617. TF_CURRENCY_TIME_REWARD,
  1618. TF_CURRENCY_WAVE_COLLECTION_BONUS,
  1619. };
  1620. enum mvm_announcement_t
  1621. {
  1622. TF_MVM_ANNOUNCEMENT_WAVE_COMPLETE,
  1623. TF_MVM_ANNOUNCEMENT_WAVE_FAILED,
  1624. TF_MVM_ANNOUNCEMENT_TOTAL
  1625. };
  1626. #define RD_MAX_ROBOT_GROUPS_PER_TEAM 6
  1627. #define MAX_RAIDMODE_UPGRADES 60
  1628. enum mvm_upgrade_uigroups_t
  1629. {
  1630. UIGROUP_UPGRADE_ATTACHED_TO_ITEM = 0,
  1631. UIGROUP_UPGRADE_ATTACHED_TO_PLAYER,
  1632. UIGROUP_POWERUPBOTTLE,
  1633. };
  1634. enum
  1635. {
  1636. MVM_UPGRADE_QUALITY_LOW = 1,
  1637. MVM_UPGRADE_QUALITY_NORMAL, // Default
  1638. MVM_UPGRADE_QAULITY_HIGH,
  1639. };
  1640. #define MVM_BUYBACK_COST_PER_SEC 5
  1641. #define MVM_CLASS_TYPES_PER_WAVE_MAX 12
  1642. // this is ugly, but we need to increase the max types per wave and changing the old define will break demos
  1643. #define MVM_CLASS_TYPES_PER_WAVE_MAX_NEW ( MVM_CLASS_TYPES_PER_WAVE_MAX * 2 )
  1644. #define MVM_CLASS_FLAG_NONE 0
  1645. #define MVM_CLASS_FLAG_NORMAL (1<<0)
  1646. #define MVM_CLASS_FLAG_SUPPORT (1<<1)
  1647. #define MVM_CLASS_FLAG_MISSION (1<<2)
  1648. #define MVM_CLASS_FLAG_MINIBOSS (1<<3)
  1649. #define MVM_CLASS_FLAG_ALWAYSCRIT (1<<4)
  1650. #define MVM_CLASS_FLAG_SUPPORT_LIMITED (1<<5)
  1651. enum MedicCallerType
  1652. {
  1653. CALLER_TYPE_NORMAL,
  1654. CALLER_TYPE_AUTO,
  1655. CALLER_TYPE_REVIVE_EASY, // The more someone is revived, the harder
  1656. CALLER_TYPE_REVIVE_MEDIUM, // subsequent revives become.
  1657. CALLER_TYPE_REVIVE_HARD,
  1658. };
  1659. //-----------------------------------------------------------------------------
  1660. // Additional TF achievement packs
  1661. //-----------------------------------------------------------------------------
  1662. #define ACHIEVEMENT_TF_COMPLETE_TRAINING (ACHIEVEMENT_TF_LAST_ORANGEBOX + 1)
  1663. #define ACHIEVEMENT_TF_FIRE_WATERJUMP (ACHIEVEMENT_TF_LAST_ORANGEBOX + 2)
  1664. #define ACHIEVEMENT_TF_KILL_BALLOONICORN_OWNERS (ACHIEVEMENT_TF_LAST_ORANGEBOX + 3)
  1665. #define ACHIEVEMENT_TF_MULTIPLE_BFF (ACHIEVEMENT_TF_LAST_ORANGEBOX + 4)
  1666. #define ACHIEVEMENT_TF_TEAM_PYROVISION (ACHIEVEMENT_TF_LAST_ORANGEBOX + 5)
  1667. #define ACHIEVEMENT_TF_DOMINATE_FOR_GOGGLES (ACHIEVEMENT_TF_LAST_ORANGEBOX + 6)
  1668. #define ACHIEVEMENT_TF_PARACHUTE_KILL_GRIND (ACHIEVEMENT_TF_LAST_ORANGEBOX + 7)
  1669. #define ACHIEVEMENT_TF_MELEE_KILL_CLASSIC_RIFLE_SNIPER (ACHIEVEMENT_TF_LAST_ORANGEBOX + 8)
  1670. #define ACHIEVEMENT_TF_KILL_CHARGING_DEMO (ACHIEVEMENT_TF_LAST_ORANGEBOX + 9)
  1671. #define ACHIEVEMENT_TF_TAUNT_CONGA_KILL (ACHIEVEMENT_TF_LAST_ORANGEBOX + 10)
  1672. #define ACHIEVEMENT_TF_TAUNT_CONGA_LINE (ACHIEVEMENT_TF_LAST_ORANGEBOX + 11)
  1673. #define ACHIEVEMENT_TF_TAUNT_RPS_ROCK (ACHIEVEMENT_TF_LAST_ORANGEBOX + 12)
  1674. #define ACHIEVEMENT_TF_TAUNT_RPS_SCISSORS (ACHIEVEMENT_TF_LAST_ORANGEBOX + 13)
  1675. #define ACHIEVEMENT_TF_TAUNT_DOSIDO_MELLE_KILL (ACHIEVEMENT_TF_LAST_ORANGEBOX + 14)
  1676. #define ACHIEVEMENT_TF_TAUNT_WHILE_CAPPING (ACHIEVEMENT_TF_LAST_ORANGEBOX + 15)
  1677. #define ACHIEVEMENT_TF_PASS_TIME_HAT (ACHIEVEMENT_TF_LAST_ORANGEBOX + 16)
  1678. #define ACHIEVEMENT_TF_PASS_TIME_GRIND (ACHIEVEMENT_TF_LAST_ORANGEBOX + 17)
  1679. #define ACHIEVEMENT_START_CLASS_SPECIFIC 1000
  1680. // Scout
  1681. #define ACHIEVEMENT_TF_SCOUT_START_RANGE 1001
  1682. #define ACHIEVEMENT_TF_SCOUT_FIRST_BLOOD 1001
  1683. #define ACHIEVEMENT_TF_SCOUT_FIRST_BLOOD_KILL 1002
  1684. #define ACHIEVEMENT_TF_SCOUT_WELL_EARLY_KILL 1003
  1685. #define ACHIEVEMENT_TF_SCOUT_LIFETIME_KILLS 1004
  1686. #define ACHIEVEMENT_TF_SCOUT_IRON_MAN_KILLS 1005
  1687. #define ACHIEVEMENT_TF_SCOUT_DESTROY_TELEPORTERS 1006
  1688. #define ACHIEVEMENT_TF_SCOUT_DESTROY_BUILDINGS_BEING_BUILT 1007
  1689. #define ACHIEVEMENT_TF_SCOUT_DESTROY_SENTRY_WITH_PISTOL 1008
  1690. #define ACHIEVEMENT_TF_SCOUT_DOUBLE_JUMPS 1009
  1691. #define ACHIEVEMENT_TF_SCOUT_ASSIST_MEDIC 1010
  1692. #define ACHIEVEMENT_TF_SCOUT_STEAL_SANDWICH 1011
  1693. #define ACHIEVEMENT_TF_SCOUT_KILL_CHARGED_MEDICS 1012
  1694. #define ACHIEVEMENT_TF_SCOUT_SURVIVE_DAMAGE 1013
  1695. #define ACHIEVEMENT_TF_SCOUT_THREE_FLAGCAPS 1014
  1696. #define ACHIEVEMENT_TF_SCOUT_DOUBLEJUMP_KILL 1015
  1697. #define ACHIEVEMENT_TF_SCOUT_FLAG_CAP_GRIND 1016
  1698. #define ACHIEVEMENT_TF_SCOUT_DODGE_DAMAGE 1017
  1699. #define ACHIEVEMENT_TF_SCOUT_KNOCK_INTO_TRAIN 1018
  1700. #define ACHIEVEMENT_TF_SCOUT_KILL_STUNNED 1019
  1701. #define ACHIEVEMENT_TF_SCOUT_STUN_INTO_TRAIN 1020
  1702. #define ACHIEVEMENT_TF_SCOUT_STUN_UBER_ENEMIES 1021
  1703. #define ACHIEVEMENT_TF_SCOUT_STUN_CAPPING_ENEMIES 1022
  1704. #define ACHIEVEMENT_TF_SCOUT_MAX_STUNS 1023
  1705. #define ACHIEVEMENT_TF_SCOUT_STUN_SCOUT_WITH_THEIR_BALL 1024
  1706. #define ACHIEVEMENT_TF_SCOUT_KILL_IN_DODGE_COOLDOWN 1025
  1707. #define ACHIEVEMENT_TF_SCOUT_KILL_FROM_BEHIND 1026
  1708. #define ACHIEVEMENT_TF_SCOUT_CAPTURE_LAST_POINT 1027
  1709. #define ACHIEVEMENT_TF_SCOUT_CAPTURE_THREE_POINTS 1028
  1710. #define ACHIEVEMENT_TF_SCOUT_FAST_CAP 1029
  1711. #define ACHIEVEMENT_TF_SCOUT_START_AND_FINISH_CAP 1030
  1712. #define ACHIEVEMENT_TF_SCOUT_BLOCK_CAPS 1031
  1713. #define ACHIEVEMENT_TF_SCOUT_CARRIER_KILL_CARRIER 1032
  1714. #define ACHIEVEMENT_TF_SCOUT_CAP_FLAG_WITHOUT_ATTACKING 1033
  1715. #define ACHIEVEMENT_TF_SCOUT_LONG_DISTANCE_RUNNER 1034
  1716. #define ACHIEVEMENT_TF_SCOUT_TAUNT_KILL 1035
  1717. #define ACHIEVEMENT_TF_SCOUT_ACHIEVE_PROGRESS1 1036
  1718. #define ACHIEVEMENT_TF_SCOUT_ACHIEVE_PROGRESS2 1037
  1719. #define ACHIEVEMENT_TF_SCOUT_ACHIEVE_PROGRESS3 1038
  1720. #define ACHIEVEMENT_TF_SCOUT_BACKSCATTER_KILL_SPY_GRIND 1039
  1721. #define ACHIEVEMENT_TF_SCOUT_BACKSCATTER_KILL_HEAVY_MEDIC_PAIR 1040
  1722. #define ACHIEVEMENT_TF_SCOUT_BACKSCATTER_KILL_FRIENDS_GRIND 1041
  1723. #define ACHIEVEMENT_TF_SCOUT_END_RANGE 1041
  1724. // Sniper
  1725. #define ACHIEVEMENT_TF_SNIPER_START_RANGE 1101
  1726. #define ACHIEVEMENT_TF_SNIPER_JARATE_DOMINATED 1101
  1727. #define ACHIEVEMENT_TF_SNIPER_FREEZECAM_HAT 1102
  1728. #define ACHIEVEMENT_TF_SNIPER_RIFLE_NO_MISSING 1103
  1729. #define ACHIEVEMENT_TF_SNIPER_CAPTURE_FLAG 1104
  1730. #define ACHIEVEMENT_TF_SNIPER_KILL_GRIND 1105
  1731. #define ACHIEVEMENT_TF_SNIPER_KILL_WEAPONS 1106
  1732. #define ACHIEVEMENT_TF_SNIPER_HEADSHOT_SNIPERS 1107
  1733. #define ACHIEVEMENT_TF_SNIPER_DESTROY_SENTRYGUNS 1108
  1734. #define ACHIEVEMENT_TF_SNIPER_KILL_INVIS_SPY 1109
  1735. #define ACHIEVEMENT_TF_SNIPER_KILL_MIDAIR_SCOUT 1110
  1736. #define ACHIEVEMENT_TF_SNIPER_FREEZECAM_WAVE 1111
  1737. #define ACHIEVEMENT_TF_SNIPER_DOMINATE_SNIPER 1112
  1738. #define ACHIEVEMENT_TF_SNIPER_KILL_SPIES_MELEE 1113
  1739. #define ACHIEVEMENT_TF_SNIPER_HEADSHOT_DEMOMAN 1114
  1740. #define ACHIEVEMENT_TF_SNIPER_KILL_RJER 1115
  1741. #define ACHIEVEMENT_TF_SNIPER_KILL_OBJECTIVES 1116
  1742. #define ACHIEVEMENT_TF_SNIPER_KILL_UNSCOPED 1117
  1743. #define ACHIEVEMENT_TF_SNIPER_KILL_CHARGED_MEDIC 1118
  1744. #define ACHIEVEMENT_TF_SNIPER_GET_BACKSTABBED 1119
  1745. #define ACHIEVEMENT_TF_SNIPER_KILL_AT_ROUNDSTART 1120
  1746. #define ACHIEVEMENT_TF_SNIPER_HEADSHOT_POST_INVULN 1121
  1747. #define ACHIEVEMENT_TF_SNIPER_TOP_SCOREBOARD_GRIND 1122
  1748. #define ACHIEVEMENT_TF_SNIPER_KILL_FAILED_SPY 1123
  1749. #define ACHIEVEMENT_TF_SNIPER_JARATE_GROUP 1124
  1750. #define ACHIEVEMENT_TF_SNIPER_JARATE_MEDIC_PAIR 1125
  1751. #define ACHIEVEMENT_TF_SNIPER_JARATE_REVEAL_SPY 1126
  1752. #define ACHIEVEMENT_TF_SNIPER_JARATE_EXTINGUISH 1127
  1753. #define ACHIEVEMENT_TF_SNIPER_BOW_PIN_HEAVY 1128
  1754. #define ACHIEVEMENT_TF_SNIPER_BOW_KILL_MEDIC_PAIR 1129
  1755. #define ACHIEVEMENT_TF_SNIPER_BOW_KILL_FLAGCARRIER 1130
  1756. #define ACHIEVEMENT_TF_SNIPER_BOW_PINCUSHION 1131
  1757. #define ACHIEVEMENT_TF_SNIPER_JARATE_ASSISTS 1132
  1758. #define ACHIEVEMENT_TF_SNIPER_JARATE_KILL_MELEE 1133
  1759. #define ACHIEVEMENT_TF_SNIPER_TAUNT_KILL 1134
  1760. #define ACHIEVEMENT_TF_SNIPER_BOW_KILL_WHILEDEAD 1135
  1761. #define ACHIEVEMENT_TF_SNIPER_ACHIEVE_PROGRESS1 1136
  1762. #define ACHIEVEMENT_TF_SNIPER_ACHIEVE_PROGRESS2 1137
  1763. #define ACHIEVEMENT_TF_SNIPER_ACHIEVE_PROGRESS3 1138
  1764. #define ACHIEVEMENT_TF_SNIPER_CLASSIC_RIFLE_NOSCOPE_HEADSHOT 1139
  1765. #define ACHIEVEMENT_TF_SNIPER_CLASSIC_RIFLE_HEADSHOT_JUMPER 1140
  1766. #define ACHIEVEMENT_TF_SNIPER_CLASSIC_RIFLE_GIB_GRIND 1141
  1767. #define ACHIEVEMENT_TF_SNIPER_PARACHUTE_GRIND 1142
  1768. #define ACHIEVEMENT_TF_SNIPER_END_RANGE 1142
  1769. // Soldier
  1770. #define ACHIEVEMENT_TF_SOLDIER_START_RANGE 1201
  1771. #define ACHIEVEMENT_TF_SOLDIER_RJ_EQUALIZER_KILL 1201
  1772. #define ACHIEVEMENT_TF_SOLDIER_BUFF_TEAMMATES 1202
  1773. #define ACHIEVEMENT_TF_SOLDIER_KILL_DEMOMAN_GRIND 1203
  1774. #define ACHIEVEMENT_TF_SOLDIER_KILL_ENGY 1204
  1775. #define ACHIEVEMENT_TF_SOLDIER_KILL_PYRO 1205
  1776. #define ACHIEVEMENT_TF_SOLDIER_NEMESIS_SHOVEL_KILL 1206
  1777. #define ACHIEVEMENT_TF_SOLDIER_DESTROY_STICKIES 1207
  1778. #define ACHIEVEMENT_TF_SOLDIER_CROUCH_ROCKET_JUMP 1208
  1779. #define ACHIEVEMENT_TF_SOLDIER_EQUALIZER_STREAK 1209
  1780. #define ACHIEVEMENT_TF_SOLDIER_BUFF_FRIENDS 1210
  1781. #define ACHIEVEMENT_TF_SOLDIER_KILL_GROUP_WITH_CROCKET 1211
  1782. #define ACHIEVEMENT_TF_SOLDIER_KILL_TWO_DURING_ROCKET_JUMP 1212
  1783. #define ACHIEVEMENT_TF_SOLDIER_KILL_TAUNT 1213
  1784. #define ACHIEVEMENT_TF_SOLDIER_DEFEND_MEDIC 1214
  1785. #define ACHIEVEMENT_TF_SOLDIER_KILL_WITH_EQUALIZER_WHILE_HURT 1215
  1786. #define ACHIEVEMENT_TF_SOLDIER_KILL_AIRBORNE_TARGET_WHILE_AIRBORNE 1216
  1787. #define ACHIEVEMENT_TF_SOLDIER_BOUNCE_THEN_SHOTGUN 1217
  1788. #define ACHIEVEMENT_TF_SOLDIER_KILL_AIRBORNE_WITH_DIRECT_HIT 1218
  1789. #define ACHIEVEMENT_TF_SOLDIER_KILL_SNIPER_WHILE_DEAD 1219
  1790. #define ACHIEVEMENT_TF_SOLDIER_DESTROY_SENTRY_OUT_OF_RANGE 1220
  1791. #define ACHIEVEMENT_TF_SOLDIER_DUO_SOLDIER_KILLS 1221
  1792. #define ACHIEVEMENT_TF_SOLDIER_MVP 1222
  1793. #define ACHIEVEMENT_TF_SOLDIER_ASSIST_MEDIC_UBER 1223
  1794. #define ACHIEVEMENT_TF_SOLDIER_SHOOT_MULT_CRITS 1224
  1795. #define ACHIEVEMENT_TF_SOLDIER_KILL_DEFENSELESS 1225
  1796. #define ACHIEVEMENT_TF_SOLDIER_KILL_ON_FIRE 1226
  1797. #define ACHIEVEMENT_TF_SOLDIER_FREEZECAM_TAUNT 1227
  1798. #define ACHIEVEMENT_TF_SOLDIER_FREEZECAM_GIBS 1228
  1799. #define ACHIEVEMENT_TF_SOLDIER_KILL_SPY_KILLER 1229
  1800. #define ACHIEVEMENT_TF_SOLDIER_GIB_GRIND 1230
  1801. #define ACHIEVEMENT_TF_SOLDIER_THREE_DOMINATIONS 1231
  1802. #define ACHIEVEMENT_TF_SOLDIER_RIDE_THE_CART 1232
  1803. #define ACHIEVEMENT_TF_SOLDIER_KILL_TWENTY_FROM_ABOVE 1233
  1804. #define ACHIEVEMENT_TF_SOLDIER_KILL_FIVE_STUNNED 1234
  1805. #define ACHIEVEMENT_TF_SOLDIER_DEFEND_CAP_THIRTY_TIMES 1235
  1806. #define ACHIEVEMENT_TF_SOLDIER_ACHIEVE_PROGRESS1 1236
  1807. #define ACHIEVEMENT_TF_SOLDIER_ACHIEVE_PROGRESS2 1237
  1808. #define ACHIEVEMENT_TF_SOLDIER_ACHIEVE_PROGRESS3 1238
  1809. #define ACHIEVEMENT_TF_SOLDIER_PARACHUTE_KILL_GROUP 1239
  1810. #define ACHIEVEMENT_TF_SOLDIER_PARACHUTE_DISTANCE 1240
  1811. #define ACHIEVEMENT_TF_SOLDIER_PARACHUTE_KILL_PARACHUTE 1241
  1812. #define ACHIEVEMENT_TF_SOLDIER_AIRSTRIKE_MAX_CLIP 1242
  1813. #define ACHIEVEMENT_TF_SOLDIER_AIRSTRIKE_GROUP_KILL 1243
  1814. #define ACHIEVEMENT_TF_SOLDIER_END_RANGE 1243
  1815. // Demoman
  1816. #define ACHIEVEMENT_TF_DEMOMAN_START_RANGE 1301
  1817. #define ACHIEVEMENT_TF_DEMOMAN_KILL_SOLDIER_GRIND 1301
  1818. #define ACHIEVEMENT_TF_DEMOMAN_DESTROY_BUILDINGS_WITH_MEDIC 1302
  1819. #define ACHIEVEMENT_TF_DEMOMAN_DECAPITATE_CLOAKED_SPY 1303
  1820. #define ACHIEVEMENT_TF_DEMOMAN_KILL_X_WITH_DIRECTPIPE 1304
  1821. #define ACHIEVEMENT_TF_DEMOMAN_BOUNCE_AND_KILL 1305
  1822. #define ACHIEVEMENT_TF_DEMOMAN_KILL_TWO_DURING_STICKYJUMP 1306
  1823. #define ACHIEVEMENT_TF_DEMOMAN_KILL_PLAYER_AFTER_TP 1307
  1824. #define ACHIEVEMENT_TF_DEMOMAN_DOMINATE_THREE_ENGINEERS 1308
  1825. #define ACHIEVEMENT_TF_DEMOMAN_KILL_BUILDING_DIRECT_HIT 1309
  1826. #define ACHIEVEMENT_TF_DEMOMAN_DECAPITATE_PLAYERS 1310
  1827. #define ACHIEVEMENT_TF_DEMOMAN_DECAPITATE_PLAYERS_FAST 1311
  1828. #define ACHIEVEMENT_TF_DEMOMAN_DUO_DEMOMAN_KILLS 1312
  1829. #define ACHIEVEMENT_TF_DEMOMAN_MELEE_KILL_WHILE_STICKYJUMPING 1313
  1830. #define ACHIEVEMENT_TF_DEMOMAN_KILL_ENGI_SENTRY_DISPENSER 1314
  1831. #define ACHIEVEMENT_TF_DEMOMAN_DECAPITATE_EQUALIZER 1315
  1832. #define ACHIEVEMENT_TF_DEMOMAN_DECAPITATE_NEMESIS 1316
  1833. #define ACHIEVEMENT_TF_DEMOMAN_DAMAGE_GRIND 1317
  1834. #define ACHIEVEMENT_TF_DEMOMAN_KILL_X_CAPPING_ONEDET 1318
  1835. #define ACHIEVEMENT_TF_DEMOMAN_KILL_X_DEFENDING 1319
  1836. #define ACHIEVEMENT_TF_DEMOMAN_DESTROY_BUILDINGS_GRIND 1320
  1837. #define ACHIEVEMENT_TF_DEMOMAN_KILL_X_HEAVIES_FULLHP_ONEDET 1321
  1838. #define ACHIEVEMENT_TF_DEMOMAN_KILL_X_SCOUTS_PYROS 1322
  1839. #define ACHIEVEMENT_TF_DEMOMAN_TAUNT_KILL 1323
  1840. #define ACHIEVEMENT_TF_DEMOMAN_CHARGE_KILL 1324
  1841. #define ACHIEVEMENT_TF_DEMOMAN_CRIT_SWORD_KILL 1325
  1842. #define ACHIEVEMENT_TF_DEMOMAN_AIR_BURST_KILLS 1326
  1843. #define ACHIEVEMENT_TF_DEMOMAN_STICKYJUMP_CAP 1327
  1844. #define ACHIEVEMENT_TF_DEMOMAN_FREEZECAM_SMILE 1328
  1845. #define ACHIEVEMENT_TF_DEMOMAN_FREEZECAM_RUMP 1329
  1846. #define ACHIEVEMENT_TF_DEMOMAN_ENVIRONMENTAL_KILL 1330
  1847. #define ACHIEVEMENT_TF_DEMOMAN_DESTROY_X_STICKYBOMBS 1331
  1848. #define ACHIEVEMENT_TF_DEMOMAN_STICKJUMP_DISTANCE 1332
  1849. #define ACHIEVEMENT_TF_DEMOMAN_KILL3_WITH_DETONATION 1333
  1850. #define ACHIEVEMENT_TF_DEMOMAN_KILLXSAPPINGSPIES 1334
  1851. #define ACHIEVEMENT_TF_DEMOMAN_KILL3_WITH_PIPE_SETUPS 1335
  1852. #define ACHIEVEMENT_TF_DEMOMAN_ACHIEVE_PROGRESS1 1336
  1853. #define ACHIEVEMENT_TF_DEMOMAN_ACHIEVE_PROGRESS2 1337
  1854. #define ACHIEVEMENT_TF_DEMOMAN_ACHIEVE_PROGRESS3 1338
  1855. #define ACHIEVEMENT_TF_DEMOMAN_PARACHUTE_KILL_GROUP 1339
  1856. #define ACHIEVEMENT_TF_DEMOMAN_PARACHUTE_DISTANCE 1340
  1857. #define ACHIEVEMENT_TF_DEMOMAN_PARACHUTE_KILL_PARACHUTE 1341
  1858. #define ACHIEVEMENT_TF_DEMOMAN_KILL_PLAYER_YOU_DIDNT_SEE 1342
  1859. #define ACHIEVEMENT_TF_DEMOMAN_QUICK_KILLS 1343
  1860. #define ACHIEVEMENT_TF_DEMOMAN_CHARGE_KILL_CHARGING_DEMO 1344
  1861. #define ACHIEVEMENT_TF_DEMOMAN_END_RANGE 1344
  1862. // Medic
  1863. #define ACHIEVEMENT_TF_MEDIC_START_RANGE 1401
  1864. #define ACHIEVEMENT_TF_MEDIC_TOP_SCOREBOARD 1401
  1865. #define ACHIEVEMENT_TF_MEDIC_HEAL_UNDER_FIRE 1402
  1866. #define ACHIEVEMENT_TF_MEDIC_SIMUL_CHARGE 1403
  1867. #define ACHIEVEMENT_TF_MEDIC_SETUP_CHARGE 1404
  1868. #define ACHIEVEMENT_TF_MEDIC_RAPID_CHARGE 1405
  1869. #define ACHIEVEMENT_TF_MEDIC_COUNTER_CHARGE 1406
  1870. #define ACHIEVEMENT_TF_MEDIC_SWITCH_TO_MEDIC 1407
  1871. #define ACHIEVEMENT_TF_MEDIC_SAVE_TEAMMATE 1408
  1872. #define ACHIEVEMENT_TF_MEDIC_CHARGE_BLOCKER 1409
  1873. #define ACHIEVEMENT_TF_MEDIC_ASSIST_MEDIC 1410
  1874. #define ACHIEVEMENT_TF_MEDIC_SYRINGE_SCOUTS 1411
  1875. #define ACHIEVEMENT_TF_MEDIC_BONESAW_MEDICS 1412
  1876. #define ACHIEVEMENT_TF_MEDIC_ASSIST_HEAVY_LONG 1413
  1877. #define ACHIEVEMENT_TF_MEDIC_ASSIST_SCOUT 1414
  1878. #define ACHIEVEMENT_TF_MEDIC_ASSIST_PYRO 1415
  1879. #define ACHIEVEMENT_TF_MEDIC_ASSIST_HEAVY 1416
  1880. #define ACHIEVEMENT_TF_MEDIC_ASSIST_DEMOMAN 1417
  1881. #define ACHIEVEMENT_TF_MEDIC_ASSIST_SOLDIER 1418
  1882. #define ACHIEVEMENT_TF_MEDIC_HEAL_ENGINEER 1419
  1883. #define ACHIEVEMENT_TF_MEDIC_ASSIST_CAPTURER 1420
  1884. #define ACHIEVEMENT_TF_MEDIC_HEAL_CALLERS 1421
  1885. #define ACHIEVEMENT_TF_MEDIC_EXTINGUISH_TEAMMATES 1422
  1886. #define ACHIEVEMENT_TF_MEDIC_ASSIST_VS_NEMESES 1423
  1887. #define ACHIEVEMENT_TF_MEDIC_KILL_WHILE_CHARGED 1424
  1888. #define ACHIEVEMENT_TF_MEDIC_BONESAW_NOMISSES 1425
  1889. #define ACHIEVEMENT_TF_MEDIC_HEAL_LARGE 1426
  1890. #define ACHIEVEMENT_TF_MEDIC_HEAL_HUGE 1427
  1891. #define ACHIEVEMENT_TF_MEDIC_HEAL_GRIND 1428
  1892. #define ACHIEVEMENT_TF_MEDIC_KILL_HEALED_SPY 1429
  1893. #define ACHIEVEMENT_TF_MEDIC_SAVE_FALLING_TEAMMATE 1430
  1894. #define ACHIEVEMENT_TF_MEDIC_CHARGE_JUGGLE 1431
  1895. #define ACHIEVEMENT_TF_MEDIC_FREEZECAM_RAGDOLL 1432
  1896. #define ACHIEVEMENT_TF_MEDIC_BONESAW_SPY_CALLERS 1433
  1897. #define ACHIEVEMENT_TF_MEDIC_CHARGE_FRIENDS 1434
  1898. #define ACHIEVEMENT_TF_MEDIC_INVITE_JOIN_CHARGE 1435
  1899. #define ACHIEVEMENT_TF_MEDIC_HEAL_ACHIEVER 1436
  1900. #define ACHIEVEMENT_TF_MEDIC_ACHIEVE_PROGRESS1 1437
  1901. #define ACHIEVEMENT_TF_MEDIC_ACHIEVE_PROGRESS2 1438
  1902. #define ACHIEVEMENT_TF_MEDIC_ACHIEVE_PROGRESS3 1439
  1903. #define ACHIEVEMENT_TF_MEDIC_END_RANGE 1439
  1904. // Heavy
  1905. #define ACHIEVEMENT_TF_HEAVY_START_RANGE 1501
  1906. #define ACHIEVEMENT_TF_HEAVY_DAMAGE_TAKEN 1501
  1907. #define ACHIEVEMENT_TF_HEAVY_DEFEND_MEDIC 1502
  1908. #define ACHIEVEMENT_TF_HEAVY_ASSIST_MEDIC_LARGE 1503
  1909. #define ACHIEVEMENT_TF_HEAVY_EARN_MEDIC_DOMINATION 1504
  1910. #define ACHIEVEMENT_TF_HEAVY_KILL_TAUNT 1505
  1911. #define ACHIEVEMENT_TF_HEAVY_KILL_FLAG_CARRIERS 1506
  1912. #define ACHIEVEMENT_TF_HEAVY_KILL_MEDIC_PAIR 1507
  1913. #define ACHIEVEMENT_TF_HEAVY_BLOCK_INVULN_HEAVY 1508
  1914. #define ACHIEVEMENT_TF_HEAVY_BLOCK_CART 1509
  1915. #define ACHIEVEMENT_TF_HEAVY_RECEIVE_UBER_GRIND 1510
  1916. #define ACHIEVEMENT_TF_HEAVY_STAND_NEAR_DISPENSER 1511
  1917. #define ACHIEVEMENT_TF_HEAVY_ASSIST_HEAVY_GRIND 1512
  1918. #define ACHIEVEMENT_TF_HEAVY_CLEAR_STICKYBOMBS 1513
  1919. #define ACHIEVEMENT_TF_HEAVY_KILL_UNDERWATER 1514
  1920. #define ACHIEVEMENT_TF_HEAVY_TAKE_MULTI_DAMAGE 1515
  1921. #define ACHIEVEMENT_TF_HEAVY_KILL_DOMINATED 1516
  1922. #define ACHIEVEMENT_TF_HEAVY_SURVIVE_CROCKET 1517
  1923. #define ACHIEVEMENT_TF_HEAVY_ASSIST_GRIND 1518
  1924. #define ACHIEVEMENT_TF_HEAVY_UNCOVER_SPIES 1519
  1925. #define ACHIEVEMENT_TF_HEAVY_KILL_WHILE_SPUNUP 1520
  1926. #define ACHIEVEMENT_TF_HEAVY_FIRE_LOTS 1521
  1927. #define ACHIEVEMENT_TF_HEAVY_KILL_CRIT_PUNCH 1522
  1928. #define ACHIEVEMENT_TF_HEAVY_HEAL_MEDIKITS 1523
  1929. #define ACHIEVEMENT_TF_HEAVY_KILL_SHOTGUN 1524
  1930. #define ACHIEVEMENT_TF_HEAVY_FIRST_TO_CAP 1525
  1931. #define ACHIEVEMENT_TF_HEAVY_PAYLOAD_CAP_GRIND 1526
  1932. #define ACHIEVEMENT_TF_HEAVY_KILL_MIDAIR_MINIGUN 1527
  1933. #define ACHIEVEMENT_TF_HEAVY_DEFEND_CONTROL_POINT 1528
  1934. #define ACHIEVEMENT_TF_HEAVY_KILL_CAPPING_ENEMIES 1529
  1935. #define ACHIEVEMENT_TF_HEAVY_REVENGE_ASSIST 1530
  1936. #define ACHIEVEMENT_TF_HEAVY_TELEPORT_FAST_KILL 1531
  1937. #define ACHIEVEMENT_TF_HEAVY_FREEZECAM_TAUNT 1532
  1938. #define ACHIEVEMENT_TF_HEAVY_EAT_SANDWICHES 1533
  1939. #define ACHIEVEMENT_TF_HEAVY_KILL_SCOUTS 1534
  1940. #define ACHIEVEMENT_TF_HEAVY_KILL_HEAVIES_GLOVES 1535
  1941. #define ACHIEVEMENT_TF_HEAVY_ACHIEVE_PROGRESS1 1537
  1942. #define ACHIEVEMENT_TF_HEAVY_ACHIEVE_PROGRESS2 1538
  1943. #define ACHIEVEMENT_TF_HEAVY_ACHIEVE_PROGRESS3 1539
  1944. #define ACHIEVEMENT_TF_HEAVY_END_RANGE 1539
  1945. // Pyro
  1946. #define ACHIEVEMENT_TF_PYRO_START_RANGE 1601
  1947. #define ACHIEVEMENT_TF_PYRO_KILL_MULTIWEAPONS 1601
  1948. #define ACHIEVEMENT_TF_PYRO_SIMULBURN_SCOUTS 1602
  1949. #define ACHIEVEMENT_TF_PYRO_FORCE_WATERJUMP 1603
  1950. #define ACHIEVEMENT_TF_PYRO_KILL_POSTDEATH 1604
  1951. #define ACHIEVEMENT_TF_PYRO_KILL_SPIES 1605
  1952. #define ACHIEVEMENT_TF_PYRO_KILL_CARRIERS 1606
  1953. #define ACHIEVEMENT_TF_PYRO_REVEAL_SPIES 1607
  1954. #define ACHIEVEMENT_TF_PYRO_CAMP_TELEPORTERS 1608
  1955. #define ACHIEVEMENT_TF_PYRO_CAMP_POSITION 1609
  1956. #define ACHIEVEMENT_TF_PYRO_KILL_AXE_SMALL 1610
  1957. #define ACHIEVEMENT_TF_PYRO_KILL_AXE_LARGE 1611
  1958. #define ACHIEVEMENT_TF_PYRO_KILL_FROM_BEHIND 1612
  1959. #define ACHIEVEMENT_TF_PYRO_BURN_SPIES_AS_YOU 1613
  1960. #define ACHIEVEMENT_TF_PYRO_BURN_SNIPERS_ZOOMED 1614
  1961. #define ACHIEVEMENT_TF_PYRO_BURN_MEDICS_CHARGED 1615
  1962. #define ACHIEVEMENT_TF_PYRO_REFLECT_PROJECTILES 1616
  1963. #define ACHIEVEMENT_TF_PYRO_KILL_HEAVIES 1617
  1964. #define ACHIEVEMENT_TF_PYRO_KILL_UNDERWATER 1618
  1965. #define ACHIEVEMENT_TF_PYRO_KILL_UBERCHARGE 1619
  1966. #define ACHIEVEMENT_TF_PYRO_DESTROY_BUILDINGS 1620
  1967. #define ACHIEVEMENT_TF_PYRO_DEFEND_POINTS 1621
  1968. #define ACHIEVEMENT_TF_PYRO_KILL_GRIND 1622
  1969. #define ACHIEVEMENT_TF_PYRO_DAMAGE_GRIND 1623
  1970. #define ACHIEVEMENT_TF_PYRO_BURN_MEDICPAIR 1624
  1971. #define ACHIEVEMENT_TF_PYRO_KILL_TAUNT 1625
  1972. #define ACHIEVEMENT_TF_PYRO_KILL_TEAMWORK 1626
  1973. #define ACHIEVEMENT_TF_PYRO_BURN_SPY_TAUNT 1627
  1974. #define ACHIEVEMENT_TF_PYRO_DOMINATE_LEAVESVR 1628
  1975. #define ACHIEVEMENT_TF_PYRO_REFLECT_CROCKET_KILL 1629
  1976. #define ACHIEVEMENT_TF_PYRO_KILL_TAUNTERS 1630
  1977. #define ACHIEVEMENT_TF_PYRO_DOUBLE_KO 1631
  1978. #define ACHIEVEMENT_TF_PYRO_BURN_RJ_SOLDIER 1632
  1979. #define ACHIEVEMENT_TF_PYRO_FREEZECAM_TAUNTS 1633
  1980. #define ACHIEVEMENT_TF_PYRO_KILL_GRIND_LARGE 1634
  1981. #define ACHIEVEMENT_TF_PYRO_IGNITE_FLAREGUN 1635
  1982. #define ACHIEVEMENT_TF_PYRO_ACHIEVE_PROGRESS1 1637
  1983. #define ACHIEVEMENT_TF_PYRO_ACHIEVE_PROGRESS2 1638
  1984. #define ACHIEVEMENT_TF_PYRO_ACHIEVE_PROGRESS3 1639
  1985. #define ACHIEVEMENT_TF_PYRO_IGNITE_WITH_RAINBOW 1640
  1986. #define ACHIEVEMENT_TF_PYRO_IGNITE_PLAYER_BEING_FLIPPED 1641
  1987. #define ACHIEVEMENT_TF_PYRO_END_RANGE 1641
  1988. // Spy
  1989. #define ACHIEVEMENT_TF_SPY_START_RANGE 1701
  1990. #define ACHIEVEMENT_TF_SPY_BACKSTAB_SNIPERS 1701
  1991. #define ACHIEVEMENT_TF_SPY_FREEZECAM_FLICK 1702
  1992. #define ACHIEVEMENT_TF_SPY_BACKSTAB_DISGUISED_SPY 1703
  1993. #define ACHIEVEMENT_TF_SPY_BACKSTAB_DISGUISE_TARGET 1704
  1994. #define ACHIEVEMENT_TF_SPY_TAUNT_KILL 1705
  1995. #define ACHIEVEMENT_TF_SPY_BACKSTAB_MEDIC_HEALING_YOU 1706
  1996. #define ACHIEVEMENT_TF_SPY_BACKSTAB_ENGY_SAP_BUILDING 1707
  1997. #define ACHIEVEMENT_TF_SPY_SAP_BUILDING_BACKSTAB_ENGY 1708
  1998. #define ACHIEVEMENT_TF_SPY_BACKSTAB_MEDIC_PAIR 1709
  1999. #define ACHIEVEMENT_TF_SPY_BACKSTAB_FRIENDS 1710
  2000. #define ACHIEVEMENT_TF_SPY_DOMINATE_SNIPER 1711
  2001. #define ACHIEVEMENT_TF_SPY_BUMP_CLOAKED_SPY 1712
  2002. #define ACHIEVEMENT_TF_SPY_KILL_SPY_WITH_KNIFE 1713
  2003. #define ACHIEVEMENT_TF_SPY_SURVIVE_BURNING 1714
  2004. #define ACHIEVEMENT_TF_SPY_BREAK_SHIELD_KILL_SNIPER 1715
  2005. #define ACHIEVEMENT_TF_SPY_KILL_WORKING_ENGY 1716
  2006. #define ACHIEVEMENT_TF_SPY_FAST_CAP 1717
  2007. #define ACHIEVEMENT_TF_SPY_MEDIC_HEALING_KILL_ENEMY 1718
  2008. #define ACHIEVEMENT_TF_SPY_KILL_CP_DEFENDERS 1719
  2009. #define ACHIEVEMENT_TF_SPY_BACKSTAB_DOMINATING_ENEMY 1720
  2010. #define ACHIEVEMENT_TF_SPY_REVENGE_WITH_BACKSTAB 1721
  2011. #define ACHIEVEMENT_TF_SPY_KNIFE_KILL_WHILE_JARATED 1722
  2012. #define ACHIEVEMENT_TF_SPY_BACKSTAB_QUICK_KILLS 1723
  2013. #define ACHIEVEMENT_TF_SPY_BACKSTAB_GRIND 1724
  2014. #define ACHIEVEMENT_TF_SPY_SAPPER_GRIND 1725
  2015. #define ACHIEVEMENT_TF_SPY_SAPPER_TEAMWORK 1726
  2016. #define ACHIEVEMENT_TF_SPY_BACKSTAB_MEDIC_CHARGED 1727
  2017. #define ACHIEVEMENT_TF_SPY_BACKSTAB_CAPPING_ENEMIES 1728
  2018. #define ACHIEVEMENT_TF_SPY_BACKSTAB_ENEMY_SWITCH_PYRO 1729
  2019. #define ACHIEVEMENT_TF_SPY_AMBASSADOR_GRIND 1730
  2020. #define ACHIEVEMENT_TF_SPY_AMBASSADOR_SNIPER_GRIND 1731
  2021. #define ACHIEVEMENT_TF_SPY_FEIGN_DEATH_KILL 1732
  2022. #define ACHIEVEMENT_TF_SPY_AMBASSADOR_SCOUT_GRIND 1733
  2023. #define ACHIEVEMENT_TF_SPY_CAMP_POSITION 1734
  2024. #define ACHIEVEMENT_TF_SPY_ACHIEVE_PROGRESS1 1735
  2025. #define ACHIEVEMENT_TF_SPY_ACHIEVE_PROGRESS2 1736
  2026. #define ACHIEVEMENT_TF_SPY_ACHIEVE_PROGRESS3 1737
  2027. #define ACHIEVEMENT_TF_SPY_KILL_BACKSCATTER_SCOUT 1738
  2028. #define ACHIEVEMENT_TF_SPY_END_RANGE 1738
  2029. // Engineer
  2030. #define ACHIEVEMENT_TF_ENGINEER_START_RANGE 1801
  2031. #define ACHIEVEMENT_TF_ENGINEER_ACHIEVE_PROGRESS1 1801
  2032. #define ACHIEVEMENT_TF_ENGINEER_ACHIEVE_PROGRESS2 1802
  2033. #define ACHIEVEMENT_TF_ENGINEER_ACHIEVE_PROGRESS3 1803
  2034. #define ACHIEVEMENT_TF_ENGINEER_REVENGE_CRIT_SENTRY_KILLER 1804
  2035. #define ACHIEVEMENT_TF_ENGINEER_TELEPORT_GRIND 1805
  2036. #define ACHIEVEMENT_TF_ENGINEER_DISPENSER_EXTINGUISH 1806
  2037. #define ACHIEVEMENT_TF_ENGINEER_MANUAL_CLOAKED_SPY_KILL 1807
  2038. #define ACHIEVEMENT_TF_ENGINEER_REVENGE_CRIT_LIFE 1808
  2039. #define ACHIEVEMENT_TF_ENGINEER_MANUAL_SENTRY_ABSORB_DMG 1809
  2040. #define ACHIEVEMENT_TF_ENGINEER_MANUAL_SENTRY_KILLS_BEYOND_RANGE 1810
  2041. #define ACHIEVEMENT_TF_ENGINEER_UPGRADE_BUILDINGS 1811
  2042. #define ACHIEVEMENT_TF_ENGINEER_DISPENSER_HEAL_GROUP 1812
  2043. #define ACHIEVEMENT_TF_ENGINEER_SENTRY_KILL_LIFETIME_GRIND 1813
  2044. #define ACHIEVEMENT_TF_ENGINEER_WASTE_METAL_GRIND 1814
  2045. #define ACHIEVEMENT_TF_ENGINEER_KILL_FLAG_CARRIERS 1815
  2046. #define ACHIEVEMENT_TF_ENGINEER_KILL_DISGUISED_SPY 1816
  2047. #define ACHIEVEMENT_TF_ENGINEER_HELP_BUILD_STRUCTURE 1817
  2048. #define ACHIEVEMENT_TF_ENGINEER_FREEZECAM_TAUNT 1818
  2049. #define ACHIEVEMENT_TF_ENGINEER_FREEZECAM_SENTRY 1819
  2050. #define ACHIEVEMENT_TF_ENGINEER_SHOTGUN_KILL_PREV_SENTRY_TARGET 1820
  2051. #define ACHIEVEMENT_TF_ENGINEER_SENTRY_AVENGES_YOU 1821
  2052. #define ACHIEVEMENT_TF_ENGINEER_REPAIR_SENTRY_W_MEDIC 1822
  2053. #define ACHIEVEMENT_TF_ENGINEER_SENTRY_KILL_CAPS 1823
  2054. #define ACHIEVEMENT_TF_ENGINEER_DESTROY_SAPPERS 1824
  2055. #define ACHIEVEMENT_TF_ENGINEER_KILL_SPY_TWO_SAPPERS 1825
  2056. #define ACHIEVEMENT_TF_ENGINEER_REMOVE_SAPPER_LONG_DIST 1826
  2057. #define ACHIEVEMENT_TF_ENGINEER_TAUNT_KILL 1827
  2058. #define ACHIEVEMENT_TF_ENGINEER_DESTROY_STICKIES 1828
  2059. #define ACHIEVEMENT_TF_ENGINEER_HELP_MANUAL_SENTRY 1829
  2060. #define ACHIEVEMENT_TF_ENGINEER_KILL_SNIPERS_SENTRY 1830
  2061. #define ACHIEVEMENT_TF_ENGINEER_KILL_SENTRY_WITH_SENTRY 1831
  2062. #define ACHIEVEMENT_TF_ENGINEER_MOVE_SENTRY_GET_KILL 1832
  2063. #define ACHIEVEMENT_TF_ENGINEER_BUILDING_CARRY 1833
  2064. #define ACHIEVEMENT_TF_ENGINEER_KILL_ASSIST 1834
  2065. #define ACHIEVEMENT_TF_ENGINEER_DISPENSER_HEAL_GRIND 1835
  2066. #define ACHIEVEMENT_TF_ENGINEER_REPAIR_TEAM_GRIND 1836
  2067. #define ACHIEVEMENT_TF_ENGINEER_TANK_DAMAGE 1837
  2068. #define ACHIEVEMENT_TF_ENGINEER_HEAVY_ASSIST 1838
  2069. #define ACHIEVEMENT_TF_ENGINEER_END_RANGE 1838
  2070. #define ACHIEVEMENT_END_CLASS_SPECIFIC 1899
  2071. // Halloween Events
  2072. #define ACHIEVEMENT_TF_HALLOWEEN_START_RANGE 1901
  2073. #define ACHIEVEMENT_TF_HALLOWEEN_COLLECT_PUMPKINS 1901
  2074. #define ACHIEVEMENT_TF_HALLOWEEN_DOMINATE_FOR_HAT 1902
  2075. #define ACHIEVEMENT_TF_HALLOWEEN_KILL_SCARED_PLAYER 1903
  2076. #define ACHIEVEMENT_TF_HALLOWEEN_PUMPKIN_KILL 1904
  2077. #define ACHIEVEMENT_TF_HALLOWEEN_DISGUISED_SPY_KILL 1905
  2078. #define ACHIEVEMENT_TF_HALLOWEEN_BOSS_KILL 1906
  2079. #define ACHIEVEMENT_TF_HALLOWEEN_COLLECT_GOODY_BAG 1907
  2080. #define ACHIEVEMENT_TF_HALLOWEEN_CRAFT_SAXTON_MASK 1908
  2081. #define ACHIEVEMENT_TF_HALLOWEEN_BOSS_KILL_MELEE 1909
  2082. #define ACHIEVEMENT_TF_HALLOWEEN_EYEBOSS_KILL 1910
  2083. #define ACHIEVEMENT_TF_HALLOWEEN_LOOT_ISLAND 1911
  2084. #define ACHIEVEMENT_TF_HALLOWEEN_MERASMUS_COLLECT_LOOT 1912
  2085. #define ACHIEVEMENT_TF_HALLOWEEN_MERASMUS_KILL 1913
  2086. // These six achievements are part of the milestone for Helltower. Order matters here.
  2087. #define ACHIEVEMENT_TF_HALLOWEEN_HELLTOWER_RARE_SPELL 1914
  2088. #define ACHIEVEMENT_TF_HALLOWEEN_HELLTOWER_WIN_ROUNDS 1915
  2089. #define ACHIEVEMENT_TF_HALLOWEEN_HELLTOWER_ENVIRONMENTAL_KILLS 1916
  2090. #define ACHIEVEMENT_TF_HALLOWEEN_HELLTOWER_SKELETON_GRIND 1917
  2091. #define ACHIEVEMENT_TF_HALLOWEEN_HELLTOWER_KILL_GRIND 1918
  2092. #define ACHIEVEMENT_TF_HALLOWEEN_HELLTOWER_KILL_BROTHERS 1919
  2093. // This is the milestone for Helltower. Order matters here. 4/6 of the above achievements are required.
  2094. #define ACHIEVEMENT_TF_HALLOWEEN_HELLTOWER_MILESTONE 1920
  2095. #define ACHIEVEMENT_TF_HALLOWEEN_HELLTOWER_SKULL_ISLAND_REWARD 1921
  2096. // These six achievements are part of the milestone for Doomsday. Order matters here.
  2097. #define ACHIEVEMENT_TF_HALLOWEEN_DOOMSDAY_KILL_KARTS 1922
  2098. #define ACHIEVEMENT_TF_HALLOWEEN_DOOMSDAY_COLLECT_DUCKS 1923
  2099. #define ACHIEVEMENT_TF_HALLOWEEN_DOOMSDAY_SCORE_GOALS 1924
  2100. #define ACHIEVEMENT_TF_HALLOWEEN_DOOMSDAY_RESPAWN_TEAMMATES 1925
  2101. #define ACHIEVEMENT_TF_HALLOWEEN_DOOMSDAY_TINY_SMASHER 1926
  2102. #define ACHIEVEMENT_TF_HALLOWEEN_DOOMSDAY_WIN_MINIGAMES 1927
  2103. // This is the milestone for Doomsday. Order matters here. 4/6 of the above achievements are required.
  2104. #define ACHIEVEMENT_TF_HALLOWEEN_DOOMSDAY_MILESTONE 1928
  2105. #define ACHIEVEMENT_TF_HALLOWEEN_END_RANGE 1928
  2106. // Replay Achievements
  2107. #define ACHIEVEMENT_TF_REPLAY_START_RANGE 2001
  2108. #define ACHIEVEMENT_TF_REPLAY_SAVE_REPLAY 2001
  2109. #define ACHIEVEMENT_TF_REPLAY_PERFORMANCE_MODE 2002
  2110. #define ACHIEVEMENT_TF_REPLAY_BROWSE_REPLAYS 2003
  2111. #define ACHIEVEMENT_TF_REPLAY_EDIT_TIME 2004
  2112. #define ACHIEVEMENT_TF_REPLAY_YOUTUBE_VIEWS_TIER1 2005
  2113. #define ACHIEVEMENT_TF_REPLAY_YOUTUBE_VIEWS_TIER2 2006
  2114. #define ACHIEVEMENT_TF_REPLAY_YOUTUBE_VIEWS_TIER3 2007
  2115. #define ACHIEVEMENT_TF_REPLAY_YOUTUBE_VIEWS_HIGHEST 2008
  2116. #define ACHIEVEMENT_TF_REPLAY_END_RANGE 2008
  2117. // Christmas Event
  2118. #define ACHIEVEMENT_TF_CHRISTMAS_START_RANGE 2101
  2119. #define ACHIEVEMENT_TF_CHRISTMAS_COLLECT_GIFTS 2101
  2120. #define ACHIEVEMENT_TF_CHRISTMAS_END_RANGE 2101
  2121. // Foundry Achievements
  2122. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_START_RANGE 2201
  2123. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_KILL_CAPPING_ENEMY 2201
  2124. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_PLAY_GAME_FRIENDS 2202
  2125. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_WIN_MINTIME 2203
  2126. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_WIN_ROUNDS 2204
  2127. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_FAST_FINAL_CAP 2205
  2128. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_TELEPORT_AND_CAP 2206
  2129. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_PUSH_INTO_CAULDRON 2207
  2130. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_PUSH_BACK_AND_WIN 2208
  2131. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_PLAY_EACH_CLASS 2209
  2132. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_KILL_ENEMY_ON_ROOF 2210
  2133. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_BACK_AND_FORTH_BATTLE 2211
  2134. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_ACHIEVE_PROGRESS1 2212
  2135. #define ACHIEVEMENT_TF_MAPS_FOUNDRY_END_RANGE 2212
  2136. // MvM Achievements
  2137. #define ACHIEVEMENT_TF_MVM_START_RANGE 2301
  2138. #define ACHIEVEMENT_TF_MVM_COMPLETE_POP_FILE 2301
  2139. #define ACHIEVEMENT_TF_MVM_EARN_MONEY_BONUS 2302
  2140. #define ACHIEVEMENT_TF_MVM_ADVANCED_EARN_ALL_BONUSES 2303
  2141. #define ACHIEVEMENT_TF_MVM_PICKUP_MONEY_ABOUT_TO_EXPIRE 2304
  2142. #define ACHIEVEMENT_TF_MVM_COLLECT_MONEY_GRIND 2305
  2143. #define ACHIEVEMENT_TF_MVM_PLAY_GAME_FRIENDS 2306
  2144. #define ACHIEVEMENT_TF_MVM_PLAY_EACH_CLASS 2307
  2145. #define ACHIEVEMENT_TF_MVM_DESTROY_TWO_TANKS 2308
  2146. #define ACHIEVEMENT_TF_MVM_DESTROY_TANK_WHILE_DEPLOYING 2309
  2147. #define ACHIEVEMENT_TF_MVM_DESTROY_TANK_QUICKLY 2310
  2148. #define ACHIEVEMENT_TF_MVM_DEFEND_CAP 2311
  2149. #define ACHIEVEMENT_TF_MVM_KILL_BOMB_CARRIERS 2312
  2150. #define ACHIEVEMENT_TF_MVM_COMPLETE_WAVE_WITHOUT_DYING 2313
  2151. #define ACHIEVEMENT_TF_MVM_COMPLETE_TOUR 2314
  2152. #define ACHIEVEMENT_TF_MVM_USE_TELEPORT_BOTTLE 2315
  2153. #define ACHIEVEMENT_TF_MVM_USE_CRIT_BOTTLE 2316
  2154. #define ACHIEVEMENT_TF_MVM_USE_UBER_BOTTLE 2317
  2155. #define ACHIEVEMENT_TF_MVM_USE_BUILD_BOTTLE 2318
  2156. #define ACHIEVEMENT_TF_MVM_USE_AMMO_BOTTLE 2319
  2157. #define ACHIEVEMENT_TF_MVM_MAX_PRIMARY_UPGRADES 2320
  2158. #define ACHIEVEMENT_TF_MVM_MAX_PLAYER_RESISTANCES 2321
  2159. #define ACHIEVEMENT_TF_MVM_NO_ALARMS_IN_FINAL_WAVE 2322
  2160. #define ACHIEVEMENT_TF_MVM_KILL_MEDICS_CHARGED 2323
  2161. #define ACHIEVEMENT_TF_MVM_KILL_ROBOT_GRIND 2324
  2162. #define ACHIEVEMENT_TF_MVM_KILL_ROBOT_MEGA_GRIND 2325
  2163. #define ACHIEVEMENT_TF_MVM_KILL_SENTRY_BUSTER 2326
  2164. #define ACHIEVEMENT_TF_MVM_SPY_SAP_ROBOTS 2327
  2165. #define ACHIEVEMENT_TF_MVM_SOLDIER_BUFF_TEAM 2328
  2166. #define ACHIEVEMENT_TF_MVM_HEAVY_RAGE_PUSH_DEPLOYING_ROBOT 2329
  2167. #define ACHIEVEMENT_TF_MVM_MEDIC_SHARE_BOTTLES 2330
  2168. #define ACHIEVEMENT_TF_MVM_DEMO_GROUP_KILL 2331
  2169. #define ACHIEVEMENT_TF_MVM_SCOUT_MARK_FOR_DEATH 2332
  2170. #define ACHIEVEMENT_TF_MVM_SNIPER_KILL_GROUP 2333
  2171. #define ACHIEVEMENT_TF_MVM_PYRO_BOMB_RESET 2334
  2172. #define ACHIEVEMENT_TF_MVM_ENGINEER_ESCAPE_SENTRY_BUSTER 2335
  2173. #define ACHIEVEMENT_TF_MVM_ACHIEVE_PROGRESS1 2336
  2174. #define ACHIEVEMENT_TF_MVM_ACHIEVE_PROGRESS2 2337
  2175. #define ACHIEVEMENT_TF_MVM_ACHIEVE_PROGRESS3 2338
  2176. #define ACHIEVEMENT_TF_MVM_MAPS_ROTTENBURG_TANK 2339
  2177. #define ACHIEVEMENT_TF_MVM_MAPS_ROTTENBURG_BOMB 2340
  2178. #define ACHIEVEMENT_TF_MVM_MAPS_ROTTENBURG_PIT_GRIND 2341
  2179. #define ACHIEVEMENT_TF_MVM_MAPS_MANNHATTAN_PIT 2342
  2180. #define ACHIEVEMENT_TF_MVM_MAPS_MANNHATTAN_MYSTERY 2343
  2181. #define ACHIEVEMENT_TF_MVM_MAPS_MANNHATTAN_NO_GATES 2344
  2182. #define ACHIEVEMENT_TF_MVM_MAPS_MANNHATTAN_STUN_RADIOWAVE 2345
  2183. #define ACHIEVEMENT_TF_MVM_MAPS_MANNHATTAN_BOMB_BOT_GRIND 2346
  2184. #define ACHIEVEMENT_TF_MVM_SENTRY_BUSTER_FRIENDLY_FIRE 2347
  2185. #define ACHIEVEMENT_TF_MVM_SNIPER_COLLECT_HEADSHOT_MONEY 2348
  2186. #define ACHIEVEMENT_TF_MVM_MEDIC_SHIELD_BLOCK_DAMAGE 2349
  2187. #define ACHIEVEMENT_TF_MVM_MEDIC_REVIVE_TEAMMATES 2350
  2188. #define ACHIEVEMENT_TF_MVM_ROCKET_SPECIALIST_KILL_GRIND 2351
  2189. #define ACHIEVEMENT_TF_MVM_ROCKET_SPECIALIST_STUN_GRIND 2352
  2190. #define ACHIEVEMENT_TF_MVM_END_RANGE 2352
  2191. // Doomsday Achievements
  2192. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_START_RANGE 2401
  2193. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_SOLO_CAPTURE 2401
  2194. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_PLAY_GAME_FRIENDS 2402
  2195. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_WIN_ROUNDS 2403
  2196. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_PLAY_EACH_CLASS 2404
  2197. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_KILL_ENEMIES_ON_ELEVATOR 2405
  2198. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_PUSH_BACK_AND_WIN 2406
  2199. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_KILL_CARRIERS 2407
  2200. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_RIDE_THE_ELEVATOR 2408
  2201. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_DENY_NEUTRAL_PICKUP 2409
  2202. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_PUSH_INTO_EXHAUST 2410
  2203. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_DEFEND_CARRIER 2411
  2204. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_ACHIEVE_PROGRESS1 2412
  2205. #define ACHIEVEMENT_TF_MAPS_DOOMSDAY_END_RANGE 2412
  2206. // Process Achievement
  2207. #define ACHIEVEMENT_TF_MAPS_PROCESS_START_RANGE 2501
  2208. #define ACHIEVEMENT_TF_MAPS_PROCESS_WIN_ROUNDS 2501
  2209. #define ACHIEVEMENT_TF_MAPS_PROCESS_END_RANGE 2501
  2210. // Standin Achievement
  2211. #define ACHIEVEMENT_TF_MAPS_STANDIN_START_RANGE 2601
  2212. #define ACHIEVEMENT_TF_MAPS_STANDIN_WIN_ROUNDS 2601
  2213. #define ACHIEVEMENT_TF_MAPS_STANDIN_END_RANGE 2601
  2214. // Snakewater Achievements
  2215. #define ACHIEVEMENT_TF_MAPS_SNAKEWATER_START_RANGE 2701
  2216. #define ACHIEVEMENT_TF_MAPS_SNAKEWATER_WIN_ROUNDS 2701
  2217. #define ACHIEVEMENT_TF_MAPS_SNAKEWATER_PUSH_BACK_AND_WIN 2702
  2218. #define ACHIEVEMENT_TF_MAPS_SNAKEWATER_TEAM_KILL 2703
  2219. #define ACHIEVEMENT_TF_MAPS_SNAKEWATER_DOUBLE_AIR_DEATHS 2704
  2220. #define ACHIEVEMENT_TF_MAPS_SNAKEWATER_KILL_ENEMIES_IN_MIDDLE 2705
  2221. #define ACHIEVEMENT_TF_MAPS_SNAKEWATER_END_RANGE 2705
  2222. // Powerhouse Achievements
  2223. #define ACHIEVEMENT_TF_MAPS_POWERHOUSE_START_RANGE 2801
  2224. #define ACHIEVEMENT_TF_MAPS_POWERHOUSE_WIN_ROUNDS 2801
  2225. #define ACHIEVEMENT_TF_MAPS_POWERHOUSE_PUSH_BACK_AND_WIN 2802
  2226. #define ACHIEVEMENT_TF_MAPS_POWERHOUSE_FAST_FINAL_CAP 2803
  2227. #define ACHIEVEMENT_TF_MAPS_POWERHOUSE_KILL_CAPPING_PLAYER 2804
  2228. #define ACHIEVEMENT_TF_MAPS_POWERHOUSE_KILL_ENEMY_IN_WATER 2805
  2229. #define ACHIEVEMENT_TF_MAPS_POWERHOUSE_END_RANGE 2805
  2230. const unsigned char *GetTFEncryptionKey( void );
  2231. //-----------------------------------------------------------------------------
  2232. // Sapping Events
  2233. //-----------------------------------------------------------------------------
  2234. enum
  2235. {
  2236. TF_SAPEVENT_NONE = 0,
  2237. TF_SAPEVENT_PLACED,
  2238. TF_SAPEVENT_DONE,
  2239. };
  2240. //-----------------------------------------------------------------------------
  2241. // Helper code shared between client/server.
  2242. //-----------------------------------------------------------------------------
  2243. inline bool BIsAttributeValueWithDeltaOverCap( float flCurAttributeValue, float flAttrDeltaValue, float flCap )
  2244. {
  2245. return AlmostEqual( flCurAttributeValue, flCap )
  2246. || ( flAttrDeltaValue > 0 && flCurAttributeValue >= flCap )
  2247. || ( flAttrDeltaValue < 0 && flCurAttributeValue <= flCap );
  2248. }
  2249. //-----------------------------------------------------------------------------
  2250. // Helltower Announcer lines for Redmond and Blutarch
  2251. //-----------------------------------------------------------------------------
  2252. enum
  2253. {
  2254. HELLTOWER_VO_RED_MISC = 0,
  2255. HELLTOWER_VO_BLUE_MISC,
  2256. HELLTOWER_VO_RED_MISC_RARE,
  2257. HELLTOWER_VO_BLUE_MISC_RARE,
  2258. HELLTOWER_VO_RED_WINNING,
  2259. HELLTOWER_VO_BLUE_WINNING,
  2260. HELLTOWER_VO_RED_WINNING_RARE,
  2261. HELLTOWER_VO_BLUE_WINNING_RARE,
  2262. HELLTOWER_VO_RED_LOSING,
  2263. HELLTOWER_VO_BLUE_LOSING,
  2264. HELLTOWER_VO_RED_LOSING_RARE,
  2265. HELLTOWER_VO_BLUE_LOSING_RARE,
  2266. HELLTOWER_VO_RED_WIN,
  2267. HELLTOWER_VO_BLUE_WIN,
  2268. HELLTOWER_VO_RED_WIN_RARE,
  2269. HELLTOWER_VO_BLUE_WIN_RARE,
  2270. HELLTOWER_VO_RED_LOSE,
  2271. HELLTOWER_VO_BLUE_LOSE,
  2272. HELLTOWER_VO_RED_LOSE_RARE,
  2273. HELLTOWER_VO_BLUE_LOSE_RARE,
  2274. HELLTOWER_VO_RED_ROUNDSTART,
  2275. HELLTOWER_VO_BLUE_ROUNDSTART,
  2276. HELLTOWER_VO_RED_ROUNDSTART_RARE,
  2277. HELLTOWER_VO_BLUE_ROUNDSTART_RARE,
  2278. HELLTOWER_VO_RED_SKELETON_KING,
  2279. HELLTOWER_VO_BLUE_SKELETON_KING,
  2280. HELLTOWER_VO_RED_NEAR_WIN,
  2281. HELLTOWER_VO_BLUE_NEAR_WIN,
  2282. HELLTOWER_VO_RED_NEAR_LOSE,
  2283. HELLTOWER_VO_BLUE_NEAR_LOSE,
  2284. HELLTOWER_VO_COUNT,
  2285. };
  2286. struct helltower_vo_t
  2287. {
  2288. const char *m_pszFormatString;
  2289. int m_nCount;
  2290. };
  2291. extern helltower_vo_t g_pszHelltowerAnnouncerLines[];
  2292. // flags to ignore certain check in CanAttack function
  2293. #define TF_CAN_ATTACK_FLAG_NONE 0
  2294. #define TF_CAN_ATTACK_FLAG_GRAPPLINGHOOK 0x01
  2295. struct PlayerHistoryInfo_t
  2296. {
  2297. CSteamID steamID;
  2298. float flTime; // Time last seen
  2299. int nTeam; // Last team they were on
  2300. };
  2301. // When adding new RuneTypes_t, make sure to add new condition codes to
  2302. // ETFCond and also update GetConditionFromRuneType and GetRuneTypeFromCondition.
  2303. enum RuneTypes_t
  2304. {
  2305. RUNE_NONE = -1,
  2306. RUNE_STRENGTH,
  2307. RUNE_HASTE,
  2308. RUNE_REGEN,
  2309. RUNE_RESIST,
  2310. RUNE_VAMPIRE,
  2311. RUNE_REFLECT,
  2312. RUNE_PRECISION,
  2313. RUNE_AGILITY,
  2314. RUNE_KNOCKOUT,
  2315. RUNE_KING,
  2316. RUNE_PLAGUE,
  2317. RUNE_SUPERNOVA,
  2318. // ADD NEW RUNE TYPE HERE, DO NOT RE-ORDER
  2319. RUNE_TYPES_MAX
  2320. };
  2321. inline ETFCond GetConditionFromRuneType( RuneTypes_t rt )
  2322. {
  2323. switch ( rt )
  2324. {
  2325. case RUNE_NONE: return TF_COND_INVALID;
  2326. case RUNE_STRENGTH: return TF_COND_RUNE_STRENGTH;
  2327. case RUNE_HASTE: return TF_COND_RUNE_HASTE;
  2328. case RUNE_REGEN: return TF_COND_RUNE_REGEN;
  2329. case RUNE_RESIST: return TF_COND_RUNE_RESIST;
  2330. case RUNE_VAMPIRE: return TF_COND_RUNE_VAMPIRE;
  2331. case RUNE_REFLECT: return TF_COND_RUNE_REFLECT;
  2332. case RUNE_PRECISION: return TF_COND_RUNE_PRECISION;
  2333. case RUNE_AGILITY: return TF_COND_RUNE_AGILITY;
  2334. case RUNE_KNOCKOUT: return TF_COND_RUNE_KNOCKOUT;
  2335. case RUNE_KING: return TF_COND_RUNE_KING;
  2336. case RUNE_PLAGUE: return TF_COND_RUNE_PLAGUE;
  2337. case RUNE_SUPERNOVA: return TF_COND_RUNE_SUPERNOVA;
  2338. default:
  2339. AssertMsg( 0, "Unexpected rune_type rt (%d) in GetConditionFromRuneType", rt );
  2340. }
  2341. return TF_COND_INVALID;
  2342. }
  2343. enum TemporaryRuneTypes_t
  2344. {
  2345. RUNETYPE_TEMP_NONE = 0,
  2346. RUNETYPE_TEMP_CRIT,
  2347. RUNETYPE_TEMP_UBER,
  2348. RUNETYPE_TEMP_MAX,
  2349. };
  2350. const char *GetPowerupIconName( RuneTypes_t type, int iTeam );
  2351. #define TOURNAMENT_NOCANCEL_TIME 10
  2352. #define TF_WEAPON_PICKUP_RANGE 150
  2353. enum CampaignMedalDisplayType_t
  2354. {
  2355. CAMPAIGN_MEDAL_DISPLAY_TYPE_NONE = 0,
  2356. // Gun Mettle Campaign
  2357. CAMPAIGN_MEDAL_DISPLAY_TYPE_SUMMER2015_GRAVEL,
  2358. CAMPAIGN_MEDAL_DISPLAY_TYPE_SUMMER2015_BRONZE,
  2359. CAMPAIGN_MEDAL_DISPLAY_TYPE_SUMMER2015_SILVER,
  2360. CAMPAIGN_MEDAL_DISPLAY_TYPE_SUMMER2015_GOLD,
  2361. // Invasion Community Update
  2362. CAMPAIGN_MEDAL_DISPLAY_TYPE_INVASION,
  2363. // Halloween
  2364. CAMPAIGN_MEDAL_DISPLAY_TYPE_HALLOWEEN_GRAVEL,
  2365. CAMPAIGN_MEDAL_DISPLAY_TYPE_HALLOWEEN_BRONZE,
  2366. CAMPAIGN_MEDAL_DISPLAY_TYPE_HALLOWEEN_SILVER,
  2367. CAMPAIGN_MEDAL_DISPLAY_TYPE_HALLOWEEN_GOLD,
  2368. // Tough Break Campaign
  2369. CAMPAIGN_MEDAL_DISPLAY_TYPE_WINTER2016_GRAVEL1,
  2370. CAMPAIGN_MEDAL_DISPLAY_TYPE_WINTER2016_BRONZE1,
  2371. CAMPAIGN_MEDAL_DISPLAY_TYPE_WINTER2016_SILVER1,
  2372. CAMPAIGN_MEDAL_DISPLAY_TYPE_WINTER2016_GOLD1,
  2373. CAMPAIGN_MEDAL_DISPLAY_TYPE_WINTER2016_GRAVEL2,
  2374. CAMPAIGN_MEDAL_DISPLAY_TYPE_WINTER2016_BRONZE2,
  2375. CAMPAIGN_MEDAL_DISPLAY_TYPE_WINTER2016_SILVER2,
  2376. CAMPAIGN_MEDAL_DISPLAY_TYPE_WINTER2016_GOLD2,
  2377. CAMPAIGN_MEDAL_DISPLAY_TYPE_COUNT,
  2378. };
  2379. enum CampaignMedalBaseType_t
  2380. {
  2381. CAMPAIGN_MEDAL_SUMMER2015 = 0x001,
  2382. CAMPAIGN_MEDAL_INVASION = 0x002,
  2383. CAMPAIGN_MEDAL_HALLOWEEN = 0x004,
  2384. CAMPAIGN_MEDAL_WINTER2016 = 0x008,
  2385. };
  2386. extern const char *g_pszCampaignMedalIcons[];
  2387. // Rage buffs - how is rage generated with respect to a buff ID?
  2388. enum
  2389. {
  2390. kRageBuffFlag_None = 0x00,
  2391. kRageBuffFlag_OnDamageDealt = 0x01,
  2392. kRageBuffFlag_OnDamageReceived = 0x02,
  2393. kRageBuffFlag_OnMedicHealingReceived = 0x04,
  2394. kRageBuffFlag_OnBurnDamageDealt = 0x08,
  2395. kRageBuffFlag_OnHeal = 0x10
  2396. };
  2397. struct RageBuffType
  2398. {
  2399. unsigned int m_iBuffFlags;
  2400. float m_fRageScale;
  2401. int m_nMaxPulses;
  2402. };
  2403. static const RageBuffType g_RageBuffTypes[] =
  2404. {
  2405. { kRageBuffFlag_None, 0.f, 10 }, // default/unknown buff type
  2406. { kRageBuffFlag_OnDamageDealt, 1.f, 10 }, // buff type 1
  2407. { kRageBuffFlag_OnDamageDealt, 1.f, 10 }, // buff type 2
  2408. { kRageBuffFlag_OnDamageDealt, 1.25f, 10 }, // buff type 3
  2409. { kRageBuffFlag_OnMedicHealingReceived, 1.f, 10 }, // buff type 4
  2410. { kRageBuffFlag_OnBurnDamageDealt, 1.f, 10 }, // pyro rage
  2411. { kRageBuffFlag_OnHeal, 1.f, 10 }, // medic healing
  2412. };
  2413. enum
  2414. {
  2415. DRAWING_PANEL_TYPE_NONE,
  2416. DRAWING_PANEL_TYPE_CRAFTING,
  2417. DRAWING_PANEL_TYPE_MATCH_SUMMARY,
  2418. DRAWING_PANEL_TYPE_MAX,
  2419. };
  2420. enum RankStatType_t
  2421. {
  2422. RankStat_Invalid = -1,
  2423. RankStat_Score = 0,
  2424. RankStat_Kills,
  2425. RankStat_Damage,
  2426. RankStat_Healing,
  2427. RankStat_Support,
  2428. RankStat_Deaths,
  2429. };
  2430. enum StatMedal_t
  2431. {
  2432. StatMedal_None = 0,
  2433. StatMedal_Bronze = 1,
  2434. StatMedal_Silver = 2,
  2435. StatMedal_Gold = 3,
  2436. StatMedal_Max
  2437. };
  2438. #define SF_TEAMSPAWN_SCOUT 1
  2439. #define SF_TEAMSPAWN_SNIPER 2
  2440. #define SF_TEAMSPAWN_SOLDIER 4
  2441. #define SF_TEAMSPAWN_DEMOMAN 8
  2442. #define SF_TEAMSPAWN_MEDIC 16
  2443. #define SF_TEAMSPAWN_HEAVY 32
  2444. #define SF_TEAMSPAWN_PYRO 64
  2445. #define SF_TEAMSPAWN_SPY 128
  2446. #define SF_TEAMSPAWN_ENGINEER 256
  2447. enum MM_PlayerConnectionState_t
  2448. {
  2449. MM_DISCONNECTED = 0,
  2450. MM_CONNECTED,
  2451. MM_CONNECTING, // the server knows that this player is coming
  2452. MM_LOADING, // loading into the server
  2453. MM_WAITING_FOR_PLAYER
  2454. };
  2455. #endif // TF_SHAREDDEFS_H