Source Code Fivehax library

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat

c5

Kim Kong Trasher
Dank Tier VIP
Dank Tier Donator
Jul 19, 2012
1,187
12,638
76
*** Latest version/Updates available on github: https://github.com/citizen5/Fivehax ***

General Information/instructions:

Fivehax is a little wrapper sort of library I wrote to simplify the means of managing memory, could come in quite handy for beginners.

The library consists of two main parts: One consists of functions meant to be used when your application is an external executable. Second part consists of functions meant to be used when your application is going to be an injected dll.

To specify, how are you going to use the library, you must define one of the two in the top of the Fivehax.h
C++:
//#define __AS_DLL		// uncomment if you're building a dll (internal)
//#define __AS_EXE		// uncomment if you're building an executable (external)
Now if you are building an executable, you must also, before using any functions, call the Initialize function with atleast one of the opt parameters.
C++:
void Initialize(DWORD opt_procId, HWND opt_hwnd, char* opt_windowClassName, bool enableDebugPriv);
However if you are building a dll, you don't have to do it. It is also a good habit to call the destructor afterwards you have finished with using the library (only as an executable again)

And now you are all set to use all of the library's functions :)

Here are the features and some examples:

  • Enable debugging privileges
  • Get module's base address
  • Calculate base to dynamic address
  • Evaluate pointers
  • Patch opcodes
  • Read data (int, float, byte)
  • Write data (int, float, byte)
  • Allocate memory
  • Free memory

C++:
// Example of reading and writing memory externally
Fivehax memory;
memory.Initialize(NULL, NULL, "Game", 1);
int money = memory.Read<int>(0xF84212);
memory.Write<int>(0xF84212, money+50000);
memory.~Fivehax();
C++:
// Example of beating DMA internally
Fivehax memory;
DWORD offsets[] = {0x4F; 0x4; 0x16C};
DWORD endAddress = memory.BaseToDynamicAddress(0x2450FF, offsets, 3);
I might gradually update the library and add new features. Credits included in the Fivehax.h. All sorts of ideas and suggestions are welcome :)
 

Attachments

Last edited:

Rake

Cesspool Admin
Administrator
Jan 21, 2014
12,380
78,998
2,414
Looks great c5. Thanks for sharing. :)
 

c5

Kim Kong Trasher
Dank Tier VIP
Dank Tier Donator
Jul 19, 2012
1,187
12,638
76
Thank you very much. Please report back any bugs you find :D
 

Chuck E

Coder
Dank Tier Donator
Nobleman
Jan 2, 2013
122
588
1
This is excellent. So freaking useful. Thanks for sharing this :)
 
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