Cheat engine how does it work




















This question and this question discuss similar things. Sign up to join this community. The best answers are voted up and rise to the top. Stack Overflow for Teams — Collaborate and share knowledge with a private group. Create a free Team What is Teams? Learn more. How does a software like Cheat Engine work? Ask Question. Asked 8 years, 9 months ago. Active 2 years, 10 months ago.

Viewed 5k times. Improve this question. Mark Amery 1 1 gold badge 2 2 silver badges 13 13 bronze badges. Add a comment. Active Oldest Votes. Improve this answer. So, how is memory protection useful if a process has these kind of means for interprocess memory access?

Gonzalo on Linux there are the user permissions, a normal user can't attach a process as a debugger to one which belongs to root, you can make this attach only if you have the right permissions what make the protection still useful — Horus. Attaching to a process as debugger sends sigstop s, doesn't it? Not sure about Windows, but at least that's the way Linux works, this makes every read and write to the process memory safe no race conditions but makes the process paused for a while.

Community Bot 1. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Click Download Cheat Engine. It's a large link in the middle of the page. This button will also have the current version of Cheat Engine listed on it e. Install Cheat Engine. Doing so will vary depending on your computer's operating system: Windows — Double-click the Cheat Engine setup file, click Yes when prompted, click Next , check the "I agree" box and click Next , click Next three more times, uncheck the "I agree to install McAfee WebAdvisor" box and click Next , and click Install.

Once setup completes, click Next if prompted, then click Finish. Mac — Double-click the Cheat Engine DMG file, verify the installation if prompted, click and drag the Cheat Engine logo onto the "Applications" folder, and follow any on-screen instructions. Part 2. Start a game. Open the game that you want to use with Cheat Engine. Remember, this cannot be an online multiplayer or server-based game. Click the "Processes" icon. In the Cheat Engine window, click the computer-shaped icon in the top-left corner.

This will open a pop-up window with your computer's current programs in it. Select your game's process. Scroll through the list of processes until you find your game, then click the game's name. If you're attempting to use Cheat Engine for a browser game, you'll select your browser's name instead. If your game doesn't appear in the "Processes" list, you cannot edit it in Cheat Engine. You may first have to click the Processes tab at the top of the window.

Click OK. It's at the bottom of the window. This will open the game in Cheat Engine. Part 3. Determine a game aspect to change. In order for you to be able to change a game aspect, the aspect must have a number attached to it e. The number must be on-screen. For example, if you want to change the number of a certain item in your inventory, you would first have to open your inventory to the page on which the item's number is available.

Minimize the game window and click over to Cheat Engine. You'll need to pull up the Cheat Engine window while the game is minimized. Don't pause the game when you do this. All rights reserved. This image may not be used by other entities without the express written consent of wikiHow, Inc. Click New Scan. It's at the top of Cheat Engine next to the panel on the left. Any time you want to scan for a new value, you need to click New Scan. Select a scan type.

There are five scan types you can do when you start a new scan. The two main ones you'll be using are "Exact Value" and "Unknown initial value". Use the drop-down menu next to "Scan Type" to select the type of scan you want to do. The scan types are as follows: Exact value: Use this scan type if you know the exact number you want to change. For example, if you know the exact number of lives, or ammo you have, you can select this option.

Unknown initial value: In video games, sometimes a value isn't represented with a number. For example, your health may be represented by a health meter instead of a number. In which case, you don't have an exact number for how much health you have. There is a number that represents your health, you just don't see it on-screen. In this case, you can select Unknown initial value. Bigger than Smaller than Value between Select a data type: The data type represents how a value is stored in the memory.

It can be hard to know what data type to select, so this can take a little guesswork. Use the drop-down menu next to "Data type" to select a data type. If you can't find the value you are looking for using one data type, click New Scan and try again using a different data type.

Some of the more common data types you will be using are as follows: Bytes: 2 Bytes and 4 Bytes are the data types you'll be using most often. Most Windows applications use 4 Bytes, so start with that. You can also find these values using 2 Bytes. Float: Floating point data types are values that have a decimal point in the value though you may not see the decimal point on-screen in the game.

Some times games store values as floating points to prevent simple memory scans. If you're not able to find the value you are looking for by scanning bytes, try scanning for floating points.

Double: Doubles are similar to floating points, but they can contain twice the amount of digits. If you are unable to find a value by scanning for bytes or floats, try scanning for it as a double. All: This option scans all values of all data types. This is a good option if you don't know what you are searching for, but it will also return more search results that you will need to narrow down.

Enter the value you want to change and click First scan. For example, if you have 20 bullets left in your ammo, you would type 20 into the "Value" text box. This will scan for all values that have the number "20" in it. This will likely produce a long list of values in the list of addresses, you'll need need to narrow it down a bit. Return to your game and change the value. How you do this will depend on the game itself; for example, if you're trying to give yourself more health, you might purposefully damage your own health in order to lower the number.

If you want more ammo, you might fire a couple of shots to lower your ammo count. Return to Cheat Engine and scan for the updated number value. Minimize the game again and click back over to Cheat Engine. Type the new number into the "Value" section, then click Next Scan. This will scan all the values in your first scan and narrow down the addresses to the ones that changed to the value you entered in the "Value" bar.

Unknown initial value: If you selected "Unknown initial value" for your first scan, select Increased value or Decreased value under "Scan type" depending on if the value or meter increased or decreased. This will scan for all values that increased or decreased instead of scanning for an exact number. Repeat the search process until you have 4 or fewer values. You'll keep changing the number and then searching for the updated number until you have no more than 4 values listed on the left side of Cheat Engine.

You should eventually see the previous number you searched for listed in the "Previous" column of each value's number, while the current value of the item will be in the "Value" column. Add the values to the address list. You can either double-click a value to add it to the address list at the bottom, or you can click an address to select it and click the red, diagonal arrow in the bottom-right corner of the list of values.

Doing so will place the values in the list of addresses at the bottom of the window. To select multiple addresses, you can hold "Shift" and click the top address and the bottom address.

Change the number to a value you want. Use the following steps to change the value number: Double-click the number below "Value" in the list at the bottom of Cheat Engine. Enter a new number in the "Value" field. Click Ok. Check to see if the value updated in your game. When you re-open the game, the value you edited should reflect the number you just entered.

The next part teaches you how to stop a value from changing by replacing it with non-operational code. You may need to change the value one more time before it will update. Part 4. Scan for a value you want to stop. This part teaches you how to use the Code Finder to find what writes to the address you want to change and then replace it with non-operational code.

This will prevent the value from changing in-game. Use the steps in the previous part to find a value you want to change. Add it to the list at the bottom of the screen. Right-click the address and click Find out what access this address. This opens the Cheat Engine Debugger. This displays instructions that write to the address you are accessing. Click Yes. This confirms that you want to attach the debugger to the Cheat Engine process. This opens the Code debugger.

The list will be blank when the window first opens. Return to the game and change the value again. Once again, return to your game and do something to change the value you want to stop. This will cause the code instruction that accesses the address you selected to appear in the debugger window.

Return to Cheat Engine and click the instruction in the list. There may be more than one address. If that is the case, select the one that doesn't write to the same base address. Look for the instruction that has a different value between the "[' and "]" brackets than the rest. Click Replace. This replaces the code with non-operational NOP code. Click Stop. This puts the non-operational code into effect. This will prevent the value from changing in the game. To restore the original code, select the item in the list and clck Show disassembler.

Right-click where it says "NOP" and click Restore with original code. If you don't see this option, click Replace with code that does nothing , click Yes. Then right-click NOP again and select Restore with orignal code. Part 5. Scan for a value you want to change. Sometimes values can change address either when you restart the game, or in the middle of the game. You can use pointers to find what writes to an address. Once you find the base level static address that doesn't change, you can change that value.

Right-click the address and click Find out what writes to this address. This opens the debugger window. If there is multiple addresses, open a debugger window for as many addresses as Cheat Engine will allow.

Once again, return to your game and do something to change the value you want to change i. This will cause the instruction that writes to that address to appear in the debugger window. If nothing changes in the debugger window, it is not the correct address. Try a different one. It's in the debugger window. If that is the case, look for the instruction that has a different set of characters between the "[' and "]" brackets than the rest.

If there isn't a single address that has different characters, check to see if the pointer is the same for all of them. That is an offset number. Write it down. You'll need it later.

Click More information. This displays instructions that happen when the value changes in the Extra Info screen.

This also lists the pointer that writes to the address. You can also find the address by checking the characters in the bracket, and then checking what number comes after those characters listed at the bottom. Click the checkbox next to "Hex" and do a new scan for the pointer address.

The address of the pointer is listed in the text that says "The value of the pointer needed to find this address is probably xxxxxxxxx". Use the following steps to search for the address at the end of this sentence. Click the checkbox that says "Hex" next to the "Value" field. Enter the pointer address in the Value field and click First scan.

Double-click the pointer address. This adds the address to the list at the bottom of Cheat Engine. If the address is listed in green in the scan results. This means it is a static address and probably the pointer you are looking for. In some cases, the pointer you find may also be a pointer.

This is called a multilevel pointer. In this case, you'll need to repeat these steps for each pointer you find in order to find out what the root static pointer address is. Double-click the number below "Address". This opens the "Change address" dialogue box. Copy the address in the field and click Cancel. To copy the address, simply highlight the entire text in the field at the top of the "Change address" box. Right-click it and click Copy.

Then click Cancel to close the field. Click Add address manually. It's the button on the left above the address list at the bottom of Cheat Engine.

This opens a box that looks similar to the "Change address" box, except this one allows you to add an address. Click the checkbox next to "Pointers". This expands the box and adds a new text field where you can enter a pointer. Paste the pointer address in the field below "Pointers" and click Ok. This adds a new address for the pointer that controls the value that you want to change.

This indicates that this is a pointer pointing to a specific address. If there is an offset number, enter it in the space above the field where you paste the address. If there is more than one pointer, click Add offset. This will add more offset number boxes above the area where you paste the address. Enter the correct offset number in each box. Click the "Active" boxe next to the pointer address you just added.

It's the box below "Active" in the list address list at the bottom of the screen. This activates pointer. Change the value of the address you just added. The value number for the pointer address you just created should be the same as the address of the value you searched for.

If the pointer writes to a different location, the original address you scanned for will no longer be valid. However, you can still change the value of the pointer address you just created. That will work no matter where it writes the value location to. Click the number below "value" for the address you just added.

Enter a new numeric value and click Ok. Part 6. This part teaches you how to use Code Injections to change how the code writes a value. For example, if you lose health every time you get hit, you can change the code so that it increases your health when you get hit. This will cause the code that accesses the address you selected to appear in the debugger window.

If that is the case, look for an instruction that has the word "sub" in the instruction to subtract from the value, or the word "add" or "inc" to increase the value. Click Show disassembler. This opens the code in the disassembler. Select the code that subtracts or increases the value. It is usually the first instruction at the top of the code. It will have wlll most likely have the word "Sub" or "Add" at the start of the code to subtract from the value or add to it.

Click Tools followed by Auto Assemble. This opens the auto assembler. Click Template followed by Full Injection. This displays a pop-up window that confirms the address you want to inject code into. Ensure the address is correct and click Ok. Ensure the address in the field is the same address you selected in the Memory Viewer disassembler window. Then click Ok. This opens a new template. Replace the code with it's opposite.

Scroll down to where it says "Code". The line below it is the code that changes the value. If the line starts with "sub", change "sub" to "add". If the line starts with "add", change it to "sub". You can also change the value at the end of the line to change how much you want it to change the value by. Click Execute followed by Yes twice.



0コメント

  • 1000 / 1000