How to manually cheat games in ppsspp on windows.
(you can try on linux, Android, and Mac should be similar)
Get memory heap viewer with the ability to write back to RAM. I suggest
HxD.
DISCLAIMER: Use with caution you can seriously mess stuff up with this. YOU HAVE BEEN WARNED! I take no responsibility for how you use this program or guide!
1st understand how memory values are stored: (normally I explain later on). This is useful because ppsspp handles memory a little bit weird (v7-161).
Memory values are stored in Base16 a.k.a hexadecimal (123456789ABCDEF).
in hexadecimal there are 3 sizes you will normally be dealing with. (this is important to understand because you will know how to format your searches correctly).
This list will show base10 (decimal) value of 98 for an example. To convert from base10 to base16 you can use The windows stock calculator. Just Put it into programmers mode and the left hand side will have a list allowing you to change between Hex and Dec. Or you can use an online calculator.
- 2byte: 0062
- 4byte or Dword: 00000062
- 8byte: 0000000000000062
Remember the Zero spots are Important!
2nd how memory is set-up on ppsspp(v7-161):
First we have to figure out where ppsspp stores the values from the game your playing. To do this we have to calculate the offset of the games data on the system memory level of addresses.
Sad to Say THIS HAS TO BE DONE EVERY TIME YOU WANT TO CHEAT
- Open up the Debug console in PPSSPP, then set the calculator to hex values.
- Find the Memory Base(usually third line in the debug log)(Where PPSSPP is storing its values in system memory) and copy it to the calculator and notepad if your using one (I suggest you do.)
- Find the UserSbrk offset(Where PPSSPP stores the games variables in PPSSPP scope of memory range) and add it to the Memory Base
Usually doesn't change but might so check it after every new release.
Value is 08d2bd00
- The results are the location of the games variables in terms of the system's memory address .
I will now call this The offset. This is useful to narrow your search range and to be-able to use the cheats you find again without looking for them (or at least till PPSSPP changes how it stores memory)
Next we need to learn how to use the program. if you use a different program well your sol
lol
- To be able to manipulate a programs values while it runs We need to:
- open our memory heap viewer.
- Select the Extras tab
- Select Open Ram
- Select PPSSPP from the window that pops-up
Useful functions to work with.
- Search > Find (Ctrl + F), to go to next result its (F3)
- You will Most likely always be searching for hex values.
- Search > Find reverse (Shift + F3)
- Search > Go to (Ctrl + G), jumping to an address
- File > Save (Ctrl + S) used to write your changed values to Memory
- View > Byte Group Size > 4 Useful to try and organize the data so you can eliminate some variables without modifying them (i.e. oddly positioned in the blocks for the value size)
There's a lot more but you'll figure it out if you explore it longer
Now on to how PPSSPP stores it memory values:
- First PPSSPP stores its memory backwards
- a psp probably stores its variables like this: A,B,C
- PPSSPP stores its variables like this: C,B,A
Because the values are stored backwards even the memory bytes are backwards.
- Normal 4byte hex Value for 1000: 00 00 03 E8
- PPSSPP 4byte hex Value for 1000: E8 03 00 00
This gets tricky but just remember the sets(bytes) get reversed not the numbers in the set. This is the Value you look for .
Now to search for some values:
- In HxD Go To the start of the offset block
- Transform the decimal value into the modified hex value PPSSPP uses.
- Search for that value
- Either change the value and save, Check it. if it doesn't work you might want to change it back because it might crash the emulator.
- Or change the value in game by modifying its status and click the block your watching to update its value. If it changes then that's the one.
When you find a value record:
- It's name
- Its address start block minus the offset value (Because it will
always be in the same place till PPSSPP memory save style changes)
But let's set some ground rules for these sheets until cwCheats become working . (If it gets popular enough I will write a small program on the side when I get some free time )
Code:
_I GameId
_G Game Name
_V Working PPSSPP version:
_O UserSbrk offset (should stay relatively the same and useful to determine change and codes validity)
_U UserSbrk size ^^^^
_C notes such as creater of codes
_N Name of value and any notes
_L offset location of Value
_S byte size if known ex.2,4,8
Repeat
Post somewhere, somehow for others.
How to use your old values:
Now once you have the sheet do these steps to use it.
Calculate your offset (memory base + UserSbrk offset)
- add the offset to the location value in sheet
- Go to the new location
- Change the value to what you want based on ppsspp way of handling hex values
- repeat.
- profit
Tips:
- Know the data size for the value your looking for it will be much easier.
- Longer more special values are easier to find.
- Use a cwCheat list for that game. (please see further down about cwcheat sheets tho).
- psp and ppsspp have aligned memory blocks. Meaning the variables fall in the same order
hp > mp > money. but backwards so money > mp > hp
- If you have two values close find the difference that's their size and look for them together. Makes it a lot easier to track down tricky low number values like HP and MP
- If in the cheat sheet the value is high look at the begging of the block, If low than look towards the end of the block.
have any Tips post them
CwCheat sheets:
Even though psp and ppsspp have aligned memory's, ppsspp is early on in its life and its memory blocking isn't as conformed as psp and it has massive space between blocks of variables.
This means That at this time cwCheats sheet codes will not work with any equation you try and should only be used as reference sheets for size, speculative position, and value amounts.
Hope it Helps And maybe we can figure out a way to spread some of those cheats
Here's an example of what the code sheet should look like
Code:
_I ULJS-00266
_G .HACK//LINK
_V 7-161
_O 08d2bd00
_U 01194300
_C CREATED BY c0nK3R
_N GP or MONEY
_L 18FA10
_S 4
_N Tokio's HP
_L 8682E
_S 2
_N Tokio's MP
_L 86830
_S 2
_N Tokio's EXP.
_L 738B88
_S 2
Also you can follow some of this guide for modifying save states, but honestly they are too random to be efficient at this task(ex. different rooms will have different location values with a save state).
-Extra note-
Just because the file says it was tested on an early build doesn't mean it wont work.
Also when a value does migrate not all of them do. and the ones that do are usually less than +-2000 bytes away from where they were before.