Where to start in game hacking?

Anything Cheat Engine related, bugs, suggestions, helping others, etc..
Post Reply
ShyTwig16
Expert Cheater
Expert Cheater
Posts: 335
Joined: Thu Apr 06, 2017 7:14 pm
Reputation: 21

Where to start in game hacking?

Post by ShyTwig16 »

Preamble:
So I was asked "Can you give a brief explanation about how you build cheat tables like this?". And so I started writing, then when it got larger I thought it might help others if it was posted somewhere that was easier to find. And just got larger from there. So this is more how I started with hacking games.

And I encourage other table makers to give their own explanation of how they started as well. And what where the pitfalls and hard lessons along the way.

And to anyone who might be linked to this in the future or stumble across it, none of this is meant as an attack on you. It's just things that need to be stated and I myself need to be reminded of, from time to time.


Where to start:
Start with the [Link] and just finding the values you need. All the lua adds an overly complicated layer that will generally hinder you when starting out. For me I spent about 5 years making tables before adding the Lua stuff, with the exception of minor things like calculating an address stored in an instruction in a 64 bit process. I even spent some time with just ASM, I installed a NASM assembler and a FASM assembler and wrote simple programs just to try things out. And worked with both to better understand ASM as a whole. And yes this was all done while working full time and still having a life. But there where weekends were all I did was this.

So first thing is how to find the info you need. And this seems to be the hardest part for most people. I post all the time and most get offended by it, and stop there because they know all there is to know about that. And refuse to admit that not finding what they need proves that to be false, and assume the info doesn't exist or there is some elaborate plot to hide things from them. And yes, I have literally been told this more than once plus slurs and many choice words. And yes I have watched that video more than once myself, we all forget things and even need to absorb things in layers. So you need to have the humility to start with the most basic things even if you think you already know it. And when you can't find what you are looking for, just know that others can. This is how I found NASM and FASM, simply by wanting to start with the most basic set up I could that has lots of documentation. And I didn't find it with the first search. The number of times I've been asked for a link to a tutorial is ridiculous. Most times what they "can't find" is right in the tutorials section of this form, it's in the tutorials section of the CEF, and in the tutorials section of the wiki, and it's been posted a thousand times on youtube. And yet it's like some mystic secret that no one can find, in their mind. Go through the CE help file (F1 in CE), the [Link], this forum (not so mutch the tables, trainers, or requests sections; more so everything else), and [Link]. I wrote a lot of the CE wiki just because I got tired of the help file and scrolling the CEF just to find something I forgot. But I still went through all of it just to learn all I could from it.


Don't get mad, learn to control your emotions like you are learning to control the game:
If you are getting mad you need to just walk away for a bit, til you can learn not to let your emotions control you like an adult. Though this is something many adults lack, and even think the walking away is mature. When in reality walking away is what you should learn as a kid, and as an adult you need to learn to control your emotions. Computers don't care about emotions they only use logic. And most people don't want to help assholes, I tell assholes "piss off and good luck". And when your GF or BF or whatever, says to take a break listen to them and take a break, eat some food and come back to it later. Take notes and don't be afraid of starting over. If you try to mount a horse from behind and get kicked, it's better to retry from the front or side. Refusing to do so will only hurt you, and the horse will just keep kicking you.


Learn the etiquette of the community:
I actually spent the first 5 years making tables without a CEF account and never posted any questions, because I understood [Link] like with any community before I even knew what it was. I learned this with other things like learning woodworking and how to golf as a kid, every community will have an etiquette and failing to understand that will only hinder you. I was just as interested in learning the etiquette as how to hack games. I started with only searching and reading, I read all the info I could find any chance I got. I scrolled through the CEF and read every post I could find on ASM and the CE's auto assembler. I looked at how other's set up their tables and what they found.

Don't use the findings of others without giving credit, this will alienate you from the community and hinder your progress. And if you make a habit of it, you will get banned. And some here do help with DMCAs and getting it removed from other sites, so just going somewhere else won't really work in the end. Most of my table's get reposted on other forums, but because they give me credit I don't mind. Even if you actually write a script yourself. But use someone's findings, give them credit. Often finding the values can be the hardest part. I have countless table's with other's scripts, or my own script based on their findings and have not had any complaints because I always give credit where it's due. I learned to always put the person's name/id in the script's description, so I didn't forget where it can form years later. And make a "made by"/"credits" section when posting tables. If you have something older and can't remember where it came from, just say so when you post it. Admitting it's not yours, looks a lot better than making it seem like it is yours (even if that wasn't your intention). And yes posting a table with no explanation of where it came from, looks like your saying it's yours. Imagine you spent years learning how to do something and then hours doing it, and someone claims they did it or simply doesn't give you credit. It's a shity thing to do and a shity thing to have happen to you, and you'd be rightfully pissed about it. And yes they will have the fortitude and dedication to do something about it, and will outlast you since you didn't even have the fortitude and dedication to do it yourself.


Try things out and keep it simple:
Then don't be afraid to just try things out. Yes you will have times when you crash your game/program over and over and over again. If you are posting questions like "will this work", it's do to fear and you need to just try it. Break things down to better understand how they work, don't run 100 lines of code run 2 or 3 lines. Yes this is more work and coding, but you will learn more about each piece of the whole. And I often worked with simple games I didn't even like playing, just to make things as easy as possible. I have also done the CE tutorials more times than I can count. Then if there is something you have spent days trying to figure out and still haven't. Then ask your question in a helpful and intelligent way, and be patient and allow time for someone to answer.


Don't fall prey to target fixation:
Don't get fixated on any one thing. If I couldn't figure it out, I want back to something more simple. This also seems to be a hard part for most people, they get fixated on some hack they want on some specific game and forget they need to learn to hack first. Yes flying a jet fighter looks cool and who doesn't want to learn to fly one, but if you jump straight into a jet fighter with no knowledge of how to fly. You will crash and burn, and many have before you. Just think about how you learn math, you don't start with quadratic equations, you start with addition. If you don't know how "1 + 1 = 2" works you'll never understand how "ax^2 + bx + c = 0" works. Vincent van Gogh didn't start with " The Mulberry Tree", he likely started with shitty drawings as a kid and shity paintings as an adult. Hell the dude went mad and cut off his own ear at one point. So just know learning things drives everyone a little crazy, just try not to cut off your own ear (this is also a good metaphor for getting mad at the people that try to help you, and being an asshole so they stop helping you).


Learn programming:
Once you get to where you can read and write the AA scripts and understand them well. Then you might think you want to use your own templates, so you find some CE extensions/tools that someone wrote and see how they did it (the simpler the better). Use and even modify them to work like you want or add your own stuff to it. And install Lua and use just Lua without CE just to better understand lua as a whole. Write simple programs that you really don't need just to learn some lua. Try writing the same simple programs in Python and C# and Pascal/Delphi (these are what CE is written with, so it will help you find even more on how CE works when you can read it's source code), just to understand programing better as a whole. And use the same steps as above to learn programming or at least the basics of how it works.

Then you might start writing your own template extension from scratch. And yes write from scratch, copy and pasting is nice but you tend not to learn anything other than Ctrl+C and Ctrl+V. So write code and write code and write some more, til you actually understand the code you want to copy or use. Use the Lua engine to just output simple things to understand what they do, you can't understand a full module/extension til you know what every line of code is actually doing and what every call returns.

Then you might start thinking of a way to use an external editor, and then start with a Lua module to assist you in doing that. Then you need some code to be able to use the lua module as a table file so you find out how to do that. And so on down the rabbit hole til you find yourself using 10-15 lua modules, for some dumb reason (for those who don't know I'm talking about myself here).


How I build my tables (a very basic explanation):
As for how I build my table's now. I find a value, say health. Then I find what writes to it when it is decreased. Then backtrace the games code to find where it actually decreases the value and not just writes the new value, this is what took years to do well (and by well, I mean no longer pulling my hair out). Then if say all entity's health is decreased by the same code, I then look for a way to distinguish the difference. For me the easiest way is to store the player's health base address and compare it later. So I make an AOB script (using a template) for the health decrease code and put it away for latter. Then find what accesses health and look for something that fires constantly but only access player health, and some times this means backtracing til I find a static address or at least a base pointer that has an instruction that only accesses the one address. When I find that, I then make an AOB script (using a template) to store the base address for later (searching for "injection copy" will help you find more on that). Then back to the decrease code, I then use the stored base to compare and set up a multiplier for damage (decreasing value). And then test, test, and test some more. Restart the game, restart the computer, try it with different versions of the EXE. Find what works and what doesn't work. Then with time you'll need less testing out of the gate, because you'll know what works and what doesn't. Then I move on to the next value I want to manipulate, and on down the rabbit hole til you have a table with the features/hacks you want.

User avatar
Warda
Cheater
Cheater
Posts: 28
Joined: Sun Dec 30, 2018 3:27 pm
Reputation: 12

Re: Where to start in game hacking?

Post by Warda »

Really good post, thanks for sharing this.

Fully agree with what you are saying - it made me think about my own experiences.

I'll be honest, there have been many times where I've come on FRF or CEF, and just click into random posts where people are asking generic CE related questions (latest example: viewtopic.php?f=16&t=18782). And I'll just sit there and read through each post and (embarrassingly) just wish I could understand what people are saying.

For me, my issue is I just never knew where to start. I'm not computer literate by any standards and I lack confidence massively. Like you said above about just trying things, I was always too scared of breaking things to be honest lol... I once tried doing something new that I learnt through the CE tutorial a while back, basic stuff - (sorry if I butcher any terminology) I remember wanting to try something new, so I loaded up a game I used to play (forget which game it was now) on the UE4 engine. Normally I'd just look for my money value and freeze it to give myself unlimited funds, but I wanted to experiment and try learn a different way of doing it. Long story short, I tried to instead find the instruction that decreased the value and re-write it to do something different like giving the player money instead of taking it, or just nil-ing it entirely. I remember finding the instruction (or at least I thought I did - I *think* it may have been a 'mov' instruction), and I nop'd it at first to see what would happen, and I remember not the program crashing but what I can only describe as my whole PC graphics going haywire. After that, I completely just lost all confidence in my abilities and to be honest I gave up entirely before I'd even started... Genuinely thought I'd bricked my PC for a moment lol

But, then I go back and think on what I have actually been able to do then reflect on what I couldn't do 10 years ago. To most it's bare basics but for me it was a massive achievement building a table from just finding pointers, and sharing it on the forum felt amazing. Looking and seeing over 1k downloads to me was just crazy lol.

I remember making a table for the Parasite Eve 2 (PS1 Game) on an emulator, and uploading it on CEF. At this point I think I was just experimenting with the memory viewer. The game had an inventory system similar to the old Resident Evil games on the PS1 (Slots 1-8). And I'd sit there moving items into each slot and scanning for changes until I found the right address, then noticing that the adjacent set of bytes stored the ammo amount. Changing the data type from Byte to Array of Bytes I was able to make a really basic inventory editor, but as I had no idea how CE really worked and I didn't even know what a pointer was at that point. I remember spending hours and hours finding the index value for each and every item in the game - I think I'd uploaded it and for others it didn't work. So I shared the methods I used to create the table so others could make their own instead (since I had no idea how to fix my own lol).

Point of my long, boring-ass story is I think I was just biting off more than I could chew. I went through thinking, "well, do I need to learn ASM to achieve x, y and z - or do I need to learn lua now?" and it would be a constant battle of "where the actual hell do I even start to do half of the stuff the table makers are doing!?". When in actual fact, I just (for me at least) needed to start with the absolute basics and take my time with it, and just be happy that I've actually learnt something new at all lol.

Massive respect to all the table makers and contributors on here, I can only imagine the immense amount of work behind it - not just the contents/features of the tables, but the hours invested learning how to pull it off.

Post Reply

Who is online

Users browsing this forum: No registered users