No, I meant the plugin's code 
Well the code below should work so maybe there's an error somewhere else in the code.
Well the code below should work so maybe there's an error somewhere else in the code.
void printReadValue(u32 addr, u32 pos)
{
char *buffer;
char buf[9];
pos = gamePluginMenu.offsetInBuffer[pos];
buffer = &gamePluginMenu.buf[pos];
while (*buffer != 'x' && *(buffer - 1) != '0' && *buffer != '\0')
buffer++;
if (*buffer == '\0')
return;
if (*buffer == 'x')
buffer++;
memset(buf, '\0', 9);
xsprintf(buf, "%08X", READU32(addr));
strcpy(buffer, buf);
}
// init
void initCheatMenu() {
initMenu();
addCheatMenuEntry("ATK monst 2");
addCheatMenuEntry("ATK monst LEADER");
addCheatMenuEntry("ATK monst 3");
addCheatMenuEntry("ATK monst 4");
addCheatMenuEntry("ATK monst 5");
addCheatMenuEntry("ATK monst 6");
addCheatMenuEntry("READU32 = 0x00000000");
updateMenu();
}
printReadValue(0x145EAEB0, 6);
Hmmm, your code seems right.
Probably the base pointer is not the right one.
I wrote a little function to change a menu entry with the value we read at a specific address (untested).
Code:void printReadValue(u32 addr, u32 pos) { char *buffer; char buf[9]; pos = gamePluginMenu.offsetInBuffer[pos]; buffer = &gamePluginMenu.buf[pos]; while (*buffer != 'x' && *(buffer - 1) != '0' && *buffer != '\0') buffer++; if (*buffer == '\0') return; if (*buffer == 'x') buffer++; memset(buf, '\0', 9); xsprintf(buf, "%08X", READU32(addr)); strcpy(buffer, buf); } // init void initCheatMenu() { initMenu(); addCheatMenuEntry("ATK monst 2"); addCheatMenuEntry("ATK monst LEADER"); addCheatMenuEntry("ATK monst 3"); addCheatMenuEntry("ATK monst 4"); addCheatMenuEntry("ATK monst 5"); addCheatMenuEntry("ATK monst 6"); addCheatMenuEntry("READU32 = 0x00000000"); updateMenu(); }
And in your gamePluginEntry function, put this in the while loop:
Code:printReadValue(0x145EAEB0, 6);
If it's correctly working, it should change the entry in the menu with the value stocked at the address you provided. This way you should be able to confirm if it's a pointer or not easily.![]()
If you have the address where the coins are stocked, yes you can show it in the menu by changing the plugin's menu buffer.
Also, you can code a function to search through the ram to find a value or address.
Actually i made this, so as you can see, we can show and navigate through the memory.
Now aside from showing, you can also analyze it to find what you're searching for.
Actually it's, I believe, just like the Gateway's cheat menu act. It dump the ram then analyze it. You can do it too with a plugin, but you have to code it.![]()
You have a gateway, so you should just do ram dumps then use the soft for searching pointers. When you have the first one, search for pointer to pointers until you have no results. That should work no ?
Yea i think thats the one im using xDI don't own a gateway so i'll be a bit helpless in this domain. :/
But, on maxconsole forums, i read a tuto on how to find pointer with a dump made by a gateway. It's not working with ntr, but seems like the soft is clearly made to find pointers.
Try to find this one, and you should be able to find the pointers.![]()
Yes, it's the one. x)
It's not working ?
You just have to make more dump, and compare the list. Then take one whose the same on all the dumps.![]()
lol offsets seem a whole world for me. Maybe this is a little bit too much, but where can I read about offsets with pointers?An other pointer or maybe your not supposed to read the value from the second pointer but from the second + offset ?
I, for one, would really love a tutorial on finding pointers and offsets. I'm also trying to use the NTR Debugger, but I sometimes bump into some dead ends. A tutorial would be incredibly useful.Success! So I learned about offsets and I was able to make it work finally!
The main problems I had were that I really didn't remember much about C, pointers and the offsets.
I had to learn about them and how they are applied and yea basically make it happen!
I can make a tutorial if anybody gets interested
Thanks @Nanquitas for your awesome help!
Thanks, I appreciate it!It's really simple once you go through hell and learn everything in 1 day hehe but yea, absolutely, I will make a tutorial then.
It will take me a few days or so to get my ideas right but I will try to do it xD