Advertisement
Guest User

Entity.h

a guest
Aug 27th, 2017
319
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.18 KB | None | 0 0
  1. #pragma once
  2.  
  3. enum MoveType_t
  4. {
  5. MOVETYPE_NONE = 0,
  6. MOVETYPE_ISOMETRIC,
  7. MOVETYPE_WALK,
  8. MOVETYPE_STEP,
  9. MOVETYPE_FLY,
  10. MOVETYPE_FLYGRAVITY,
  11. MOVETYPE_VPHYSICS,
  12. MOVETYPE_PUSH,
  13. MOVETYPE_NOCLIP,
  14. MOVETYPE_LADDER,
  15. MOVETYPE_OBSERVER,
  16. MOVETYPE_CUSTOM,
  17. MOVETYPE_LAST = MOVETYPE_CUSTOM,
  18. MOVETYPE_MAX_BITS = 4
  19. };
  20.  
  21. enum CSWeaponType
  22. {
  23. WEAPONTYPE_KNIFE = 0,
  24. WEAPONTYPE_PISTOL,
  25. WEAPONTYPE_SUBMACHINEGUN,
  26. WEAPONTYPE_RIFLE,
  27. WEAPONTYPE_SHOTGUN,
  28. WEAPONTYPE_SNIPER,
  29. WEAPONTYPE_MACHINEGUN,
  30. WEAPONTYPE_C4,
  31. WEAPONTYPE_PLACEHOLDER,
  32. WEAPONTYPE_GRENADE,
  33. WEAPONTYPE_UNKNOWN
  34. };
  35.  
  36. enum WEAPONCLASS
  37. {
  38. WEPCLASS_INVALID,
  39. WEPCLASS_RIFLE,
  40. WEPCLASS_PISTOL,
  41. WEPCLASS_SHOTGUN,
  42. WEPCLASS_SNIPER,
  43. WEPCLASS_SMG,
  44. WEPCLASS_MACHINEGUN,
  45. WEPCLASS_KNIFE
  46. };
  47.  
  48. enum TeamID
  49. {
  50. TEAM_SPECTATOR = 1,
  51. TEAM_TT,
  52. TEAM_CT
  53. };
  54.  
  55. class CBaseCombatWeapon;
  56. class CBaseEntity
  57. {
  58. public:
  59. char __pad[0x64];
  60. int index;
  61. int GetHealth();
  62. bool IsValid();
  63. int GetTeam();
  64. int GetFlags();
  65. int GetTickBase();
  66. int GetDistance();
  67. int GetShotsFired();
  68. int GetMoney();
  69. int GetMoveType();
  70. int GetModelIndex();
  71. int GetHitboxSet();
  72. int GetUserID();
  73. int GetArmor();
  74. model_t* GetModel();
  75. int GetCollisionGroup();
  76. int GetAmmo(CBaseCombatWeapon* wep);
  77. bool IsDefusing();
  78. bool IsBombPlanted();
  79. int PhysicsSolidMaskForEntity();
  80. int GetOwner();
  81. float& GetSimulationTime();
  82. float& GetOldSimulationTime();
  83. float& GetCycle();
  84. int& GetSequence();
  85. CBaseEntity* GetObserverTarget();
  86. ObserverMode_t* GetObserverMode();
  87. int GetGlowIndex();
  88. bool IsAlive();
  89. bool IsDormant();
  90. int GetIndex();
  91. bool HasImmunity();
  92. bool IsEnemy();
  93. bool IsVisible(int bone);
  94. bool m_visible;
  95. bool IsBroken();
  96. bool HasHelmet();
  97. bool HasDefuser();
  98. bool IsFlashed();
  99. bool IsTargetingLocal();
  100. bool IsScoped();
  101. bool* IsSpotted();
  102. float GetFlashDuration();
  103. float* GetFlashMaxAlpha();
  104. float GetBombTimer();
  105. bool IsBombDefused();
  106. int GetBombDefuser();
  107. float GetLowerBodyYaw();
  108. QAngle GetViewPunch();
  109. Vector GetAimPunchAngle();
  110. QAngle GetPunch();
  111. QAngle* GetEyeAnglesPointer();
  112. QAngle GetEyeAngles();
  113. QAngle* GetVAngles();
  114. Vector GetOrigin();
  115. Vector GetOrigin2();
  116. Vector GetAbsOrigin();
  117. Vector GetAbsOrigin2();
  118. Vector GetAbsAngles();
  119. Vector GetAbsAngles2();
  120. Vector GetEyePosition();
  121. Vector GetBonePosition(int iBone);
  122. Vector GetVecViewOffset();
  123. bool SetupBones(matrix3x4_t* pBoneToWorldOut, int nMaxBones, int boneMask, float currentTime);
  124. Vector GetVelocity();
  125. Vector GetPredicted(Vector p0);
  126. float& GetPoseParameter(int i);
  127. ICollideable* GetCollideable();
  128. void UpdateClientSideAnimation();
  129. player_info_t GetPlayerInfo();
  130. std::string GetName();
  131. std::string GetSteamID();
  132. std::string GetLastPlace();
  133. int& GetXUIDLow();
  134. int& GetXUIDHigh();
  135. CBaseCombatWeapon* GetWeapon();
  136. ClientClass* GetClientClass();
  137. };
  138.  
  139. class CHudTexture
  140. {
  141. public:
  142. char szShortName[64]; //0x0000
  143. char szTextureFile[64]; //0x0040
  144. bool bRenderUsingFont; //0x0080
  145. bool bPrecached; //0x0081
  146. char cCharacterInFont; //0x0082
  147. BYTE pad_0x0083; //0x0083
  148. int hFont; //0x0084
  149. int iTextureId; //0x0088
  150. float afTexCoords[4]; //0x008C
  151. int iPosX[4]; //0x009C
  152. };//Size=0x00AC
  153.  
  154. class WeaponInfo_t
  155. {
  156. public:
  157. char pad_0x0000[4]; // 0x0000
  158. char* consoleName; // 0x0004
  159. char pad_0008[12]; // 0x0008
  160. int iMaxClip1; // 0x0014
  161. int iMaxClip2; // 0x0018
  162. int iDefaultClip1; // 0x001C
  163. int iDefaultClip2; // 0x0020
  164. char pad_0024[8]; // 0x0024
  165. char* szWorldModel; // 0x002C
  166. char* szViewModel; // 0x0030
  167. char* szDroppedModel; // 0x0034
  168. char pad_0038[4]; // 0x0038
  169. char* N0000023E; // 0x003C
  170. char pad_0040[56]; // 0x0040
  171. char* szEmptySound; // 0x0078
  172. char pad_007C[4]; // 0x007C
  173. char* szBulletType; // 0x0080
  174. char pad_0084[4]; // 0x0084
  175. char* szHudName; // 0x0088
  176. char* szWeaponName; // 0x008C
  177. char pad_0090[56]; // 0x0090
  178. int WeaponType; // 0x00C8
  179. int iWeaponPrice; // 0x00CC
  180. int iKillAward; // 0x00D0
  181. char* szAnimationPrefix; // 0x00D4
  182. float flCycleTime; // 0x00D8
  183. float flCycleTimeAlt; // 0x00DC
  184. float flTimeToIdle; // 0x00E0
  185. float flIdleInterval; // 0x00E4
  186. bool bFullAuto; // 0x00E8
  187. char pad_0x00E5[3]; // 0x00E9
  188. int iDamage; // 0x00EC
  189. float flArmorRatio; // 0x00F0
  190. int iBullets; // 0x00F4
  191. float flPenetration; // 0x00F8
  192. float flFlinchVelocityModifierLarge; // 0x00FC
  193. float flFlinchVelocityModifierSmall; // 0x0100
  194. float flRange; // 0x0104
  195. float flRangeModifier; // 0x0108
  196. float flThrowVelocity; // 0x010C
  197. char pad_0x010C[12]; // 0x0110
  198. bool bHasSilencer; // 0x011C
  199. char pad_0x0119[3]; // 0x011D
  200. char* pSilencerModel; // 0x0120
  201. int iCrosshairMinDistance; // 0x0124
  202. int iCrosshairDeltaDistance;// 0x0128 - iTeam?
  203. float flMaxPlayerSpeed; // 0x012C
  204. float flMaxPlayerSpeedAlt; // 0x0130
  205. float flSpread; // 0x0134
  206. float flSpreadAlt; // 0x0138
  207. float flInaccuracyCrouch; // 0x013C
  208. float flInaccuracyCrouchAlt; // 0x0140
  209. float flInaccuracyStand; // 0x0144
  210. float flInaccuracyStandAlt; // 0x0148
  211. float flInaccuracyJumpInitial;// 0x014C
  212. float flInaccuracyJump; // 0x0150
  213. float flInaccuracyJumpAlt; // 0x0154
  214. float flInaccuracyLand; // 0x0158
  215. float flInaccuracyLandAlt; // 0x015C
  216. float flInaccuracyLadder; // 0x0160
  217. float flInaccuracyLadderAlt; // 0x0164
  218. float flInaccuracyFire; // 0x0168
  219. float flInaccuracyFireAlt; // 0x016C
  220. float flInaccuracyMove; // 0x0170
  221. float flInaccuracyMoveAlt; // 0x0174
  222. float flInaccuracyReload; // 0x0178
  223. int iRecoilSeed; // 0x017C
  224. float flRecoilAngle; // 0x0180
  225. float flRecoilAngleAlt; // 0x0184
  226. float flRecoilAngleVariance; // 0x0188
  227. float flRecoilAngleVarianceAlt; // 0x018C
  228. float flRecoilMagnitude; // 0x0190
  229. float flRecoilMagnitudeAlt; // 0x0194
  230. float flRecoilMagnitudeVariance; // 0x0198
  231. float flRecoilMagnitudeVarianceAlt; // 0x019C
  232. float flRecoveryTimeCrouch; // 0x01A0
  233. float flRecoveryTimeStand; // 0x01A4
  234. float flRecoveryTimeCrouchFinal; // 0x01A8
  235. float flRecoveryTimeStandFinal; // 0x01AC
  236. int iRecoveryTransitionStartBullet;// 0x01B0
  237. int iRecoveryTransitionEndBullet; // 0x01B4
  238. bool bUnzoomAfterShot; // 0x01B8
  239. bool bHideViewModelZoomed; // 0x01B9
  240. char pad_0x01B5[2]; // 0x01BA
  241. char iZoomLevels[3]; // 0x01BC
  242. int iZoomFOV[2]; // 0x01C0
  243. float fZoomTime[3]; // 0x01C4
  244. char* szWeaponClass; // 0x01D4
  245. float flAddonScale; // 0x01D8
  246. char pad_0x01DC[4]; // 0x01DC
  247. char* szEjectBrassEffect; // 0x01E0
  248. char* szTracerEffect; // 0x01E4
  249. int iTracerFrequency; // 0x01E8
  250. int iTracerFrequencyAlt; // 0x01EC
  251. char* szMuzzleFlashEffect_1stPerson; // 0x01F0
  252. char pad_0x01F4[4]; // 0x01F4
  253. char* szMuzzleFlashEffect_3rdPerson; // 0x01F8
  254. char pad_0x01FC[4]; // 0x01FC
  255. char* szMuzzleSmokeEffect; // 0x0200
  256. float flHeatPerShot; // 0x0204
  257. char* szZoomInSound; // 0x0208
  258. char* szZoomOutSound; // 0x020C
  259. float flInaccuracyPitchShift; // 0x0210
  260. float flInaccuracySoundThreshold; // 0x0214
  261. float flBotAudibleRange; // 0x0218
  262. BYTE pad_0x0218[8]; // 0x0220
  263. char* pWrongTeamMsg; // 0x0224
  264. bool bHasBurstMode; // 0x0228
  265. BYTE pad_0x0225[3]; // 0x0229
  266. bool bIsRevolver; // 0x022C
  267. bool bCannotShootUnderwater; // 0x0230 };,
  268. CHudTexture* iconWeapon;
  269. CHudTexture* iconAmmo;
  270. CHudTexture* iconWeaponS;
  271. };
  272.  
  273. class CCSWeaponInfo_t
  274. {
  275. public:
  276. void* vTable; //0x0000
  277. BYTE N0309F389; //0x0004
  278. BYTE N030AC4C1; //0x0005
  279. char name_class[93]; //0x0006
  280. char printname[80]; //0x00
  281. char viewmodel[80]; //0x00A6
  282. char playermodel[80]; //0x00F6
  283. char bullettype[32]; //0x0146
  284. char anim_prefix[58]; //0x0166
  285. char N03122066[32]; //0x01A0
  286. char contentpack[32]; //0x01C0
  287. char unknowndata00[128]; //0x01E0
  288. char name_real[32]; //0x0260
  289. char unknowndata01[1184]; //0x0280
  290. CHudTexture* hudTexture_silenced; //0x0720
  291. CHudTexture* hudTexture; //0x0724
  292. CHudTexture* hudTexture_ammo; //0x0728
  293. char unknowndata02[4]; //0x072C
  294. CHudTexture* hudTexture_crosshair_01; //0x0730
  295. CHudTexture* hudTexture_crosshair_02; //0x0734
  296. CHudTexture* hudTexture_crosshair_03; //0x0738
  297. CHudTexture* hudTexture_crosshair_04; //0x073C
  298. char unknowndata03[8]; //0x0740
  299. __int32 WeaponType; //0x0748
  300. __int32 Team; //0x074C
  301. __int32 WeaponID; //0x0750
  302. BYTE FullAuto; //0x0754
  303. char unknowndata04[7]; //0x0755
  304. __int32 WeaponPrice; //0x075C
  305. float WeaponArmorRatio; //0x0760
  306. float MaxPlayerSpeed; //0x0764
  307. float MaxPlayerSpeedAlt; //0x0768
  308. __int32 CrosshairMinDistance; //0x076C
  309. __int32 CrosshairDeltaDistance; //0x0770
  310. float flPenetrationPower; //0x0774
  311. __int32 iDamage; //0x0778
  312. float flRange; //0x077C
  313. float flRangeModifier; //0x0780
  314. __int32 iBullets; //0x0784
  315. float CycleTime; //0x0788
  316. }; //Size=0x078C
  317.  
  318. class CBaseCombatWeapon
  319. {
  320. public:
  321. char __pad[0x64];
  322. int index;
  323. int& GetWeaponID();
  324. float& GetNextPrimaryAttack();
  325. float& GetAccuracyPenalty();
  326. float& GetPostponeFireReadyTime();
  327. int& GetXUIDLow();
  328. int& GetXUIDHigh();
  329. int& GetEntityQuality();
  330. int& GetAccountID();
  331. int& GetItemIDHigh();
  332. int& GetItemDefinitionIndex();
  333. int& GetFallbackPaintKit();
  334. int& GetFallbackStatTrak();
  335. int& ViewModelIndex();
  336. int& WorldModelIndex();
  337. float& GetFallbackWear();
  338. bool IsEmpty();
  339. bool IsReloading();
  340. float GetSpread();
  341. float GetInaccuracy();
  342. float GetInaccuracy2();
  343. float GetHitchance();
  344. void UpdateAccuracyPenalty();
  345. float GetWeaponSpread();
  346. float GetWeaponCone();
  347. WeaponInfo_t* GetCSWpnData();
  348. bool IsGun();
  349. bool IsGunSniper();
  350. bool IsGunCanScope();
  351. bool IsGunGrenade();
  352. std::string GetWeaponName();
  353. model_t* GetModel();
  354. int GetWeaponType();
  355. };
  356.  
  357. class CBaseViewModel
  358. {
  359. public:
  360. inline int GetModelIndex()
  361. {
  362. // DT_BaseViewModel -> m_nModelIndex
  363. return *(int*)((DWORD)this + 0x254);
  364. }
  365.  
  366. inline DWORD GetOwner()
  367. {
  368. // DT_BaseViewModel -> m_hOwner
  369. return *(PDWORD)((DWORD)this + 0x29BC);
  370. }
  371.  
  372. inline DWORD GetWeapon()
  373. {
  374. // DT_BaseViewModel -> m_hWeapon
  375. return *(PDWORD)((DWORD)this + 0x29B8);
  376. }
  377. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement