Source Code AssaultCube Weapon VTable

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat

Solaire

Respected Hacker
Dank Tier VIP
Dec 15, 2013
1,051
16,353
62
C++:
class world;
class playerent;
class weapon;


class world{
public:
    playerent* pLocal; 
};


class playerent{
public:
    char _0x0000[840];
    weapon * knife;
    weapon * pistol;
    weapon * carbine;
    weapon * shotgun;
    weapon * subgun;
    weapon * sniper;
    weapon * assaultrifle;
    weapon * cpistol;
    weapon * grenade;
    weapon * akimbo;
};


class weapon{
public:
    void * VTable;
};
VTable indexes:
C++:
//     00 ~weapon();
//     01 int dynspread();
//     02 float dynrecoil();
//     03 bool attack(vec& targ);
//     04 void attackfx(const vec& from, const vec& to, int millis);
//     05 void attackphysics(vec& from, vec& to);
//     06 void attacksound();
//     07 bool reload(bool autoreloaded);
//     08 void reset();
//     09 bool busy();
//     10 int modelanim();
//     11 void updatetimers(int millis);
//     12 bool selectable();
//     13 bool deselectable();
//     14 void renderstats();
//     15 void renderhudmodel();
//     16 void renderaimhelp(bool teamwarning);
//     17 void onselecting();
//     18 void ondeselecting();
//     19 void onammopicked();
//     20 void onownerdies();
//     21 void removebounceent(bounceent * b);
//     22 int flashtime();

I also reversed the whole playerent class, so if anyone needs it just mention and I'll post it. Atm it's really fugly and I cba to fix it up.

To use this, declare a world pointer to 0x50F4F4.

C++:
///////////////////////////////////////////////////////////////////////////////////////
// Grabbing the function vTable address
//             printf("0x%X\n", pWorld->pLocal->knife->VTable);
//             printf("0x%X\n", ((DWORD*)pWorld->pLocal->knife->VTable + 1));
// 
// Grabbing the function address
//             DWORD * vTable = (DWORD*)pWorld->pLocal->knife->VTable;
//             printf("0x%X\n", vTable[0]);
//             printf("0x%X\n", vTable[1]);
///////////////////////////////////////////////////////////////////////////////////////
 
Last edited:

Rake

Cesspool Admin
Administrator
Jan 21, 2014
12,074
78,998
2,371
This makes me hot, nice work!
 

Solaire

Respected Hacker
Dank Tier VIP
Dec 15, 2013
1,051
16,353
62
C++:
class world;class playerent;
class weapon;


class world{
public:
	playerent* pLocal; //0x0000 


};//Size=0x0004


class playerent{
public:
char _0x0000[840];
	weapon* knife; //0x0348 
	weapon* pistol; //0x034C 
	weapon* carbine; //0x0350 
	weapon* shotgun; //0x0354 
	weapon* subgun; //0x0358 
	weapon* sniper; //0x035C 
	weapon* assault; //0x0360 
	weapon* cpistol; //0x0364 
	weapon* grenade; //0x0368 
	weapon* akimbo; //0x036C 


};//Size=0x0370


class weapon
{
public:
	virtual void Deconstructor(); //
	virtual int dynspread(); //
	virtual float dynrecoil(); //
	virtual bool attack(vec& targ); //
	virtual void attackfx(const vec& from, const vec& to, int millis); //
	virtual void attackphysics(vec& from, vec& to)(); //
	virtual void attacksound(); //
	virtual bool reload(bool autoreloaded); //
	virtual void reset(); //
	virtual bool busy(); //
	virtual int modelanim(); //
	virtual void updatetimers(int millis); //
	virtual bool selectable(); //
	virtual bool deselectable(); //
	virtual void renderstats(); //
	virtual void renderhudmodel(); //
	virtual void renderaimhelp(bool teamwarning); //
	virtual void onselecting(); //
	virtual void ondeselecting(); //
	virtual void onammopicked(); //
	virtual void onownerdies(); //
	virtual void removebounceent(bounceent * b); //
	virtual int flashtime(); //
};//Size=0x0004
Same as before. Set a world pointer as 0x50F4F4, and let the magic begin.

You are going to have to go through and figure out which ones are __fastcall and which ones aren't. Haven't delved deeper into it yet, but some of them only work with __fastcall. You'll also need to recreate the vec and bounceent classes, or set them as void *'s and not call them (Unless you have a pointer to a bounceent or vec).
 
Attention! Before you post:

Read the How to Ask Questions Guide
99% of questions are answered in the Beginner's Guide, do it before asking a question.

No Hack Requests. Post in the correct section.  Search the forum first. Read the rules.

How to make a good post:

  • Fill out the form correctly
  • Tell us the game name & coding language
  • Post everything we need to know to help you
  • Ask specific questions, be descriptive
  • Post errors, line numbers & screenshots
  • Post code snippets using code tags
  • If it's a large project, zip it up and attach it

If you do not comply, your post may be deleted.  We want to help, please make a good post and we will do our best to help you.

Community Mods