Donkey Kong Forum

Related Games => Donkey Kong Junior => Topic started by: Sock Master on September 27, 2016, 05:52:51 pm

Title: "Fixing" DKjr
Post by: Sock Master on September 27, 2016, 05:52:51 pm
I'm near the stage where I can finally start coding for Donkey Kong Junior "Remix".

Before I start that, I figured it would be a good learning exercise (and a good idea in general) to go through DKjr and fix some of it's issues.   I have some ideas, but it'd be good to have some feedback.   Maybe we could use this thread to bounce some ideas for things to fix, maybe include occasional binaries for testing and feedback.

First, the control lag!  This is an obvious issue.  When Jr is climbing vines and moves left/right, then stop... if you try moving up or down, there will be some random amount of lag (up to 15 frames!) before the first up or down motion will even begin.   That's the easiest & worst case example to trigger, but it seems to affect just about any movement following a different movement.

I've started tackling that.   There is a timer to sequence movements, and when you're holding the joystick in a direction the timer decrements until it hits zero and then the next step of motion is allowed.  The solution?  Allow the timer to decrement to zero even if you're not pushing the joystick.   This alone is a huge reduction in the game's frustration.   This doesn't totally fix a 2nd issue of climbing one way then suddenly wanting to climb a different direction - it still has to count out that timer before you can switch directions..  later maybe I'll make two timers, one for vertical and one for horizontal motion - that way they can't interfere with each other.

2nd, the springboard!   It's definitely broken.  This took a bit more digging to unravel, but it seems to boil down to the jump trigger being a momentary input.  The code seems to check for a jump press 7 times when you land on the springboard, but it seems to be every other frame - if you happen to press the button during one of the frames where it *doesn't* check the button, it'll totally miss it.   For this, I added a second button-input variable that increases the momentary jump signal to 2 frames long instead of 1 frame.   That way a button press will always register.  100% success, no button mashing necessary, just press at the right time.

I know the scoring for jumping over multiple enemies is illogical too.  Not sure what the preferred scoring rates would be.   Something I'll be looking into later.

If anyone can chime in with other things that ought to be fixed (like camping at Mario's hideout), let me know.

Title: Re: "Fixing" DKjr
Post by: homerwannabee on September 27, 2016, 06:45:24 pm
Camping can be ended by using the bird stage timer on the hideout stage.  Or you could make the hideout stage timer 4000 instead of 8000.
Title: Re: "Fixing" DKjr
Post by: WCopeland on September 27, 2016, 07:12:37 pm
With the bugs fixed, DKJr has the potential for improvement, but there are some design concerns.

The first priority imho is that a "DKJr Remix" should not pivot to be more like Donkey Kong. DKJr is its own separate entity, and the things that make DKJr fun should not necessarily be the same things that make DK fun. With that in mind, some core principles still apply:

1.] Burning the clock out for points is boring no matter what game it is (think leeching Kong's leg on the rivet stage, or leeching off the spring on L=02 and L=03). There are some examples in DKJr as well, such as point pressing on the jungle/vine board and point pressing in the hideout. I don't agree that the timer should be limited. I think there should be more randomness thrown into these leeching elements to make the risk+reward factor much higher, similar to DK barrel board grouping. DKJr lacks this kind of depth, and adding this kind of player choice is what it desperately needs. DKJr has a reputation for being "pattern-based", and while some of that is good, other parts are not so good.

2.] With the exception of bonus stages, there should never ever be an instance of a DK Remix "crack corner" similar to the rivet board (especially on 1-2). This is too random to be taken seriously in competition, even more random than the standard DK 1-2. If you're shooting for a great score and the fireballs don't cooperate perfectly, it's an insta-reset over the course of multiple screens. If this were to be on a bonus stage, I would strongly recommend "capping out" the bonus stage. For example: you have a bucket of 8000 points to fill, if you fill them in a crack corner scenario more power to you.

3.] There may be some differing opinions on this, but blank level labels are jarring. Having a L=A, L=B, and L=C is really cool and part of the JR charm that should definitely remain, but from a spectator perspective seeing nothing for the level indicator makes a game more difficult to follow.

4.] The point spread in DKJr needs to have a serious evaluation if we're talking about design. In DK, you have a tight but elegant point spread representing every rung of the ladder, meaning a 850k kill screen, 900k clean-up phase, 1.02m, 1.07m, 1.1m, 1.13m, 1.15m, 1.2m+. These are zones that gameplay will fall into when playing to a certain formula if that formula is perfectly executed, no matter what happens. DKJr has some zones of its own, but they're much more erratic and there are fewer of them. There are fewer rungs on the ladder because the skill ceiling is not as high as DK, and that's a serious problem.

That's really all I can think of. The most glaring issue with DKJr is most of the point pressing is boring as fuck. There is very little randomness to it... it's just tedium. It's easy to learn. It's easy to master. With DK, grouping can take literally months and months to learn because of all the weird edge cases you'll find -- all of which are survivable... that is very important. It definitely wasn't designed that way, it's just a beautiful accident. With the exception of screens that are more cerebral (the chain board), the skill ceiling for the game is much lower than DK.
Title: Re: "Fixing" DKjr
Post by: Sock Master on September 28, 2016, 09:00:08 am
The first priority imho is that a "DKJr Remix" should not pivot to be more like Donkey Kong. DKJr is its own separate entity, and the things that make DKJr fun should not necessarily be the same things that make DK fun
...

...The most glaring issue with DKJr is most of the point pressing is boring as fuck. There is very little randomness to it...

DKjr Remix is going to be different from DK.  I still haven't worked out exactly how it's going to go, but the idea is that it's still going to be very much DKjr, but remixed - taking it's elements and making something new out of them.

There are some unused sprite graphics that might come into play and there is a bit of story to expand upon.  I could make new stages that could take place before, between or after the existing four stages, or think up of new variations using the original design elements.

What I really want to do is make the game fun.  So it's important to fix the frustrating and boring elements in the original game.
Title: Re: "Fixing" DKjr
Post by: homerwannabee on September 28, 2016, 10:57:00 am
I don't know if you know about this, but Colecovision had a real secret DK Jr level.  It would be cool to see that turned into a level for the arcade version.
Having said that, I understand that it might not be possible to do, and you might have a different vision in mind.
Title: Re: "Fixing" DKjr
Post by: aarontruitt on September 28, 2016, 02:17:26 pm
That Colecovision DK Jr pie factory level is really cool and I bet would be a really neat addition to DK Jr Remix! would also be cool to mix up the vine levels like you did with the barrel boards on DK Remix - having the fruit in different spots, different length vines, etc.
Title: Re: "Fixing" DKjr
Post by: krehztim on September 28, 2016, 05:33:50 pm

...The most glaring issue with DKJr is most of the point pressing is boring as fuck. There is very little randomness to it...

Couldn't agree more. Some of this could be alleviated by letting the snapjaws have access to both of the top platforms on the vine levels, so they don't turn around at the height differential (step).  That would at least make it a little harder.  But that doesn't help the huge point pressing in Mario's Hideout. Maybe the sparks have variable speeds, that might help the point pressing at the top, as in a constant speed for an individual spark, but all sparks having a different, random speed. 
Title: Re: "Fixing" DKjr
Post by: up2ng on September 28, 2016, 07:23:52 pm
DKJR has a lot of flaws.  But for me, the one single issue that prevents me from playing the game regularly is that the springboard is broken.  That is just so totally unacceptable to me that I feel that the game just shouldn't be played.  It's great that you've recognized that issue as being of the very highest priority to fix.

I started typing up some ideas for fixing the leeching problems on the hideout but that screen is REALLY leechable -- it would be hard to fix this without making some pretty big changes.
Title: Re: "Fixing" DKjr
Post by: homerwannabee on September 28, 2016, 08:50:23 pm
I thought of an idea.  Make a second fast yellow spark that is parallel with the original one.  That way you would need to kill the second spark with the top Apple.  Not an easy feat.  It would drastically cut down on point pressing.
Title: Re: "Fixing" DKjr
Post by: Sock Master on September 28, 2016, 09:33:44 pm
The control lag and springboard fixes alone pretty much eliminate most of the gameplay frustration.   It doesn't make the game more fun, nor do anything about the leeching.

I don't know if you know about this, but Colecovision had a real secret DK Jr level.  It would be cool to see that turned into a level for the arcade version.

We're going to be pretty much stuck with using the sprites & background tiles that already exist.  There are a few unused sprites that might be interesting, but there won't be much potential for creating new graphics beyond maybe combining existing sprites into something new.   Funny enough, the pie sprite from DK survives so it's possible to use, although it's available color choices are limited.

Some of this could be alleviated by letting the snapjaws have access to both of the top platforms on the vine levels, so they don't turn around at the height differential (step).  That would at least make it a little harder.  But that doesn't help the huge point pressing in Mario's Hideout. Maybe the sparks have variable speeds, that might help the point pressing at the top, as in a constant speed for an individual spark, but all sparks having a different, random speed.

I'm not sure how well animating a snapjaw going up a step would look, but allowing the red snapjaws to step down to the lower platform like the blue ones might be possible.

I think the main problem with that stage is that once Jr reaches a certain height, the blue snapjaws switch to a different logic which makes them always go all the way across the top platforms - and therefore become reliable leeches.   Maybe just disabling that to allow blue snapjaws to go down vines early, would reduce leech potential.

Mario's hideout is a whole other kettle of fish, but it also has logic switch for blue sparks once Jr reaches a certain height - main issue is that a blue spark that counts as 100 on the timer can now multiply into several sparks and give more points than the bonus timer decrements.  Also those perpetually circling red sparks, just jump over them over and over...   There's no 1:1 relation between score-able objects and bonus timer.

Maybe allow red sparks to move from one platform to another once Jr reaches the 3rd platform?  Maybe give the blue sparks a more random path or random direction?  Maybe simply have the bonus timer tick down once each time a blue spark multiplies into two?

I started typing up some ideas for fixing the leeching problems on the hideout but that screen is REALLY leechable -- it would be hard to fix this without making some pretty big changes.

That's one concern I have right now.  I don't want to mess with the original stages/logic/rules too much - if some minor changes can fix issues, that'd be best.   The control lag and broken springboard fixes were easy to rationalize because they won't change the game logic itself, just magically make the game less frustrating - the average player probably wouldn't even notice anything was changed (until they went back and played the original game anyway.)
Title: Re: "Fixing" DKjr
Post by: serphintizer on September 29, 2016, 05:46:13 pm
DKJR has a lot of flaws.  But for me, the one single issue that prevents me from playing the game regularly is that the springboard is broken.  That is just so totally unacceptable to me that I feel that the game just shouldn't be played.

This type of defeatist think is so flat-out erroneous it's ridiculous.  The whole point of these ORIGINAL games is to "play them as they lie".  Some people have figured out ways to overcome these "flaws"/"issues", as you put it, and have put up monster scores.  Maybe you need to practice more. :)     
Title: Re: "Fixing" DKjr
Post by: marinomitch13 on September 29, 2016, 08:58:20 pm
Didn't we do the math once and the chances of getting the jump with a decent double-flap was like 80-90%?
Title: Re: "Fixing" DKjr
Post by: JCHarrist on September 30, 2016, 05:28:41 pm
Didn't we do the math once and the chances of getting the jump with a decent double-flap was like 80-90%?

Yes, the springboard has been discussed before. ;)

https://donkeykongforum.net/index.php?topic=495 (https://donkeykongforum.net/index.php?topic=495)
Title: Re: "Fixing" DKjr
Post by: marinomitch13 on October 01, 2016, 03:36:22 am
I just re-read that thread and stumbled upon this poll again.

https://donkeykongforum.net/index.php?topic=515.0 (https://donkeykongforum.net/index.php?topic=515.0)

Lol, I totally forgot about it!
Title: Re: "Fixing" DKjr
Post by: up2ng on October 02, 2016, 04:24:18 pm
This type of defeatist think is so flat-out erroneous it's ridiculous.  The whole point of these ORIGINAL games is to "play them as they lie".  Some people have figured out ways to overcome these "flaws"/"issues", as you put it, and have put up monster scores.  Maybe you need to practice more. :)   

This is false.
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 02, 2016, 05:06:40 pm
Here's a first pass at DKjr fixes.

I won't provide the full ROMs, just the revised files.   In order to avoid changing existing DKjr MAME files, this version of DKjr will actually run under MAME's "dkongjre" emulation.   This way the normal "dkongjr" ROMs remain intact and you can easily switch back and forth between both this and normal DKjr.

What you need to do:
-find the dkongjre romset somewhere else.
-create a folder called "dkongjre" in your MAME roms directory.
-unzip the dkongjre files and copy them into the "dkongjre" folder.
-unzip 'dkongjr fix 1' and copy those files over the files in your "dkongjre" folder.
-play dkongjre in MAME.

What's changed?
-No more lag when changing directions on vines.
-The springboard super jump is now reliable.
-The direction you bounce off the springboard is now based on jump direction, not the direction you were facing!
-When blue sparks split into two in Mario's Hideout, it takes 100 off the timer (to dissuade leeching)
-Blue snapjaws can now go down vines when you are on the top platform (to dissuade leeching)
-The level indicator is now 2 digits instead of 1.

I'm not super happy with the anti-leeching modifications, so opinions and ideas are welcome.

Note:
-The game is considerably easier with the control lag and springboard fixes.
-Scores will be considerably lower because of the anti-leeching modification.
Title: Re: "Fixing" DKjr
Post by: serphintizer on October 02, 2016, 05:29:16 pm
This is false.

No chance.
Title: Re: "Fixing" DKjr
Post by: WCopeland on October 02, 2016, 05:58:42 pm
Let's try to keep this thread constructive out of respect for the service John is providing. This is not a thread about DKJr, it's about a revision of DKJr. As a community we should work to see that the vision of making the game as fun as it can be is executed.

I'll try to find some free time either tonight or tomorrow to test the ROM. I haven't seen the changes, but through reading the text it sounds like they could remove player choice? Leeching isn't necessarily a bad thing (think barrel grouping in DK), it's boring leeching that's a problem.
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 02, 2016, 09:33:33 pm
The current modifications make leeching more unlikely or more expensive to do, so it doesn't do anything to make the game more fun or more rewarding to play skillfully yet.

I still have a long way to go before I can understand the code inside and out.  It's all pretty much still uncommented disassembly so every change or modification means poring through code to even find where it'd be applied.   I'll slowly learn it like I did DK, but for now it means I can't magically add sweeping changes at the drop of a hat.

That said, DKjr is also very different in it's play mechanics and it seems difficult to come up ideas to make skillful play more rewarding and entertaining.  On vines you can only drop fruit for points.  On platforms you can sit around to jump some baddies over and over.   Many of the released baddies go by without scoring potential, except in Mario's Hideout where the blue sparks could multiply into 4 and skew the timer/reward ratio.

So I'm still not sure how it might go, but it'd be nice to find some subtle changes to balance scoring, make the game more fun to play skillfully and more entertaining to watch being played
Title: Re: "Fixing" DKjr
Post by: DonkeyKongGenius on October 02, 2016, 11:49:00 pm
I am glad this discussion is taking place. I will say that while I understand Dean's frustration over the springboard, I find is frustrating as well since I can't get it as consistent as MarkyD, I find that it required more skill to do more consistently. I can't press a button as fast as others and that is a limitation that I would be forced to overcome if I wanted to increase the chances of a faster springboard. It also requires you to memorize more patterns of birds because now you have to keep track of how many jumps you fail and what patterns are possible on each approach. In my opinion, while I hate failing the springboard, is that it is one of those elements that incorporates the skill for greater memorization and rapid button pushing. Removing that dynamic will make the board much easier. One of the reasons that I stopped grinding on Junior is that MarkyD had a greater success rate on the springboard and therefore was able to complete the board more quickly. It had to do with his skill of timing inputs and rapidly pressing a button that helped to push the skill ceiling a little higher.

And if you were to fix the springboard as it seems you already had then maybe throw in more variations on the birds to force players to have to react quickly instead of finishing the board in the exact same way every single time. That is to have random birds that respond to inputs so that they are not the same every time. You are familiar with the fact that some birds are fixed and others can come out at a different height depending on right and left inputs? At least a failed super jump or two on a single board provided this variety and was one of the reasons that I had to spend hours grinding out practice so that I was ready for every contingency. IF you "fix" the springboard it will lower the skill ceiling since it will no longer require well timed inputs and rapid button pushing. Therefore you will want to throw in that randomness on the birds to incorporate a more reactionary situation that requires more skill than just doing the exact same pattern every single time, which is what you get if you can get the first jump on every springboard.

While I am not arguing whether the springboard is broken or not, but taking it as it is, has it forced players to improve a gaming skill in order to increase the chances of faster game play.

As for control lag... DK Jr is DK Jr, I always assumed that the monkey was a little heavy and needed a little extra time and momentum to move. LOL :P I got so used to how the game played that I never perceived "control lag". I mean, he is a monkey on vines, he doesn't have super strength to pivot on a dime and cut corners. He is a slow monkey. So it always seemed normal to me. And I always thought that was one of his particularities that made him special and perhaps more realistic?
Title: Re: "Fixing" DKjr
Post by: DonkeyKongGenius on October 03, 2016, 12:03:32 am
Here was my analysis of the springboard bird patterns and which ones can be influenced: https://donkeykongforum.net/index.php?topic=968.0 (https://donkeykongforum.net/index.php?topic=968.0)
Title: Re: "Fixing" DKjr
Post by: xelnia on October 03, 2016, 03:12:33 am
Here's a first pass at DKjr fixes.

I'm not that good at DKJR, so I'll let the better players judge the fixes, but I think I encountered a bug. I wasn't recording but I think I was able to reproduce it once.

Anyway, I was on the very first chain stage and I somehow got stuck between chains. I was pushing a key up (the first one on the left), I had to move over a chain so JR was only on one chain (as opposed to being spread apart). I tried to switch chains, and JR got sort of stuck between the chains. I couldn't move and just sat there until I got hit by a bird. It wasn't a controller issue because I had enough time to check before I died. It was like JR froze during an animation where he spreads his arms out. It basically looked like this:

(http://i.imgur.com/x3vnRVF.png)

I tried to do it again and I was able to reproduce it, and get out of it by tapping the directional instead of just holding.

Title: Re: "Fixing" DKjr
Post by: Jonesy on October 03, 2016, 03:59:24 am
I always thought the springboard was just a timing issue on my part although I seem to be fairly consistent with this nowadays using TnF style skills when the spring is compressed.

The lag issue is a real killer though, always find it's at its worst at the top of the springboard stage crossing the vines. When you pull down the guy just sits there with a huge delay.  FailFish

Very interested to see where this project goes as I personally think the game is great and has the potential to be brilliant.

Title: Re: "Fixing" DKjr
Post by: CaptainJivePants on October 03, 2016, 08:46:46 am
I don't know if you know about this, but Colecovision had a real secret DK Jr level.  It would be cool to see that turned into a level for the arcade version.
Having said that, I understand that it might not be possible to do, and you might have a different vision in mind.
https://m.youtube.com/watch?v=KrHGZmvCZE8 (https://m.youtube.com/watch?v=KrHGZmvCZE8)


That's really cool. Thanks for sharing. I love the idea of Mario actually being a combatant/active enemy instead of just standing by my Monkey Dad.
Title: Re: "Fixing" DKjr
Post by: TheSunshineFund on October 03, 2016, 09:18:41 am

And if you were to fix the springboard as it seems you already had then maybe throw in more variations on the birds to force players to have to react quickly instead of finishing the board in the exact same way every single time. That is to have random birds that respond to inputs so that they are not the same every time.

I like this idea.

Oh and thanks John!  You are indeed the man.
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 03, 2016, 05:53:27 pm
Jeremy, I was able to reproduce the getting stuck and have fixed it.  It'll be in the next update.   This was actually caused by a mixup in the disassembly rather than coding.

DonkeyKongGenius, More variation/less patterned behavior in the birds is a good idea.  I'll have to dig some through the code to figure that out, but hopefully I can come up with something for the next update.
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 04, 2016, 09:27:30 am
Update take 2.  Just copy the files into the dkongjre folder.

I fixed a couple of errors in my disassembly, this fixes the getting stuck on vines bug.

I've tweaked the anti-camping logic a bit.  I've added a bit of randomization to the timing of the multiplying blue sparks and also to the bird patterns.    Fairly subtle stuff that a casual player probably wouldn't even notice, but it reduces pattern play.

You guys are not going to believe this, though.   I spent a lot of time yesterday trying to track down where the joystick inputs influence the bird patterns... ...and there is no deliberate code that does this!   I finally figured it out and found where it happens, though.

It's totally accidental and caused by a typo in the original code!   The birds were intended to have fixed patterns.

Code: [Select]
;bird flight pattern logic is here
l4cb9:  ld      a,(ix+$05)
        cp      $58
        jr      z,l4cec
l4cc0:  cp      $60
        ld      c,$02 ;load 2 position in C
        jr      z,l4cdd
        cp      $68
        ld      c,$05 ;load 5 position in C
        jr      z,l4cdd
        cp      $70
        ld      c,$03 ;load 3 position in C
        jr      z,l4cdd
l4cd2:  ld      a,(ix+$05)
        cp      $78
        jp      z,l4c1a
        jp      l2e96

l4cdd:  ld      a,c
        cp      b
        jp      z,l4c1a
        ld      a,b
        sub     $05
        cp      c
        jp      z,l4c1a
        jp      l2e96

l4cec:  ld      a,($6227)
        cp      $03
        jr      nz,l4cf8
        ld      a,(ix+$05)
        jr      l4cc0

l4cf8:  ld      a,$04 ;load 4 position in... A?  Oops.
        jr      l4cdd ;A actually gets clobbered right after jumping to l4cdd, so ld a,$04 does *nothing*

At the point where $04 is accidentally loaded into A instead of C, C happens to contain the joystick/button inputs (from about a dozen subroutines back.  It's only pure luck that some other in-between subroutine didn't clobber the contents of C.)   So instead of passing 2,3,4 or 5 to the bird flight pattern, it passes 2,3,joystick,5 instead, which affects the flight patterns.
Title: Re: "Fixing" DKjr
Post by: TheSunshineFund on October 05, 2016, 06:01:21 am
Wow that is interesting that it was intended to be patterned.  I like it better random I must say. 
Title: Re: "Fixing" DKjr
Post by: homerwannabee on October 05, 2016, 08:15:11 am
Wow, that's is cool. Very awesome discovery!
Title: Re: "Fixing" DKjr
Post by: WCopeland on October 05, 2016, 08:37:54 am
Very interesting -- great find
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 05, 2016, 07:35:10 pm
Was it known that there is a bug in DKjr that allows you to climb into the space inside the platforms in Mario's Hideout?   (and also allow you to squeeze down through the gap between the vines on the left and the 2nd platform?)

Weird.  I guess that's something else that ought to be fixed.

To pass into a platform, all you have to do is get off the left side vine and onto a platform, get back on the vine (but keep Jr on the right side of that vine), descend a bit, then go back onto the platform.. he'll go onto the platform lower than he's supposed to be able to.
Title: Re: "Fixing" DKjr
Post by: xelnia on October 05, 2016, 08:11:29 pm
Was it known that there is a bug in DKjr that allows you to climb into the space inside the platforms in Mario's Hideout?   (and also allow you to squeeze down through the gap between the vines on the left and the 2nd platform?)

Weird.  I guess that's something else that ought to be fixed.

To pass into a platform, all you have to do is get off the left side vine and onto a platform, get back on the vine (but keep Jr on the right side of that vine), descend a bit, then go back onto the platform.. he'll go onto the platform lower than he's supposed to be able to.

JR pls....  FailFish

Here's something else to look out for...walking through a spark. Not sure if it's a problem with MAME emulation or an actual bug in the code that would happen on arcade as well. Money shot is at about 0:25.

! No longer available (http://www.youtube.com/watch?v=7lCqnL7aK7M#)
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 05, 2016, 10:56:44 pm
JR pls....  FailFish

Here's something else to look out for...walking through a spark. Not sure if it's a problem with MAME emulation or an actual bug in the code that would happen on arcade as well. Money shot is at about 0:25..

Oh, wow.   I'm not even sure how to reproduce that.   I'll also try looking into the warp glitch eventually.

I've already found two sections of code that are potential game crashes, and the platform bug above can also cause a lockup if you merge into the little platform on the left - you get stuck inside forever, even past the timer hitting zero.
Title: Re: "Fixing" DKjr
Post by: Jonesy on October 06, 2016, 12:22:25 am
Wowzer!?

Interesting stuff, although Jr's code is coming across as a bit of a mess, pretty funny that a typo determined the final bird flight pattern.  FailFish  FailFish

Keep it going John, top job!

Jr remix FTW  Kreygasm
Title: Re: "Fixing" DKjr
Post by: Barra on October 06, 2016, 12:38:42 am
Interesting stuff, although Jr's code is coming across as a bit of a mess...

You sound surprised Kappa
Title: Re: "Fixing" DKjr
Post by: Jonesy on October 06, 2016, 08:22:30 am
Interesting stuff, although Jr's code is coming across as a bit of a mess...

You sound surprised Kappa

I'm surprised it's that bad TBH

Anyhow, John mentioned he tweaked the 'anti-camping' logic....I reckon you need yours tweaking also  Kappa
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 06, 2016, 01:26:08 pm
Here's update #3 to the ROM, just unzip and copy the files into the dkongjre folder.

This update cleans up some glitches with getting suck on vines, getting stuck inside or walking inside platforms.  Also fixes the last of the disassembly errors, so it seems to be assembling reliably now.   I think that about does it for obvious glitches.   This was good for getting a feel for the code.   I think that means I'll start some Remix related modifications soon.

Interesting stuff, although Jr's code is coming across as a bit of a mess...

You sound surprised Kappa

I'm surprised it's that bad TBH

Anyhow, John mentioned he tweaked the 'anti-camping' logic....I reckon you need yours tweaking also  Kappa

If anyone has an opinion on the anti-camping, let me know.  Randomizing the timing of the splitting blue sparks makes them more likely to form deadly barrel, I mean spark, combos.   (sparks are modified barrels.  snapjaws are modified fireballs/firefoxes.)

The get the impression that Donkey Kong was programmed by veteran programmers.   Donkey Kong Jr was most likely junior programmers.   I suspect they had a printout of the source code and the binaries, but not source code itself.  They must have approached the project as a ROM hack - adding patches over the DK ROM rather than assembling the game fresh.  There are a few address calculation mistakes (where code jumps to a bad location), abandoned code & data fragments, lots of jumps that go to other jumps, lots of bypass jumps to insert a bit of code before jumping back...   It's a bit of a nightmare to make sense of because little bits of code are spread out all over the place instead of in rational order.

Ah well, onwards...
Title: Re: "Fixing" DKjr
Post by: up2ng on October 15, 2016, 02:24:52 pm
This is false.

No chance.

Wrong again!  LOL  Thanks for playing!!
Title: Re: "Fixing" DKjr
Post by: serphintizer on October 15, 2016, 02:41:11 pm
Wrong again!  LOL  Thanks for playing!!

You mad bro? ROFL
Title: Re: "Fixing" DKjr
Post by: up2ng on October 15, 2016, 05:13:58 pm
Wrong again!  LOL  Thanks for playing!!

You mad bro? ROFL

Yup, that must be it.  People often laugh out loud when they are mad.  Good read.  Oh, wait . . .
Title: Re: "Fixing" DKjr
Post by: marinomitch13 on October 15, 2016, 07:55:00 pm
Honestly, I find the fact that Jumpman in DK will sometimes slide in the direction you are holding rather than turning around to be much more annoying than the DKJr super jump requiring mashing to get it consistently. At least in the case of the Super Jump you can always expect it and just get better at mashing.
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 15, 2016, 08:51:23 pm
Honestly, I find the fact that Jumpman in DK will sometimes slide in the direction you are holding rather than turning around to be much more annoying than the DKJr super jump requiring mashing to get it consistently. At least in the case of the Super Jump you can always expect it and just get better at mashing.

Jr. does exactly that too.  Twitch the joystick around a bit and you can make him moonwalk for a few frames.  It's not anything specifically wrong internally - push left and both games go left, push right and they go right.. it's only the sprite frame animation that doesn't update until X frames of walking, so you can walk a couple of pixels before the next frame of animation is triggered.  That's also why you can sometimes jump to the left while facing the right.

Jr. has a related issue if you descend off a vine, it can still show a climbing sprite even though the game has technically switched to walking mode.  This one bothers me.   Maybe if I fix one, I'll fix both visual issues.
Title: Re: "Fixing" DKjr
Post by: Sock Master on October 21, 2016, 04:52:07 pm
Here's update #4 to fixing DKjr, just unzip and copy these files into the dkongjre folder in the roms directory.

This update is a lot more extensive than before.  The more I went through the code, the more apparent the broken things became.   So I decided that it's OK to make wider changes... whatever it's going to take to fix.

Sometimes there was code where I can see the intended functionality, even if it doesn't actually *work*.  Stuff like the level 1 vines screen supposed to have 3 red snapjaws, level 2 is supposed to have 4 red snapjaws, level 3+ have 5...  Well, 4 never happens because the routine that does the check happens to trash the value of the registers it's testing...  Anyway, so in cases like that, I tried to implement their intention.

There's some evidence that they intended blue snapjaws and blue sparks to have more function in their AI - the blue snapjaws check for the bottoms of vines, for instance.. so I think they were intended to do more than just fly straight down into the water.   But whatever, that's too much a change for now - but Jr Remix will expand the AI functions.

There's a lot of little details fixed, like how platform & vine detection and handling is done..  Generally, things most people won't even notice.. unless maybe you go back to the normal DKjr and then you'll notice something isn't going quite right.

I also tried to balance the difficulty.   I fixed some of the internal difficulty functionality that was hacked up and made it advance more gracefully and affect things in the game in a reasonable way.   Hopefully that makes the difficulty increase smoothly between levels 1 and 5.

I *think* I got things pretty good now.   A casual player probably has a chance at surviving past level 3.

Anyway, give it a go and let me know if the game is more fair and less frustrating.   This will be the code that is the base for DKjr Remix.

Title: Re: "Fixing" DKjr
Post by: SuperNinbendo on April 09, 2024, 11:06:54 pm
This is absolutely fascinating!

I'm having so much fun revisiting these old topics!
Title: Re: "Fixing" DKjr
Post by: Sock Master on April 11, 2024, 08:57:25 am
Here's something else to look out for...walking through a spark. Not sure if it's a problem with MAME emulation or an actual bug in the code that would happen on arcade as well. Money shot is at about 0:25.

Youtube link - Walking Through a Blue Spark (https://www.youtube.com/watch?v=7lCqnL7aK7M)

Wow that was a while ago.

Well, I actually did later find the code responsible for this bug later when I was in development of DK Junior Remix so here's the explanation of what's going on!

There's a bug in DK Junior's code where there are 10 slots made available for the blue and yellow sparks in Mario's Hideout...
but the initialization code only sets the hitbox size for the first 8 slots.   Everything runs fine as long as there are never more than 8 sparks on the screen but as soon as a 9th or 10th spark gets assigned, any sparks in those two slots don't have any defined hitboxes.
You can still jump over them for points or smash them with fruit (if I recall) but you can walk right through them because they have a 0x0 hitbox.
Title: Re: "Fixing" DKjr
Post by: Dallas Taylor on April 11, 2024, 05:04:00 pm
"Sometimes there was code where I can see the intended functionality, even if it doesn't actually *work*.  Stuff like the level 1 vines screen supposed to have 3 red snapjaws, level 2 is supposed to have 4 red snapjaws, level 3+ have 5...  Well, 4 never happens because the routine that does the check happens to trash the value of the registers it's testing...  Anyway, so in cases like that, I tried to implement their intention."

This is so... I'm not sure what it is. I must have grown up in an alternate reality.

Forever, I have sworn that I played the game where after L3, there were two red snapjaws on the right side vines of the Jungles. Two snapjaws that covered the verticals and the small platform on the far right of the screen. I actually had a picture of the Jungle board, that I'd drawn in 5th grade, and I included both of the red snapjaws on the far right side. Found that picture just a few years ago. It triggered the "memory" of playing this version.

Obviously, this is crazy and not possible. That being said, sometimes, my failing memory and false memories that my crazy brain sometimes creates these days are entertaining and possibly genius beyond my capabilities  ;D ;D ;D