Jump to content
IGNORED

2 button joystick ?


R0ger

Recommended Posts

19 hours ago, doug0909 said:

Just happened across this thread... So I guess for 2 button games, I can just use a Genesis controller to take advantage of these hacks, but for 3 button games, I can't use Genesis button 3 and would need a custom rewired stick? 

to use 3 buttons you have to use the modification that your friends made in the previous posts. remove the chip and make the necessary connections since the cable works.

 

8 hours ago, Bobo Cujo said:

And while I'm at it, here's a 3-button Star Trek version too, also with the above fix.

I can only tell you how impressive it is! ?

Link to comment
Share on other sites

Here's Spelunker - 2 Button version.

(Broderbund release with the animated intro, based on the .xex version from Homesoft's page)

 

Unlike many of my previous hacks, I purposely kept the keyboard controls intact this time.

 

Existing controls:

Button 1 (Fire Button): Jump

F : Launch Flare (to deal with birds)

D : Place dynamite (to blow up big "hills")

Space: Activate fan (to deal with ghosts)

 

Additional controls:

Button 2 + UP: Launch flare

Button 2 + DOWN: Place dynamite

Button 2 without UP or DOWN: Activate fan

All of the above will still work if the player is moving left or right.

 

Please try this out and let me know if I've introduced any bugs/crashes; it's hard to tell what's actually free memory...

 

(3 button version coming later - that one will have a dedicated fan button)

Spelunker - Joy2B - 2 Buttons.xex

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

...And I mistyped a byte in Spelunker, causing the button debouncing to not actually work - yay dropping dynamite and then activating the Phantom Blaster, thus being unable to move away from the dynamite. ?

 

Here's a fix.

 

Also, apparently it's a Phantom Blaster, not a fan.  Who knew...

@www.atarimania.com  That link above is for an Atari manual of the game - you may wish to contact the site author about adding it to Atarimania...

Spelunker - Joy2B - 2 Buttons - Rev 1.xex

  • Like 2
Link to comment
Share on other sites

15 hours ago, tane said:

@Bobo Cujo What about Blue Max?

Of all of the Atari games that do direction+button to fire a bomb or other secondary weapon, I actually think that Blue Max does one of the best jobs working it into its game design.

Forcing the player to drop in altitude to bomb prevents the player from spending practically the entire game at "strafing altitude" (the altitude where your guns can destroy minor gun targets) and thus making bombing targets way too easy.

 

With that said, moving diagonally and trying to hit planes without accidentally changing altitude is something that could be improved.

Someday, I'd like to do a 2-joystick mod of the game, where stick 2 controls altitude/bombing (with up/down rebound to moving straight up/down) and stick 1 controls x/y direction and firing.

I'd probably leave gravity permanently on to prevent the problem I mentioned above.

 

Ditto for Blue Max 2001, which probably needs a 2-joystick mod far more than the original Blue Max...

  • Like 1
Link to comment
Share on other sites

Here's a 3-button version of Spelunker, too.

 

Additional controls:

Button 2 + UP: Launch flare

Button 2 + DOWN: Place dynamite

Button 3: Activate fan Phantom Blaster

All of the above will still work if the player is moving left or right.

 

Again, the keyboard controls still work in this version.

Spelunker - Joy2B - 3 Buttons.xex

  • Like 1
Link to comment
Share on other sites

As for Hawkquest:

Given that there haven't been any reported issues with the last beta (yet), and given that I know that the new code isn't clobbering existing data, I'm going to go ahead and declare this the first proper release.

I'll happily update it if anyone finds any issues.

 

(note: If you got beta 1 earlier, it's the same file with no changes)

 

At some point in the future, I still need to play through the entire game with it, and to see if @playsoft's version might still be more optimal (in the Altirra profiler).

 

@ascrnet This and the above files (from Qix onward) are ready for upload to the Joy2B git/wiki ?

Hawkquest - Joy2B.car

  • Like 1
Link to comment
Share on other sites

Augh, it turns out that the Homesoft version of Spelunker (and by extension, the Joy2B version) crashes after reaching the exit in "The Ropes" (level 2).

Presumably, it's because it tries to load in the second half of the game map from disk, but the data isn't in the .xex...

 

@ascrnet I don't suppose you have a cartridge version of this one? ?

(I tried this one but I couldn't get it to actually boot in Altirra, either with 128K XEGS or 128K Switchable XEGS...)

Link to comment
Share on other sites

Not exactly what you asked for, but here's the atr version already patched: spelunkertest.atr

 

I took the liberty of adding autodetection of the third button. It should work just like the two-button version when only two buttons are available, but when a third button is detected the second button no longer triggers the fan.

 

The loader is obfuscated, so I put the button reading routine just after the high score table (which is only 24 bytes long but uses an entire plain-text sector), meaning that I only had to modify three obfuscated bytes to call the routine. Thanks to Avery for the Altirra debugger: this kind of patching wouldn't be possible without it.

 

I've only tried it on Altirra with an emulated three-button joystick so far, and my rusty skills couldn't get me past the Ropes to verify that the second load works. Please test :)

Link to comment
Share on other sites

16 hours ago, Bobo Cujo said:

I don't suppose you have a cartridge version of this one? ?

Spelunker.car

 

2 hours ago, Eyvind Bernhardsen said:

Not exactly what you asked for, but here's the atr version already patched: spelunkertest.atr

 

I took the liberty of adding autodetection of the third button. It should work just like the two-button version when only two buttons are available, but when a third button is detected the second button no longer triggers the fan.

 

The loader is obfuscated, so I put the button reading routine just after the high score table (which is only 24 bytes long but uses an entire plain-text sector), meaning that I only had to modify three obfuscated bytes to call the routine. Thanks to Avery for the Altirra debugger: this kind of patching wouldn't be possible without it.

 

I've only tried it on Altirra with an emulated three-button joystick so far, and my rusty skills couldn't get me past the Ropes to verify that the second load works. Please test :)

Thanks, but this is not a patched version because there are users who do not have how to emulate .car in the real atari. ?

I tried altirra and it works fine.?

1 hour ago, tane said:

There is the same .car that I am sharing, thanks for the help. ?

Link to comment
Share on other sites

3 hours ago, ascrnet said:

Spelunker.car 128.02 kB · 2 downloads

 

Thanks, but this is not a patched version because there are users who do not have how to emulate .car in the real atari. ?

I tried altirra and it works fine.?

There is the same .car that I am sharing, thanks for the help. ?

Thanks for the cartridge file link, @tane and @ascrnet!

 

 

6 hours ago, Eyvind Bernhardsen said:

Not exactly what you asked for, but here's the atr version already patched: spelunkertest.atr

 

I took the liberty of adding autodetection of the third button. It should work just like the two-button version when only two buttons are available, but when a third button is detected the second button no longer triggers the fan.

 

The loader is obfuscated, so I put the button reading routine just after the high score table (which is only 24 bytes long but uses an entire plain-text sector), meaning that I only had to modify three obfuscated bytes to call the routine. Thanks to Avery for the Altirra debugger: this kind of patching wouldn't be possible without it.

 

I've only tried it on Altirra with an emulated three-button joystick so far, and my rusty skills couldn't get me past the Ropes to verify that the second load works. Please test :)

@Eyvind Bernhardsen Good catch on the empty space after the high score table!

I patched your code into the .car file and tried this on a real NTSC Atari 800XL with a Sega Genesis controller (2 button), but unfortunately, the 2-button detection doesn't seem to work (I can't activate the fan with Button 2). ?

(This is true whether or not I include the initializing $FFs in the new routine's variables.)

 

I'll patch the .car file with the 2 and 3 button code later tonight (and properly relocated into the post-high-score table space.

 

Link to comment
Share on other sites

3 hours ago, Bobo Cujo said:

I patched your code into the .car file and tried this on a real NTSC Atari 800XL with a Sega Genesis controller (2 button), but unfortunately, the 2-button detection doesn't seem to work (I can't activate the fan with Button 2). ?

(This is true whether or not I include the initializing $FFs in the new routine's variables.)

Oh, I was wondering if that would be a problem. Looking at the pinout now, the Genesis controller uses the third button pin for its power supply. It’s probably pulling the pin low enough that the routine thinks there’s a button there.

 

I tested last night and it does work for me, but I’m using an adapter that reroutes the power from Atari pin 7 and leaves pin 5 unconnected. Ah well, thanks for testing ?

 

3 hours ago, Bobo Cujo said:

 

I'll patch the .car file with the 2 and 3 button code later tonight (and properly relocated into the post-high-score table space.

 

That’s great!

Link to comment
Share on other sites

OK, here's the Joy2B Cartridge versions of Spelunker (based on the version available at atarionline.pl, as mentioned above).

 

A recap of the controls:

 

Existing controls:

Button 1 (Fire Button): Jump

F : Launch Flare (to deal with birds)

D : Place dynamite (to blow up big "hills")

Space: Activate Phantom Blaster (to deal with ghosts)

 

2-button version additional controls:

Button 2 + UP: Launch flare

Button 2 + DOWN: Place dynamite

Button 2 without UP or DOWN: Activate Phantom Blaster

All of the above will still work if the player is moving left or right.

 

3-button version additional controls:

Button 2 + UP: Launch flare

Button 2 + DOWN: Place dynamite

Button 3: Activate Phantom Blaster

All of the above will still work if the player is moving left or right.

 

I've verified the controls in the first hallway (yay conveniently available flares/dynamite :-)) on real hardware (for the 2-button version) and in Altirra (both versions).

I'll try to see if I can beat The Ropes to make sure that part actually works properly...

Spelunker - Joy2B - 3 Buttons.car Spelunker - Joy2B - 2 Buttons.car

  • Thanks 1
Link to comment
Share on other sites

10 hours ago, Eyvind Bernhardsen said:

Thanks to Avery for the Altirra debugger: this kind of patching wouldn't be possible without it.

On that note:

I probably wouldn't have gotten ANY of these Joy2B hacks off the ground if it weren't for the amazing Altirra and its even more amazing debugger.

Thanks a ton, @phaeron!

 

dis6502 has been helpful, too (to get a 10,000 foot view of the overall code, at least for <16K titles/xex games).

 

And thank you @ascrnet and everyone else on this thread for getting this whole Joy2B project off the ground!

I've been wanting a proper standardized multi-button solution on the Atari 8-bit for as long as I can remember ?

 

  • Like 1
Link to comment
Share on other sites

And here's the Joy2B disk versions of Spelunker (same controls as above), which of course also save high scores ?

Special thanks (once again) to @Eyvind Bernhardsen for figuring out the obfuscated jump call and the correct part of free memory to use - these are based on the spelunkertest.atr file mentioned above.

Spelunker - Joy2B - 3 Buttons.atr Spelunker - Joy2B - 2 Buttons.atr

  • Like 2
Link to comment
Share on other sites

18 minutes ago, Bobo Cujo said:

I'll try to see if I can beat The Ropes to make sure that part actually works properly...

I just managed it on the disk version, so putting the patch after the high score table doesn't seem to cause any problems with that. (I like to play the disk version because that saves the high scores... but that means it also saves the button status, which is another reason autodetection won't work.  Oh well.)

 

We can't be 100% sure that it doesn't cause problems until somebody beats the game with a patched version, of course :evil:

Link to comment
Share on other sites

1 hour ago, Bobo Cujo said:

3-button version additional controls:

Button 2 + UP: Launch flare

Button 2 + DOWN: Place dynamite

Oh, a tiny suggestion for the 3-button version: if you look at my code, I delayed setting the "button held" flag for button 2 until after the decision to launch a flare or place dynamite. That way you can hold the button and then press up or down instead of having to move the joystick to the correct position first, which makes the controls feel a bit less fussy.

Link to comment
Share on other sites

I just tested getting beyond "The Ropes" on the disk and cartridge versions I just posted.

The disk versions work fine, and saving high scores doesn't overwrite the button handling code.

The cartridge versions... unfortunately have the same issue as the .xex versions, which is the game going to a black screen upon hitting the Ropes exit instead of actually going to "The Falls". ?

 

Hopefully someone can patch the cartridge version to actually load in the level data upon exiting "The Ropes"...

  • Sad 1
Link to comment
Share on other sites

14 hours ago, Bobo Cujo said:

And thank you @ascrnet and everyone else on this thread for getting this whole Joy2B project off the ground!

I've been wanting a proper standardized multi-button solution on the Atari 8-bit for as long as I can remember ?

thanks to you for the time you have worked on all the games you have modified.?

13 hours ago, Bobo Cujo said:

I just tested getting beyond "The Ropes" on the disk and cartridge versions I just posted.

The disk versions work fine, and saving high scores doesn't overwrite the button handling code.

The cartridge versions... unfortunately have the same issue as the .xex versions, which is the game going to a black screen upon hitting the Ropes exit instead of actually going to "The Falls". ?

 

Hopefully someone can patch the cartridge version to actually load in the level data upon exiting "The Ropes"...

Don't worry so much at least we have ATR's working.?

Link to comment
Share on other sites

On 8/30/2020 at 12:56 AM, Eyvind Bernhardsen said:

Oh, a tiny suggestion for the 3-button version: if you look at my code, I delayed setting the "button held" flag for button 2 until after the decision to launch a flare or place dynamite. That way you can hold the button and then press up or down instead of having to move the joystick to the correct position first, which makes the controls feel a bit less fussy.

@Eyvind Bernhardsen That sounds reasonable.  Here's a revised 3-button version of Spelunker that addresses this:

Spelunker - Joy2B - 3 Buttons - Rev 1.atr

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

Here's Sinistar (Atari prototype, .xex version from Homesoft).

 

Old controls:
Fire button: Shoot (or Fire Sinibomb if "Auto Shooting" is enabled)

Space Bar: Fire Sinibomb

 

New controls:
Button 1: Shoot (or Fire Sinibomb if "Auto Shooting" is enabled)

Button 2: Fire Sinibomb
 

Naturally, "Manual shooting" is highly recommended here (it defaults to Auto).

 

Tested with both players, and verified that I was able to actually destroy a Sinistar.

Link to comment
Share on other sites

Here's Rockball (final version, cartridge - a recently unearthed Roklan game, from the developer of Star Island/Galactic Chase).

 

Old controls:

Left/Right: Rotate ship

Fire Button: Shoot

Up: Thrust, Force spawning of player (on new life)

 

New controls:

Left/Right: Rotate ship

Button 1: Shoot

Button 2: Thrust, Force spawning of player (on new life)

 

Tested with both players.

Rockball (Final) - Joy2B.car

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...