Advertisement
y0Mike

Untitled

Apr 10th, 2018
986
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.07 KB | None | 0 0
  1. Crossout Info 8/29/2017
  2.  
  3.  
  4. enum eFlags
  5. {
  6. SHOOTING = 2
  7. };
  8.  
  9. enum eState
  10. {
  11. IDLE = 5
  12. };
  13.  
  14.  
  15. #define MEMBER( x ) public: x; private:
  16.  
  17.  
  18. class CBaseEntity;
  19. class CEntityList
  20. {
  21. public:
  22. bool InUpdate ()
  23. {
  24. return *( bool* )( ( DWORD )this + 0x50 );
  25. }
  26.  
  27. int GetEntityCount ()
  28. {
  29. return *( DWORD* )( ( DWORD )this + 0x1000C );
  30. }
  31.  
  32. /*
  33. * 55 8B EC 56 FF 75 08 8B F1 FF 86
  34. */
  35. const char* FindEntityByName ( const char* pszName );
  36.  
  37. CBaseEntity* GetEntityFromIdx ( unsigned int idx )
  38. {
  39. ++*( DWORD* )( ( DWORD )this + 0x3404C );
  40.  
  41. auto v4 = ( reinterpret_cast< DWORD >( this + 12 * ( ( idx & 0xFFF ) + 1 ) ) );
  42. auto result = idx == *reinterpret_cast< DWORD* >( v4 + 8 );
  43. auto v5 = *reinterpret_cast< DWORD* >( v4 ) & ( ( ( result ) | -result ) >> 31 );
  44.  
  45. return ( CBaseEntity* )v5 != NULL ? ( CBaseEntity* )v5 : NULL;
  46. }
  47. CBaseEntity* GetNetworkedEntityFromIdx ( unsigned int idx )
  48. {
  49. auto v4 = ( reinterpret_cast< DWORD >( this + 12 * ( ( idx & 0xFFF ) + 0x2AAD ) ) );
  50. auto result = idx == *reinterpret_cast< DWORD* >( v4 + 8 );
  51. auto v5 = *reinterpret_cast< DWORD* >( v4 ) & ( ( ( result ) | -result ) >> 31 );
  52.  
  53. return ( CBaseEntity* )v5 != nullptr ? ( CBaseEntity* )v5 : nullptr;
  54. }
  55. };
  56.  
  57.  
  58. //////////////////////////////////////////
  59.  
  60. class CModelInfo;
  61. class CBaseEntity_VTABLE;
  62. class CTransform;
  63. class CModel;
  64. class CPlayerCoordinates;
  65. class CGameLogic;
  66. class CD3DDevice;
  67. class CD3DDevice_VTABLE;
  68. class CBone;
  69. class CCarInfo;
  70. class CBaseEntityTypeInfo;
  71. class CVelocity;
  72. class CGameLogic_VTABLE;
  73. class CBaseCamera;
  74. class CEntityDef;
  75. class CEntityDefInfo;
  76. class CCarPhysics;
  77. class CEntityChildren;
  78.  
  79.  
  80. class CTransform
  81. {
  82. public:
  83. D3DXMATRIX m_Matrix; //0x0000
  84. D3DXMATRIX m_Frame2; //0x0040
  85. char pad_0x0080[ 0x20 ]; //0x0080
  86. CVector m_vec; //0x00A0
  87. char pad_0x00AC[ 0x4 ]; //0x00AC
  88. CVector m_vec2; //0x00B0
  89. char pad_0x00BC[ 0xB48 ]; //0x00BC
  90. }; //Size=0x0C04
  91.  
  92.  
  93. class CBaseEntityTypeInfo
  94. {
  95. public:
  96. char pad_0x0000[ 0x18 ]; //0x0000
  97. __int32 m_flag; //0x0018
  98. char pad_0x001C[ 0xBE8 ]; //0x001C
  99.  
  100. }; //Size=0x0C04
  101.  
  102. class CEntityInfo
  103. {
  104. public:
  105. CVector m_vecUnk; //0x0000
  106. char pad_0x000C[ 0x10 ]; //0x000C
  107. __int32 m_playerIdx; //0x001C
  108. char pad_0x0020[ 0x30 ]; //0x0020
  109. CVector m_vecPosition; //0x0050
  110. char pad_0x005C[ 0x18 ]; //0x005C
  111. float m_fUnk; //0x0074
  112. char pad_0x0078[ 0x38C ]; //0x0078
  113.  
  114. }; //Size=0x0404
  115.  
  116.  
  117.  
  118. class CBaseEntity
  119. {
  120. public:
  121. class CBaseEntity_VTABLE* vfptr; //0x0000
  122. class CBaseEntityTypeInfo* m_pEntityTypeInfo; //0x0004
  123. char pad_0008[ 4 ]; //0x0008
  124. int32_t m_Flags; //0x000C
  125. char pad_0010[ 32 ]; //0x0010
  126. int32_t m_ID; //0x0030
  127. int32_t m_NetworkID; //0x0034
  128. int32_t m_unk_; //0x0038
  129. int32_t m_parent; //0x003C
  130. char pad_0040[ 16 ]; //0x0040
  131. int32_t m_unk_2; //0x0050
  132. int32_t m_MovementFlags; //0x0054
  133. class CEntityDef* m_pEntityDef; //0x0058
  134. char pad_005C[ 4 ]; //0x005C
  135. char m_szName[ 16 ]; //0x0060
  136. char pad_0070[ 64 ]; //0x0070
  137. class CModel* m_pModel; //0x00B0
  138. char pad_00B4[ 4 ]; //0x00B4
  139. float m_flHealth; //0x00B8
  140. float m_flMaxHealth; //0x00BC
  141. class CCarInfo* m_pCarInfo; //0x00C0
  142. char pad_00C4[ 36 ]; //0x00C4
  143. uint32_t m_dwRelationshipGroup; //0x00E8
  144. char pad_00EC[ 36 ]; //0x00EC
  145. CVector m_vecMins; //0x0110
  146. char pad_011C[ 4 ]; //0x011C
  147. CVector m_vecMaxes; //0x0120
  148. char pad_012C[ 4 ]; //0x012C
  149. class CTransform* m_pTransform; //0x0130
  150. char pad_0134[ 68 ]; //0x0134
  151. int32_t m_NumBones; //0x0178
  152. char pad_017C[ 148 ]; //0x017C
  153. float m_flMaxViewDist; //0x0210
  154. char pad_0214[ 172 ]; //0x0214
  155. class CEntityDef* m_pEntityDef2; //0x02C0
  156. char pad_02C4[ 4 ]; //0x02C4
  157. int32_t m_PlayerIdx; //0x02C8
  158. char pad_02CC[ 568 ]; //0x02CC
  159. float m_flWeaponDmgScale; //0x0504
  160. float m_flHealthScale; //0x0508
  161. float m_flInitialHealth; //0x050C
  162. char pad_0510[ 628 ]; //0x0510
  163. class CCarPhysics* m_pCarPhysics; //0x0784
  164. char pad_0788[ 20 ]; //0x0788
  165. uint32_t m_NumChildren; //0x079C
  166. class CEntityChildren* m_children; //0x07A0
  167. char pad_07A4[ 76 ]; //0x07A4
  168. CVector m_vecViewDirection; //0x07F0
  169. char pad_07FC[ 4 ]; //0x07FC
  170. float m_flAccelerating; //0x0800
  171. int32_t m_nTargetEntity; //0x0804 -> Crosshair target
  172. char pad_0808[ 4 ]; //0x0808
  173. int32_t m_FlagsEx; //0x080C
  174. CVector m_vecCrossOnTarget; //0x0810
  175. char pad_081C[ 28 ]; //0x081C
  176. float m_flPitch; //0x0838
  177. char pad_083C[ 188 ]; //0x083C
  178. uint32_t m_nWeaponType; //0x08F8
  179. char pad_08FC[ 5904 ]; //0x08FC
  180.  
  181.  
  182.  
  183.  
  184. public:
  185.  
  186. inline bool IsDead () const
  187. {
  188. return ( m_Flags & 1 );
  189. }
  190.  
  191. CVector GetCenterPos ( void );
  192. const char* GetName ( );
  193. void Suicide ( void );
  194. void Revive ( void );
  195. void MovePos ( float vecNewPos );
  196. CBone* GetBone ( unsigned int boneIdx );
  197. signed int GetBoneIdxFromName ( const char* szBoneName );
  198. CVector GetLinearVelocity ( void );
  199. void SetLinearVelocity ( CVector vecVelocity );
  200. void SetTransparency ( float flTransparency );
  201. CBaseEntity* GetParent ( void );
  202. CEntityInfo* Info ( void );
  203. bool IsHostile ( CBaseEntity* pPlayer );
  204. bool IsFriendly ( CBaseEntity* pPlayer );
  205. bool IsVisibleForPlayers ( void );
  206. bool IsCar ( void );
  207. bool IsCarPart ( void );
  208. bool IsEffectEntity ( void );
  209. bool IsBaseEntity ( void );
  210. bool IsWeapon ( void );
  211. bool IsProjectile ( void );
  212. bool IsLandMine ( void );
  213. bool IsTurret ( void ) ;
  214. bool IsHomingMissle ( void );
  215. bool IsServerObject ( void );
  216. bool IsRelatedToMe ( CBaseEntity* pEntity );
  217. CBaseEntity* GetChild ( unsigned int idx );
  218. int GetChildId ( unsigned int idx );
  219. bool CanHaveChildren ( void );
  220. int GetNumWeapons ( void );
  221. bool EntityDefContains ( const char* szText, bool bCaseSensitive = true );
  222.  
  223. void* GetEntityInfo ( void* a2, const char* pszInfoName );
  224.  
  225. const char* GetClassName ( void );
  226.  
  227. CVector GetDirection ( void );
  228. private:
  229.  
  230. bool IsType ( char* szType );
  231. bool IsTypeEx ( char* szType );
  232. }; //Size=0x1C04
  233.  
  234. class CModelInfo
  235. {
  236. public:
  237. char pad_0x0000[ 0x16C ]; //0x0000
  238. char m_szDefName[ 16 ]; //0x10E7888
  239. char pad_0x017C[ 0x688 ]; //0x017C
  240.  
  241. }; //Size=0x0804
  242.  
  243. class CBaseEntity_VTABLE
  244. {
  245. public:
  246. char pad_0x0000[ 0x4 ]; //0x0000
  247. char pad_0x0008[ 0x28A ]; //0x0008
  248.  
  249. }; //Size=0x0292
  250.  
  251.  
  252. class CModel
  253. {
  254. public:
  255. char pad_0x0000[ 0x18 ]; //0x0000
  256. __int32 m_SkinIdx; //0x0018
  257. char pad_0x001C[ 0x128 ]; //0x001C
  258. __int32 m_NumSkins; //0x0144
  259. char pad_0x0148[ 0x2BC ]; //0x0148
  260.  
  261. }; //Size=0x0404
  262.  
  263. class CPlayerCoordinates
  264. {
  265. public:
  266. char pad_0x0000[ 0x10 ]; //0x0000
  267. CVector m_vecPosition; //0x0010
  268. char pad_0x001C[ 0x3E8 ]; //0x001C
  269.  
  270. }; //Size=0x0404
  271.  
  272. class CGameLogic
  273. {
  274. public:
  275. CGameLogic_VTABLE* vfptr; //0x0000
  276. char pad_0x0004[ 0x14 ]; //0x0004
  277. __int32 localClientNum; //0x0018
  278. char pad_0x001C[ 0x464 ]; //0x001C
  279.  
  280. }; //Size=0x0480
  281.  
  282. class CD3DDevice
  283. {
  284. public:
  285. CD3DDevice_VTABLE* vfptr; //0x0000
  286. char pad_0x0004[ 0x54 ]; //0x0004
  287. __int32 m_ResolutionX; //0x0058
  288. __int32 m_ResolutionY; //0x005C
  289. char pad_0x0060[ 0x3E0 ]; //0x0060
  290.  
  291. }; //Size=0x0440
  292.  
  293. class CD3DDevice_VTABLE
  294. {
  295. public:
  296. char pad_0x0000[ 0x4 ]; //0x0000
  297.  
  298. }; //Size=0x0004
  299.  
  300. class CBone
  301. {
  302. public:
  303. char pad_0x0000[ 0x10 ]; //0x0000
  304. CVector m_vecMax; //0x0010
  305. char pad_0x001C[ 0x4 ]; //0x001C
  306. CVector m_vecMin; //0x0020
  307. char pad_0x002C[ 0x4 ]; //0x002C
  308. CVector m_vecPosition; //0x0030
  309. char pad_0x003C[ 0x7C8 ]; //0x003C
  310. }; //Size=0x0804
  311.  
  312.  
  313. class CCarInfo
  314. {
  315. public:
  316. char pad_0x0000[ 0x14 ]; //0x0000
  317. CVelocity* m_pVelocityInfo; //0x0014
  318. char pad_0x0018[ 0x18 ]; //0x0018
  319. D3DXMATRIX m_trans; //0x0030
  320. char pad_0x0070[ 0x40 ]; //0x0070
  321. D3DXMATRIX N00001468; //0x00B0
  322. D3DXMATRIX m_Frame; //0x00F0
  323. D3DXMATRIX N00001488; //0x0130
  324. char pad_0x0170[ 0x120 ]; //0x0170
  325. D3DXMATRIX N000014E0; //0x0290
  326. char pad_0x02D0[ 0xD34 ]; //0x02D0
  327.  
  328. }; //Size=0x1004
  329.  
  330. class CVelocity
  331. {
  332. public:
  333. char pad_0x0000[ 0x10 ]; //0x0000
  334. D3DXMATRIX m1; //0x0010
  335. D3DXMATRIX m2; //0x0050
  336. char pad_0x0090[ 0xD0 ]; //0x0090
  337. CVector m_vecSpeed; //0x0160
  338. char pad_0x016C[ 0x4 ]; //0x016C
  339. CVector m_vecSpeed2; //0x0170
  340. char pad_0x017C[ 0x288 ]; //0x017C
  341.  
  342. }; //Size=0x0404
  343.  
  344. class CGameLogic_VTABLE
  345. {
  346. public:
  347. char pad_0x0000[ 0x404 ]; //0x0000
  348.  
  349. }; //Size=0x0404
  350.  
  351.  
  352. class CBaseCamera
  353. {
  354. public:
  355. char pad_0x0000[ 0x10 ]; //0x0000
  356. float m_flFovX; //0x0010
  357. float m_flFovY; //0x0014
  358. float m_flFovZ; //0x0018
  359. char pad_0x001C[ 0x14 ]; //0x001C
  360. CVector m_vecCameraPosition; //0x0030
  361. char pad_0x003C[ 0x4 ]; //0x003C
  362. CVector m_vecCameraAimPosition; //0x0040
  363. char pad_0x004C[ 0x4 ]; //0x004C
  364. CVector m_vecDirection; //0x0050
  365. char pad_0x005C[ 0x4 ]; //0x005C
  366. float m_flResolutionX; //0x0060
  367. float m_flResolutionY; //0x0064
  368. char pad_0x0068[ 0x18 ]; //0x0068
  369. D3DXMATRIX m_ViewMatrix; //0x0080
  370. D3DXMATRIX m2; //0x00C0
  371. D3DXMATRIX m_Projection; //0x0100
  372. D3DXMATRIX m4; //0x0140
  373. CVector m_vecUnk; //0x0180
  374. char pad_0x018C[ 0x518 ]; //0x018C
  375. float m_flYaw; //0x06A4
  376. float m_flPitch; //0x06A8
  377. char pad_0x06AC[ 0x558 ]; //0x06AC
  378. public:
  379.  
  380. //CVector2D GetCameraProjScales ( void );
  381. bool ProjectToScreen ( CVector& vecWorld, CVector* vecScreen );
  382. CVector GetCameraPos ( void );
  383. CVector GetCameraDirection ( void );
  384. bool SetAimPosition ( CVector vecPosition );
  385. bool SetCameraPosition ( CVector vecPosition );
  386. void SetUpPosition ( CVector vecPosition );
  387. void AimAt ( const CVector& vecPosition );
  388. bool IsRayIntersectEntity ( const CVector& vecStart, const CVector& vecDirection, float flDistance, CBaseEntity* pEntity, CVector* pvecReturn = nullptr );
  389.  
  390.  
  391. inline float GetYaw ( void ) const
  392. { return m_flYaw; }
  393. inline float GetPitch ( void ) const
  394. { return m_flPitch; }
  395. inline void SetYaw ( float flYaw )
  396. { m_flYaw = flYaw; }
  397. inline void SetPitch ( float flPitch )
  398. { m_flPitch = flPitch; }
  399. };
  400.  
  401. class CEntityDef
  402. {
  403. public:
  404. CEntityDefInfo* m_pEntityInfo; //0x0000
  405. char m_szModelInfo[ 59 ]; //0x10E7888
  406. char pad_0x003F[ 0x131 ]; //0x003F
  407. char m_szEntityDefName[ 59 ]; //0x10E7888
  408. char pad_0x01AB[ 0x19 ]; //0x01AB
  409. char N000015E5[ 59 ]; //0x10E7888
  410. char pad_0x01FF[ 0x131 ]; //0x01FF
  411. char N00001640[ 20 ]; //0x10E7888
  412. char pad_0x0344[ 0x40 ]; //0x0344
  413. char N00001655[ 59 ]; //0x10E7888
  414. char pad_0x03BF[ 0x481 ]; //0x03BF
  415. }; //Size=0x0840
  416.  
  417. class CEntityDefInfo
  418. {
  419. public:
  420. char pad_0x0000[ 0x404 ]; //0x0000
  421.  
  422. }; //Size=0x0404
  423.  
  424.  
  425. class CCarPhysics
  426. {
  427. public:
  428. char pad_0x0000[ 0xAC ]; //0x0000
  429. CVector m_vecAcceleration; //0x00AC
  430. char pad_0x00B8[ 0x34C ]; //0x00B8
  431.  
  432. }; //Size=0x0404
  433.  
  434. template < typename T = int >
  435. class CVar
  436. {
  437. public:
  438. T Value; //0x0000
  439. char *String_Value; //0x0004
  440. int SizeOfString; //0x0008
  441. int SizeOfStringInCvarClass; //0x000C always 14h
  442. char string[ 20 ]; //0x0010
  443. CVar* Next; //0x0024
  444. int Type; //0x0028 0 - int ,1 - float,2 - string ,3 - unsigned char [4]
  445. char *Name; //0x002C
  446. char *StringValue2; //0x0030
  447. char _0x0034[ 4 ];
  448. int Min; //0x0038
  449. int Max; //0x003C
  450. int Protect; //0x0040
  451. char _0x0044[ 12 ];// idk
  452.  
  453. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement