It loads fine for me in Chrome, Firefox and IE. I know there's no problem with the function itself since I've used it before, so what's the issue?
... already has the values in the code but doesnt explain how they got it.
You can start from 0 and run all the way up to whatever the OS lets you. In general, I'm unsure of how to define what the limits of the process' memory is, but I'd play around with the function and see what it gives you.
here is what i am actually asking for
i want to know how to get this type of value
0x########
That's what I'm trying to point you to, and I would appreciate it if you could avoid having an ill-formed tone. I could have skipped this topic entirely and left you alone.
When you say "values from PC games" I'm assuming you mean accessing the values at specific points in memory. In that case, the function does exactly what you need and can provide values that can be translated to hexadecimal. I'd attempt working with this myself if Visual Studio wasn't currently under the process of reinstalling, but in the meantime we can at least make sure we're on the same page in terms of your question.
In which case, I apologize for misinterpreting you. I'll take a step back, then: What do you mean by
the "0x#######" value
? Are you referring to the memory location or the value itself? The title of the topic asks for the value, but the hexadecimal indicates that you're asking for a memory location.
The function fills a MEMORY_BASIC_INFORMATION object for you, after which I'd use ReadProcessMemory from the starting location to the extents of the process memory and search for the value you want. You're going to have to do a trial-and-error method to narrow down the results.
there isnt, the dynamic is the variable that control then ammo, but i need to find the static because the dynamic address changes if you shut tdown the game, therefore the address i have would be worthless, i need the static address because the static adress never changes.