I doesn’t contain very little information anymore… I think~grytolle
** Is a tile 2^16^ or 2^21^ microtwips?
** Are integers signed or unsigned?
** What are the shield values?
1. Both ;p I am not sure exactly how it works, but for reading positions both those shoudl work, however neobeo prefer the later for some reason:
$floor($calc($jj2readp(5a4eee $mypn)*32))
$floor($calc($jj2readp(5a4eec $mypn)/2^21))
I still don’t get it. A tile cannot be both 2^16^ and 2^21^ microtwips in size at the same time, unless there’s two different sorts of microtwip. ~BoggyB
Oh nvm, it’s 2^21. A tile is 32 pixels though, I think. ~anonymous
My mistake. 1 pixel = 2^16^ microtwips, a unit I invented myself :(. If you are using TSearch or something else, it would be the same as reading the higher word (last 2 bytes). However, that is the way Jazz2 reads it so it would be better to just stick with that. ~Neobeo
2. I suppose integers are signed, because they can have a negative value (see the airboard address for example). ~Fl@$h aka BlewMeUp
Most values in JJ2 are signed 32-bit values. This I concluded, because the gameloop uses mostly JG/JL/JGE/JLE ASM instructions. There are a few JA/JB/JAE/JBE instructions though, so there is probably a minority of variables that use unsigned integers. ~Neobeo
3. same as when using jjshield:
0 none
1 fire
2 bubble
3 electric something (green one)
4 laser
Since the article is written with beginners as the target audience, it’s probably not right to assume they understand how the the weapons would be stored in memory. Also, it makes a quicker reference to just look at the weapon #x address then the weapon #1 address and then add to it. ~Neobeo
I’m not sure if the article is perfectly accurate. The lists of weapons considers Pepper Spray as weapon 8, while technically it’s the OEM Fireball which is the weapon 8. It’s still in the game (you can put it in crates) and it’s able to destroy gun8 destruct scenery. Maybe someone should look for the memory values of Fireball and add them here? ~Cooba
I am 100% sure the weapons and powerups adresses are correct :p
I’d like to see that weapon though :O
For the sake of clarity, please stop using microtwips. The pixel values are stored as 2 bytes, either as shorts or unsigned shorts, so with the right offset you can get the pixel values directly. No bit shifting, multiplying, or dividing necessary. In fact I believe you can get some incorrect values by attempting to interpret those memory locations as 4-byte long values. grytolle seemed to revert my change related to this. It’s possible the addresses I had were off by 2 bytes, so someone might want to check it before setting it back correctly. ~Monolith
To clarify, it is possible (read: easier) to read the top 2 bytes, and is also the way I used to do it. But in the ASM code, JJ2 reads it as a 4-byte value, the way I implement it now. This of course, makes conversion to pixel slightly more complicated, but it is easier to disassemble the code if you understand that JJ2 reads it as a 4-byte value this way, rather than as 32 pixels per tile. ~Neobeo
And for the sake of uhm.. something. Here is the asm for the for the actual warp function:
MOV DWORD PTR SS:[EBP+5A4EEC],EAX
MOV DWORD PTR SS:[EBP+5A4EF0],ECX
~Grytolle
Just thought I’d mention that I just added info for weapons 11,12, and 13, from the top of my head. I know that these worked when I tried them a year ago, but I cannot remember what I got when I tried weapon 10, or if I got the laser to work. Just fill your ammo slot for one of the weapons, change “current weapon selected” to the correct value (B,C or D in hex), and start firing! Great fun!
`n0 (yes, I cannot be bothered to log in)
I just added 2 addresses to the [1.24 adresses per player] section, and a description of what they contain (5C8550 and 5C8A7C).
-They are byte types, 0-255. Feel free to change the byte type i wrote to anything that fits the naming conventions for the article.
-If I made a mistake, or the information is wrong/not allowed, feel free to remove/edit it, but notify me of whats wrong please. (just comment here or somth.)
I hope you find a use for them, ~wKtK
Jazz2Online © 1999-INFINITY (Site Credits). We have a Privacy Policy. Jazz Jackrabbit, Jazz Jackrabbit 2, Jazz Jackrabbit Advance and all related trademarks and media are ™ and © Epic Games. Lori Jackrabbit is © Dean Dodrill. J2O development powered by Loops of Fury and Chemical Beats.
Eat your lima beans, Johnny.