NosTale Memory Pattern

03/18/2023 02:50 Florian.K#1
Hey,

I am currently attempting to code in Python and am using NosTale as a learning tool. Specifically, I am trying to read HP values, but I am having difficulty as the address for the current HP changes after each reboot. Despite my efforts, I have not been able to identify a pattern to consistently read the HP. Does anyone have any experience or tips they can share to help me with this issue?
03/18/2023 04:30 JONNST4R#2
hey,
you have to find a pointer that points to the hp value and find pattern for the pointer.
03/18/2023 08:42 Hatz~#3
Quote:
Originally Posted by Florian.K View Post
Hey,

I am currently attempting to code in Python and am using NosTale as a learning tool. Specifically, I am trying to read HP values, but I am having difficulty as the address for the current HP changes after each reboot. Despite my efforts, I have not been able to identify a pattern to consistently read the HP. Does anyone have any experience or tips they can share to help me with this issue?
Just wanted to mention that you don't pattern scan for a specific value (in this case HP) you use pattern scanning to find a specific instruction in the assembly code.

So the correct procedure would be to first find the memory address of the structure that holds the value you want (in your case the HP), then you have to find a static pointer to that structure address (green address in cheat engine) and finally you find a instruction in the code that access that static address (for example a mov eax, [xxxxxx]). Since the address will be embedded in the instruction bytes you can pattern scan for that address and get the static pointer to the structure you want.
03/18/2023 11:27 Apourtartt#4
In addition to Hatz comment, you can also use the "Pointer scan for this address" feature from Cheat Engine to find a static pattern (useful, as sometimes you will not end up with a static pointer)
03/18/2023 17:35 Florian.K#5
I always find the address for the HP, but I'm not quite sure how to find a static pointer with cheat engine.
Currently, I'm searching with the pointer scanner, but I'm finding over 163,000 entries.

Picture
03/18/2023 19:29 Apourtartt#6
Save those entries, close Nostale, restart and do that all over again until you don't have much left, and then you are done
03/19/2023 00:39 FI0w#7
Quote:
Originally Posted by Florian.K View Post
Hey,

I am currently attempting to code in Python and am using NosTale as a learning tool. Specifically, I am trying to read HP values, but I am having difficulty as the address for the current HP changes after each reboot. Despite my efforts, I have not been able to identify a pattern to consistently read the HP. Does anyone have any experience or tips they can share to help me with this issue?
If it reaches to get the % of the HP

patternAddr = PatternScan(
"\x50\x6a\x00\x6a\x00\x6a\x00\x6a\x00\x6a\x00\x6a\ x00\x33\xd2\x33\xc0\xe8\x00\x00\x00\x00\x8b\xd0\xa 1\x00\x00\x00\x00",
"xx?x?x?x?x?x?xxxxx????xxx????", 25);
source: [Only registered and activated users can see links. Click Here To Register...]

here the pattern to TPlayerMapObjManager with that you can get the own Character by getting the TMapPlayerObj
Then the Address of
TMapPlayerObj + 0xC0 -> HP %
TMapPlayerObj + 0xC1 -> MP %

both are int8 aka 8bit integer

but dont forget after a map Change the address to TMapPlayerObj changes so you need to re-read it from TPlayerMapObjManager so better if you use a function to always read it from there.

What could you help too:

[Only registered and activated users can see links. Click Here To Register...]
03/19/2023 02:58 Florian.K#8
Quote:
Originally Posted by Apourtartt View Post
Save those entries, close Nostale, restart and do that all over again until you don't have much left, and then you are done
I am now at a point where after every restart, I have only about minus 100 entries left. There are still over 224,000..
03/19/2023 04:14 Apourtartt#9
It is fine, try to find one that has not that much offsets (3 or less for example) and use this one
03/19/2023 21:24 Florian.K#10
Okay, just so I understand correctly, the item I selected in the image is the static pointer (3rd row)? This accesses mov eax, which would then be an offset? Then there's another offset at the bottom, the address 6FF35E, where HP, Mana, and some other values are stored. Is that right? And now I need to use the memory pattern to find the pointer?

Picture


Edit: I did it and it was easier than expected, thank you very much.
Edit2: Is there any way to show the exact amount of XP? I can only see 9% XP for something like 9.23%.
03/20/2023 12:59 romdrak#11
The experience is not stored as %, at least not in the non-gui related structures, check the packets that contain xp and look in memory for those values.