Solved GMOD Hack - How to make BunnyHop

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat

iDo1M

Newbie
Full Member
Nov 10, 2015
6
52
0
Hello, I watched all the 4 tutorials of how to make a bhop script to CS:S, and I tried to make it to gmod.
I tried to launch it and it doesn't find the process so I believe the problem is in HackProcess.h , and I'm using his main source code to make sure there's no problem in the code.

I'm not sure about the offsets too, if someone could check why can't it find any process & if it's related to the offsets too it'd be great!
Thanks!

main.cpp: https://pastebin.com/QrU2YFPw (didn't change anything besides the offsets).

HackProcess.h: https://pastebin.com/tr3NENFr

Thanks!
 

mambda

headass
Escobar Tier VIP
Trump Tier Donator
Jun 25, 2014
2,298
37,938
269
C++:
        if(MyPlayer.m_fFlags ==  FL_ONGROUND)
        {
                //bHOP bay bay
                WriteProcessMemory(fProcess.__HandleProcess, (PBYTE*)(fProcess.__dwordClient + dw_Jump), &b_True, sizeof(bool), NULL);
        }
        //If we are in the air reset the flag so we can jump again after
        else if(MyPlayer.m_fFlags != FL_ONGROUND)
        {
                //bHOP bay bay, SWITCH off jump
                WriteProcessMemory(fProcess.__HandleProcess, (PBYTE*)(fProcess.__dwordClient + dw_Jump), &b_False, sizeof(bool), NULL);
        }
Player flags is a bitfield, where'd you get that define? Last i checked all source engine games have this as the flag.
#define FL_ONGROUND (1<<0)

and with it being a bitfield, you dont check if its EQUAL to that, you check if that bit is flipped. i.e. if ( flags & FL_ONGROUND ) // then you are on the ground.
 

iDo1M

Newbie
Full Member
Nov 10, 2015
6
52
0
Rake;38107 said:
is the GMOD executable named "hl2.exe"?
Yes, hl2.exe *32


C++:
        if(MyPlayer.m_fFlags ==  FL_ONGROUND)
        {
                //bHOP bay bay
                WriteProcessMemory(fProcess.__HandleProcess, (PBYTE*)(fProcess.__dwordClient + dw_Jump), &b_True, sizeof(bool), NULL);
        }
        //If we are in the air reset the flag so we can jump again after
        else if(MyPlayer.m_fFlags != FL_ONGROUND)
        {
                //bHOP bay bay, SWITCH off jump
                WriteProcessMemory(fProcess.__HandleProcess, (PBYTE*)(fProcess.__dwordClient + dw_Jump), &b_False, sizeof(bool), NULL);
        }
Player flags is a bitfield, where'd you get that define? Last i checked all source engine games have this as the flag.
#define FL_ONGROUND (1<<0)

and with it being a bitfield, you dont check if its EQUAL to that, you check if that bit is flipped. i.e. if ( flags & FL_ONGROUND ) // then you are on the ground.
It's from fleeps' sourcecode, it's supposed to be right.
When m_fFlags==257 it means that the player is on ground.

My problem is that it doesn't find the process, probably something wrong in HackProcess.h.
HackProcess.h is built for CS:S and I tried to change it to work on gmod.
 

Rake

Cesspool Admin
Administrator
Jan 21, 2014
12,118
78,998
2,392
use the visual studio debugger, put a breakpoint on:
C++:
fProcess.RunProcess();
step through the code one line at a time
 

iDo1M

Newbie
Full Member
Nov 10, 2015
6
52
0
Rake;38110 said:
use the visual studio debugger, put a breakpoint on:
C++:
fProcess.RunProcess();
step through the code one line at a time
I'm using codeblocks, couldn't see anything with the debugger :#
 

mambda

headass
Escobar Tier VIP
Trump Tier Donator
Jun 25, 2014
2,298
37,938
269
Also, call get last error after you try to get the process. i'd bet somethigns screwed up there. goodnight
 

Rake

Cesspool Admin
Administrator
Jan 21, 2014
12,118
78,998
2,392
Put a breakpoint in your getprocess function and step through the code looking at the local variables
 

iDo1M

Newbie
Full Member
Nov 10, 2015
6
52
0
Rake;38136 said:
Put a breakpoint in your getprocess function and step through the code looking at the local variables
Tried debugging it but the local variables didn't show up as I saw in debugging tutorials and I didn't know what to look for.. I just can't get it to work I guess I'm just gonna learn more C++ before touching it again, any recommended book? :#
 
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.

Similar threads

Community Mods