JazzJackrabbit Community Forums

JazzJackrabbit Community Forums (http://www.jazz2online.com/jcf/index.php)
-   General Jazz Jackrabbit Talk (http://www.jazz2online.com/jcf/forumdisplay.php?f=4)
-   -   JJ2 game bug fixing (http://www.jazz2online.com/jcf/showthread.php?t=14407)

UNKNOWNFILE Dec 24, 2005 10:03 AM

JJ2 game bug fixing
 
Removed

Bobby aka Dizzy Dec 24, 2005 11:49 AM

What happens if you replace the div instruction with a null instruction?

I've also thought (and tried unsuccessfully) to patch the respawn problem in jj2 by hacking the exe file, but my knowledge of x86 is limited.

Grytolle Dec 24, 2005 12:49 PM

Dizzy, wouldn't that make so that player 2 in splitscreen-duels would be without ammo? ;P

Bobby aka Dizzy Dec 24, 2005 02:18 PM

Not necessarily. I believe that the respawn bug becase a problem with one of the patches. Previously it was possible to keep picking up ammo even when you had 50 pieces already. This was changed and when making that change the respawn bug was not caught. A hack of the exe itself wouldn't necessarily work like the respawn.exe program which just constantly resets a couple of memory locations.

There are a handful of aways to fix the problem:

1. Reset memory locations every so often like respawn.exe.

2. When dealing with loose ammo, there should be a check on whether or not the player in question has 50 pieces of ammo already. However, changing the constant which is used in this comparison might make it possible to pick up more than 50 pieces. I haven't played with this idea but I'd like to when I get a chance.

3. Decrement the number of pieces of ammo a player has when he shoots that piece of ammo.

Violet CLM Dec 24, 2005 02:51 PM

I would like to take this moment to thank Unknownfile for being one of the few people in the community who is actively working to get something done. I don't know enough (read: anything) about ASM to know how effective his efforts will be, but he seems determined and I have high hopes for this project.

ThunderPX Dec 25, 2005 04:35 AM

You'll want to google StealthPatch to use the patch (it's what I use.)
I just got an idea- if we don't have the original comments, we could just play with the code a bit, see what happens, and add our own comments to make modding less hard. It's kind of redundant for every single person to research the same piece of code.

EDIT: I hope that if this gets done, everyone upgrades. Make sure that nobody with an earlier version would be able to get into a new server at all, because then they could still use the Laser Shield.

Grytolle Dec 25, 2005 05:42 AM

*tries what UF has done so far*

Super_Jarno Dec 25, 2005 06:14 AM

well we are trying to make an 1.25 version of jj2 so the bug must be fixed in there!

Grytolle Dec 25, 2005 06:16 AM

...You suck

Super_Jarno Dec 25, 2005 06:19 AM

Quote:

Originally Posted by Grytolle
...You suck

...i know

Grytolle Dec 25, 2005 06:29 AM

I was referring to Super_jarno, what youa re doing rox, UF :)
I am wondering why you didn't fix listserver-support though... :p It was not hard work to edit list.jazzjackrabbit.com to jazz.nimrod-online.com in a hexedit prog

Grytolle Dec 25, 2005 05:15 PM

Good job! But dude, you will run out of letters if you keep releasing at this speed... :D

Odin Dec 25, 2005 06:42 PM

Quote:

Originally Posted by UNKNOWNFILE
I did. It's built-in now.

Speaking of which, I've deglitchified the gem ring animation, but not entirely though. I also fixed the infamous laser shield crash bug.

Note: the laser shield is still obtainable, but use of it will not crash a server or so I have tested it so far. I tried it both with and without fastfire, but after 40 seconds of lasering, I'm proud to say the testing server (running in the newest version of the patch) did NOT crash.

I haven't figured out the spike ball errors yet, so sound is re-enabled in this new version. Avoid shooting the spike balls, this WILL crash the game.

Jazz Jackrabbit 2 - 1.25b "Rosetta JOL" IPS patch

Once more, you are awesome. While the "skilled" coders in the community are sitting on their butts, you're actually trying to do something. I commend you for that.

Cpp Dec 25, 2005 06:42 PM

Dude since this of your jj2 version has some side effects, you should make a dedicated server out of it - one that doesn't crash ;P

UNKNOWNFILE Dec 25, 2005 06:56 PM

Overlord: There are several known bugs with this, although the laser shield problem is out of the way for now.

-I can't seem to hack the game into ignoring long nicknames as the code isn't stored in the file -- in fact, it's stored in memory!
-Even though the gem ring problem is dealt with, there is still a bit of glitching in the game.

And a test server will be conducted as of this posting, and will be running on a fixed 1.25b with serverlists that are actually built in. Sorry for issues on earlier patches, they'll be corrected when 1.25c comes out. And in case you're wondering, 1.25c will be codenamed "Nebula". ;p

EDIT: The server went down with no laser problems whatsoever. The server was bombarded with laser requests from my good assistant Grytolle, and later I joined in on the laserfest. Needless to say, after its 10 minute* run, the server did not suffer anything but a couple of graphical glitches from the gemring animation processor. (I still need to fix that)

*This is a free guess. Do you actually think I keep track of uptime or something!?

This thread has been SIGGIFIED!

Grytolle Dec 25, 2005 07:37 PM

It sucked that I used 1.23 instead of 1.25b when we did it though, since my client crashed when UF began lasering. =P And the uptime was long enough. Now we can only hope all other filters are rendered useless, because right now I can't use them on my other computer, since WPE is a "trojan" ;(

n00b Dec 25, 2005 08:09 PM

Hey guys proffesional coders UF, 1.25 is nifty, but are there plans for making a TSF version of the patch?

(Sorry if there are and it has been mentioned, I lightly skimmed over the posts)

UNKNOWNFILE Dec 25, 2005 08:30 PM

JJ2 1.24 TSF is entirely different from 1.23, but I guess I could make one once this thing is finalised.

For now however, JJ2 v1.23 is needed to use this patch.

Monolith Dec 25, 2005 09:35 PM

From glancing over the problem it looks like you get a divide by zero error. Probably the simplest way of patching this without getting into the larger reasons of why ebx is 0 is to do this:
1. check if ebx is 0
2. if it is, set ebx to something safe like 1

Hopefully that doesn't have any more unintended side effects. If it does, you can try skipping over that code if ebx is 0.

Puffie40 Dec 25, 2005 11:52 PM

I commend you, UF. You are amoung the group of people who are slowly refining JJ2. With infamous bugs like this being fixed, it will be a great boon to the entire community!

Grytolle Dec 26, 2005 01:19 AM

(-) is a boon?

Stijn Dec 26, 2005 02:34 AM

So, uhm, talking about disassembled JJ2 code is allowed now here? Or did I miss something?

Not that I care, I think the work you're doing rocks. Would it also be possible to add new features (getting an extra live for 100 gems) this way?

White Rabbit Dec 26, 2005 02:42 AM

I don't understand anything here. :p UF, you don't have to explain to me how or why this works, but what exactly does it do to your JJ2? Is it a permanent code edit, or can you 'uninstall' it?

Grytolle Dec 26, 2005 02:45 AM

Why wouldn't it be allowed?
Wr, it's permanent, so back up your .exe

Cpp Dec 26, 2005 03:06 AM

Quote:

Originally Posted by Grytolle
It sucked that I used 1.23 instead of 1.25b when we did it though, since my client crashed when UF began lasering. =P And the uptime was long enough. Now we can only hope all other filters are rendered useless, because right now I can't use them on my other computer, since WPE is a "trojan" ;(

There's your problem! It's still possible to laser! IMO Laser should be completely removed which would prevent its use on the server 100%.

Violet CLM Dec 26, 2005 03:31 AM

Would that kill the laser shield 'SCE'? Sorry if this is a stupid question, this isn't my field.

Stijn Dec 26, 2005 03:40 AM

Quote:

Originally Posted by Grytolle
Why wouldn't it be allowed?

No idea, but admins used to close/delete anything related to jj2 code disassembly.

Cpp Dec 26, 2005 03:42 AM

Quote:

Originally Posted by Unknown Rabbit
Would that kill the laser shield 'SCE'? Sorry if this is a stupid question, this isn't my field.

If the code is set to block all incoming laser packets then it would not. The SCE laser is really useful and I don't think it should get removed. What should get removed is the ability for players to use the laser and I think that can be done by blocking the laser packets. Don't ask me how to do that in ASM...

Grytolle Dec 26, 2005 03:45 AM

However, lasercrashes seems to not be much of a problem anymore...

For those who can't wait for an UF-patch with fixed listservers:
1.25a and 1.25b-registry keys

Bug:
[img]http://www.freewebs.com/grytolle/jazz2stuff/wtfbug.PNG[/img]
And when I used jjfly in WR's server I crashed. When I joined it was singleplayer, then he used PC4 to switch to Treasure, meaning I was still able to cheat. Is this some kind of cheta protection you added, UF?

Edit: The jjfly crash seems to be just on that single occasion. =)

I also have graphical errors in Santranigus V, not as disturbing as in the screenshot, but on the other hand seemingly impossible to screenshot. I guess it's the same bug though =p

ThunderPX Dec 26, 2005 04:53 AM

Would it be possible to have a wad-type system eventually? I'll explain;
In some games you can load .wad files that contain some information that changes the game for that one running only. It could be used to, say, add new characters or modes. Of course, new characters and things is a long shot, but it could be useful for custom game modes.

By the way, would it be possible to add some sort of substitute animations to 1.23 and allow play with 1.24, so the animations when someone plays as Lori aren't screwed up?

UNKNOWNFILE Dec 26, 2005 08:05 AM

Quote:

Originally Posted by Grytolle
Bug:
And when I used jjfly in WR's server I crashed. When I joined it was singleplayer, then he used PC4 to switch to Treasure, meaning I was still able to cheat. Is this some kind of cheta protection you added, UF?

I doubt it, I guess it's some type of bug.

The image glitch is caused by the gemrings. I think this whole divide-by-zero error can be solved like this:

Code:

mov ebp, 01h
IMO, the divide is just dividing something by itself, which always returns 1. I'm not sure about this, but at least it's a guess.

Quote:

Originally Posted by Overlord
If the code is set to block all incoming laser packets then it would not.

The game is actually blocking the rendering of lasers, as that what causes the game to crash a server. The laser shield is still obtainable, but use of it won't crash a server.

And for the rest of you, this is being coded entirely in ASM. No source code is being used.

Bobby aka Dizzy Dec 26, 2005 09:48 AM

Quote:

IMO, the divide is just dividing something by itself, which always returns 1. I'm not sure about this, but at least it's a guess.
That's true except for zero which is a special case. 0/0 is not defined and reasons are not worth getting into in this thread.

UNKNOWNFILE Dec 26, 2005 01:08 PM

Jazz Jackrabbit 2 1.25c Nebula - now with working server lists

Gem rings are no longer an issue, so I'll work on respawn for v1.25d, code named "Nimrod". ;D

This will use your 1.25b regkeys, as I forgot to update the version number.

Newspaz Dec 26, 2005 01:46 PM

This is looking nice. But can't you just let it use the 1.21 registry keys?

UNKNOWNFILE Dec 26, 2005 01:55 PM

If I change the version in the main menu, the thing will need to use a new registry key, but I guess when the thing is final and stuff that it'll be able to work OK.

Cpp Dec 26, 2005 03:37 PM

Quote:

Originally Posted by UNKNOWNFILE
The game is actually blocking the rendering of lasers, as that what causes the game to crash a server. The laser shield is still obtainable, but use of it won't crash a server.

Ah! I understand. So basically the SCE lasers still work, but they are invisible? I wonder how this works in survivor. Did you get to conclude what causes the game to crash when using lasers? I always thought its when somebody gets roasted by a laser which would explain why the game never crashes in treasure hunt mode... or does it?

UNKNOWNFILE Dec 26, 2005 03:41 PM

CORRECT! YOU WIN A MILLION DOLLERZ!!!!!!!!1111111

Anyways, it appears what handles the gem ring actually handles rotation of several objects like the CTF direction pointers (the red and blue arrows). Because of patches done to this, JJ2 renders the arrows a bit wrong, but at least the entire screen isn't glitching.

And you can still get hit by lasers although they are invisible. Watch out, you never know what can happen... })

PAGECLAIM IN THE NAME OF 1.25

Grytolle Dec 26, 2005 04:46 PM

They didn't appear invisible to me... just not dangerous, except for instantkill.

Black Ninja Dec 26, 2005 05:19 PM

Holy crap.

Nice work so far. You > me.

EDIT: Are there any plans for increased resolutions? I can send over the work I have on resoltuions so far if needed (I have the addresses that control it and can resize it to anything *under* 640x480. If I resize it to anything higher, it works for a split-second and then crashes.)

UNKNOWNFILE Dec 26, 2005 06:39 PM

BN: Do you mean ingame or during the opening titles?


All times are GMT -8. The time now is 09:56 PM.

Powered by vBulletin® Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
JCF © 2001-Infinity Jazz2Online