Jump to content

Photo

Squish 'Em for the 2600 (Done!)


118 replies to this topic

#1 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Mon Dec 3, 2007 10:23 AM

Squish 'Em was one of my favorite games when I was a kid and so, about a year ago, I thought it might be a fun game to port to the 2600. And now, a year later, here I am trying to get it done. My goal is to give it to my son for Christmas so I need to finish it in about 2 weeks. :o We'll see...:ponder:

Here's a brief description:

You are climbing a building, trying to reach the suitcase of cash at the top. Watch out for all the nasty critters that are trying to knock you off, and watch out for the falling bricks as well. If you can't avoid the critters, or you need to relieve a little stress, you can always Squish 'Em instead!

Use the joystick to move left and right and to climb and press the trigger to squish the monsters.

SquishEm20071202.bin.png
Final builds and source code:
Attached File  squishem20071215NTSC.bin   4KB   304 downloads
Attached File  squishem20071215PAL60.bin   4KB   216 downloads
Attached File  squishem20071215.zip   23.46KB   209 downloads

EDIT DEC 18 2007: And that's a wrap! Thanks for all the help, everyone. :)

Attached Files


Edited by vdub_bobby, Tue Dec 18, 2007 1:04 PM.


#2 duncantoml OFFLINE  

duncantoml

    Moonsweeper

  • 251 posts

Posted Mon Dec 3, 2007 10:49 AM

Pretty good Bob!

I see that you have a few things different in your version.

1) the falling object is not always over the climber.

2) You have moved the beam lay out. This is interesting and seems to be a nice chnage.

3) The bag of money can knock you off, if you clmb up under it. In the other versions, the bag is betweem the beams, so you can't get kill by it.

All in all this is going to be a good one. Always like this game!

#3 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Mon Dec 3, 2007 10:51 AM

I think what I'll do is attach the latest binary to the first post and list changes and attach the source+binary zip file to the last post.

So, here's the current state of things:

I made major, major changes to how the guy moves left and right. I thought things were fine and I was playing the Atari800 version and I thought to myself, "He sure seems to move with a jerking motion...?" So I slowed down the A8 emulator and, what do you know, he doesn't move smoothly left/right, he moves with a start-stop motion. Another weird thing: he goes from girder-to-girder in the same amount of time, no matter the distance between girders. So, yes, he moves faster when he is crossing the middle. The basic pattern is 5 frames long. In the center, the pattern is move for 4 frames, pause for 1 frame, repeat. Not in the center it's move for 3 frames, pause for 2. Weird!

Other changes:
-Added enemy movement patterns; these are mostly done except for speeding them up at higher levels.
-Tightened up the kernel and made a few tweaks to how the girder/enemy data is stored.
-Level transitions work. Grab a suitcase and you'll move to the next level.
-You will die if you hit a monster or a brick. And, in some cases, if you hit a suitcase or bonus item. :ponder:
-Squishing is complete, I think.
-Lots of other back-end stuff

Lot's still to do!

Attached Files


Edited by vdub_bobby, Mon Dec 3, 2007 10:52 AM.


#4 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Mon Dec 3, 2007 10:55 AM

Pretty good Bob!

I see that you have a few things different in your version.

1) the falling object is not always over the climber.

2) You have moved the beam lay out. This is interesting and seems to be a nice chnage.

3) The bag of money can knock you off, if you clmb up under it. In the other versions, the bag is betweem the beams, so you can't get kill by it.

All in all this is going to be a good one. Always like this game!

Thanks Tom! :)

Some of those things are either bugs (#3) or just not coded yet (#1). #2 has me a bit perplexed, though. What do you mean? I did notice that in the original there are always at least two beams to climb; my version sometimes will just have one. This will be changed, though, I haven't gotten to it yet. Is that what you meant or is there something more...?

And getting back to #3, I don't think it's true that the suitcase/bonus item is always between beams; I'm pretty sure that sometimes you can climb up into it. I'll do some testing. If you're right, that would make fixing that bug a lot easier!

Thanks very much for the comments!

#5 duncantoml OFFLINE  

duncantoml

    Moonsweeper

  • 251 posts

Posted Mon Dec 3, 2007 11:17 AM

#2 has me a bit perplexed, though. What do you mean? I did notice that in the original there are always at least two beams to climb; my version sometimes will just have one. This will be changed, though, I haven't gotten to it yet. Is that what you meant or is there something more...?



Bob,

I'll use the picture you have in your first post as a example. The top 2 levels have the 2 beams on both on the left side. In the CV version the beams are mirrored. So if there is a beam on the far right, then there is a beam on the far left. Second from the left then there is also one second from the right.

I do like the change!

ALso, the CV version does have levels that have only one beam to climb and it is always in the middle(second picture, bottom level). Can't remember if the 800 version does or not. Have not play that one for some time.

I think the one beam on some levels should be lefted.

Just now noticed that your version has 6 places that up beams can be placed, the CV has 5. again, not sure about the 800.


Tom

Attached Thumbnails

  • ss_009.jpg
  • ss_010.jpg

Edited by duncantoml, Mon Dec 3, 2007 11:26 AM.


#6 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Mon Dec 3, 2007 11:30 AM

#2 has me a bit perplexed, though. What do you mean? I did notice that in the original there are always at least two beams to climb; my version sometimes will just have one. This will be changed, though, I haven't gotten to it yet. Is that what you meant or is there something more...?


I'll use the picture you have in your first post as a example. The top 2 levels have the 2 beams on both on the left side. In the CV version the beams are mirrored. So if there is a beam on the far right, then there is a beam on the far left. Second from the left then there is also one second from the right.

I do like the change!

Ah! I didn't realize that the CV version had mirrored beams!

ALso, the CV version does have levels that have only one beam to climb and it is always in the middle(second picture, bottom level). Can't remember if the 800 version does or not. Have not play that one for some time.

I think the one beam on some levels should be lefted.

Just now noticed that your version has 6 places that up beams can be placed, the CV has 5. again, not sure about the 800.

Interesting. I am going for as close to an exact port of the Atari 800 version as possible. I'll attach a pic. :)

The CV version looks very much like the C64 version, I wonder how close they are.

Atari 800 pic:
SquishEm2.png

EDIT: Holy cow! I can't believe...I never noticed...
I'm such a moron!

I knew that the beams in the Atari 800 version weren't mirrored, but I just noticed that the beams in the Atari 800 are NOT asymmetrical either - they are duplicated! I can't believe I never noticed that. Wow. No wonder there is never just one beam. :ponder:

Well, I'll add that to my list of things to do. This is good and bad - bad because now I need to rewrite the kernel a bit :x but very good because now I can compact 4 giant tables (64 bytes each!) into 2 small tables (8 bytes each). Plus I'll gain some time in the kernel and I might be able to add the brick pattern on the far left and right walls.

Just, wow. I absolutely cannot believe I never saw this, especially with all the time I've spent playing the game over the last couple of weeks. :roll:

EDIT II: Actually...this may be more complicated than I thought. Might not get anymore free time in my kernel, though I can definitely compact those tables.

Edited by vdub_bobby, Mon Dec 3, 2007 11:38 AM.


#7 Tempest OFFLINE  

Tempest

    Monochrome Martinet

  • 25,683 posts
  • Location:Accardi-By-The-Sea

Posted Mon Dec 3, 2007 11:39 AM

There's a chance that a prototype for a 2600 version of Squish 'em exists. TCF was going to release it as The Fall Guy (the story being that aliens have invaded the movie set). I think one of the advertisements has a picture, but it's more than likely just a mock-up.

Tempest

#8 Cybergoth OFFLINE  

Cybergoth

    Quadrunner

  • 8,793 posts
  • This is Sparta!
  • Location:Bavaria

Posted Mon Dec 3, 2007 1:49 PM

Sirius actually intended to release a 2600 version themselves. The original manual even has instructions for the 2600 version, just have a look at it: http://www.atarimani...VERSION_ID=4967

I still don't know why it didn't come out, as the design was a perfect fit for the 2600. Even when my theory, that Sirius got assimilated by Activision, is true - then why didn't Activision just release it, like Turmoil and Fast Eddie?

#9 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Tue Dec 4, 2007 11:19 AM

Latest.

Changes:
-fixed girders so they match original
-fixed some bugs/mistakes in how the brick fell after it whacks you on the head

I think that's it. I've started working on the disassembly of the A800 source, hopefully I can make some good progress and translate the sounds soon. :)

Attached Files



#10 ZylonBane ONLINE  

ZylonBane

    River Patroller

  • 3,686 posts
  • Location:KC, KS, USA

Posted Tue Dec 4, 2007 11:36 AM

I'd always assumed that the Atari computer version of Squish'Em was a straight 2600 port, like most of the Fox/Sirius releases (Fantastic Voyage, Turmoil, Worm War I, etc). I'd be stunned if there wasn't a complete, unreleased 2600 version of Squish 'Em gathering mold somewhere.

#11 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Tue Dec 4, 2007 12:01 PM

I'd always assumed that the Atari computer version of Squish'Em was a straight 2600 port, like most of the Fox/Sirius releases (Fantastic Voyage, Turmoil, Worm War I, etc). I'd be stunned if there wasn't a complete, unreleased 2600 version of Squish 'Em gathering mold somewhere.

That would make sense; the A800 version is written like a 2600 game. Digging through the disassembly, it doesn't seem to use ANTIC much, has a 2600-style kernel. Kind of odd, actually.

#12 Noelio OFFLINE  

Noelio

    Moonsweeper

  • 498 posts
  • Location:Newfoundland, Canada

Posted Tue Dec 4, 2007 1:44 PM

I'd love for someone to port Uncharted: Drake's Fortune from the Playstation 3 to 2600!!!

LOL.

Squish 'Em was a blast on the 800... Can't wait to see & play your final port!
What an awesome Dad you are to port that as a gift!

#13 mimo OFFLINE  

mimo

    Preppie!

  • 6,798 posts
  • It's easy living in a bubble

Posted Tue Dec 4, 2007 7:45 PM

Really nice, love the vibrant colours, plays very well.
Feels quite Activision dare I say

Good luck with getting this done

#14 tschak909 OFFLINE  

tschak909

    Stargunner

  • 1,481 posts
  • Location:USA

Posted Wed Dec 5, 2007 12:03 AM

Fantastic work! *claps* I'd love to see code :-)

-Thom

Cybergoth edit: Removed the fullquote. While I'm at it, the code is in Bobs blog ;)

#15 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Wed Dec 5, 2007 10:09 AM

Fantastic work! *claps* I'd love to see code :-)

As Manuel said, the code is in my blog, the current code is in the latest ZIP file in this thread. Or it should be, at least.

And speaking of code, I've been having so much fun disassembling the A800 Squish 'Em that I think I'll try to push through and finish it. I'll post it when I do. I've figured out how the music is played (it's pretty clever) and found the frequency table, and also found how he moves the "erratic" enemies and how long enemies stay squished. First game (on any platform) I've ever disassembled; it's pretty fun. :)

Some interesting things I've found...
ANTIC is used to draw the score and the building frame only. All player/missile data and color changes are directly written to the hardware, like a 2600 game. P2 and P3 (quadrupled) are used to draw two (vertical) girders each, and M2 and M3 are used to draw the other two. M0 is used to draw the falling brick and P0 is used to draw the climber. P1 is used to draw the enemies. P2 and P3 are also used to mask the sides of the screen at the top and bottom, where the score and extra lives are displayed, and the background color is changed to get the striped effect.

And speaking of the extra lives, from the code it looks like you can have up to 255 extra guys, though only 7 (!) are displayed on screen. Yeah, that seven has me a bit worried...a 2600 compromise might be to have a max of 6 displayed at the most. It would be a neat trick to get seven displayed, but for an effect that only the very few very best players will ever see, it probably isn't worth the time or ROM space.

#16 Heaven/TQA OFFLINE  

Heaven/TQA

    Quadrunner

  • 9,975 posts
  • Location:Baden-Württemberg, Germany

Posted Wed Dec 5, 2007 11:59 AM

so the engine does write the PM data directly into hardware?

#17 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Wed Dec 5, 2007 12:27 PM

so the engine does write the PM data directly into hardware?

Yup, here's a snip of the code; only partially labelled and commented. I left my more-finished copy at home today so I wouldn't be tempted to work on this at work! :lol:
MainPlayAreaKernelStart
		ldx #4		;21DC A2 04		index into floors
MainPlayAreaKernelLoop
		lda ZP_AF,X	;21DE B5 AF
		sta P0GfxPtr	;21E0 85 80
		lda ZP_BB,X	;21E2 B5 BB
		sta MxGfxPtr	;21E4 85 84
		lda ZP_B5,X	;21E6 B5 B5

		sta WSYNC	;21E8 8D 0A D4
		sta P0ColorPtr	;21EB 85 82

		ldy #$1F	;21ED A0 1F
		bcc L_21F4	;21EF 90 03
L_21F1
		sta WSYNC	;21F1 8D 0A D4
L_21F4
		lda (P0GfxPtr),Y	;21F4 B1 80
		sta GRAFP0	;21F6 8D 0D D0		direct write to P0!  Not using ANTIC
		lda (P0ColorPtr),Y	;21F9 B1 82
		and ColorMask0	;21FB 25 8A
		sta COLPM0	;21FD 8D 12 D0
		lda (MxGfxPtr),Y	;2200 B1 84
		sta GRAFM	;2202 8D 11 D0
		dey		;2205 88
		cpy #24		;2206 C0 18
		bcs L_21F1	;2208 B0 E7		loop while Y >= 24

		lda P0PL	;220A AD 0C D0		player to player collisions
		lsr @		;220D 4A
		lsr @		;220E 4A		get P0-to-P1 collision into carry 
		ror P0P1Collisions;220F 66 ED		and roll into RAM
		lda ZP_9B,X	;2211 B5 9B
		sta GRAFP2	;2213 8D 0F D0
		sta GRAFP3	;2216 8D 10 D0
		lda ZP_A1,X	;2219 B5 A1
		sta HPOSM2	;221B 8D 06 D0
		lda ZP_A7,X	;221E B5 A7
		sta HPOSM3	;2220 8D 07 D0
		sta WSYNC	;2223 8D 0A D4

		bcc L_222B	;2226 90 03		branch always
L_2228
		sta WSYNC	;2228 8D 0A D4
L_222B
		lda (P0GfxPtr),Y;222B B1 80
		sta GRAFP0	;222D 8D 0D D0
		lda (MxGfxPtr),Y	;2230 B1 84
		sta GRAFM	;2232 8D 11 D0
		lda (P0ColorPtr),Y	;2235 B1 82
		and ColorMask0	;2237 25 8A
		sta COLPM0	;2239 8D 12 D0
		dey			;223C 88
		cpy #12		;223D C0 0C
		bcs L_2228	;223F B0 E7		loop while Y >= 12

		lda ZP_C1,X	;2241 B5 C1
		sta HOPSP1	;2243 8D 01 D0
		lda ZP_C6,X	;2246 B5 C6
		sta P1GfxPtr	;2248 85 86
		lda ZP_CB,X	;224A B5 CB
		and ColorMask0	;224C 25 8A
		sta COLPM1	;224E 8D 13 D0
L_2251
		sta WSYNC	;2251 8D 0A D4
		lda (P0GfxPtr),Y;2254 B1 80
		sta GRAFP0	;2256 8D 0D D0
		lda (P1GfxPtr),Y;2259 B1 86
		sta GRAFP1	;225B 8D 0E D0
		lda (MxGfxPtr),Y;225E B1 84
		sta GRAFM	;2260 8D 11 D0
		lda (P0ColorPtr),Y;2263 B1 82
		and ColorMask0	;2265 25 8A
		sta COLPM0	;2267 8D 12 D0
		dey		;226A 88
		bpl L_2251	;226B 10 E4		loop while Y >= 0

		dex		;226D CA
		beq L_2273	;226E F0 03		update overall index and loop while > 0
		jmp MainPlayAreaKernelLoop	;2270 4C DE 21


#18 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Fri Dec 7, 2007 9:44 AM

Update!

Biggest change is the music! All four musical cues are in: beginning a game, starting a new life, reaching a new level (i.e., every 16 floors), and grabbing a suitcase. Though the new-level music comes in one floor too early. Also got the background wah-wah-wah-wah sound in as well. These sounds translated very well from the A800, I think they sound pretty good.

I played around with the pocka-pocka sound for when you are moving/climbing, but I couldn't get it to sound right and I can't quite figure out how they get that exact effect in the A800 game - I found the notes for that but I can't find where or how they vary the volume (or?) to get the "pocka" sound. I'll keep digging.

I also fixed the collision detection, now you won't die if you hit a suitcase/bonus item from underneath. :D

Source and binary are attached in the zip file.

EDIT: I almost forgot! The legs-up and dying/falling sounds are in as well. They also translated very well, especially the legs-up sound. The dying one not so well, though it's close enough that I'm cool with it.

Basically, I'm running into two problems with translating the sound: First, the Atari 800 pure tones are divided down from 64 KHz (is that exact?) while the 2600 pure tones are divided down from 31.44 KHz. So it's sort of close to half the frequency, so if I divide the frequencies in half then the result is pretty close. Of course, when I divide the frequencies in half I also lose a bit of precision, so it I'm losing accuracy in two ways. The other problem is that the A800 can divide it's base frequency by 1-256, while the 2600 only can divide by 1-32. This hasn't been a problem as much as I thought but, for example, the falling/dying sound is not nearly as smooth on the 2600 since if I change the frequency as fast as the A800 does I quickly run out of frequencies! I might look into some trickiness with switching to a different AUDCx value to get some lower frequencies, but I think it sounds OK right now so it isn't a priority.

Attached Files


Edited by vdub_bobby, Fri Dec 7, 2007 9:56 AM.


#19 Prodos8 OFFLINE  

Prodos8

    River Patroller

  • 2,260 posts
  • Where is John Galt?
  • Location:DFW, Texas

Posted Fri Dec 7, 2007 9:58 AM

Awesome game! :thumbsup:

#20 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Fri Dec 7, 2007 10:07 AM

Quick update. I found what gives the pocka-pocka sound! They are updating the volume (and sound effect frequency) twice per frame: they zero it out and then later set it to the appropriate value.

I added that in and it sounds pretty good, though it seems likely that the timing is somewhat critical for this so I might have to experiment a bit :)

#21 johnnywc OFFLINE  

johnnywc

    Stargunner

  • 1,370 posts

Posted Fri Dec 7, 2007 12:44 PM

Hey Bob -

Just downloaded this and gave it a try - fantastic work! Can't wait to buy the finished product.

#22 Nathan Strum ONLINE  

Nathan Strum

    Quadrunner

  • 7,111 posts
  • Enjoying a sandwich
  • Location:Newhall, CA

Posted Fri Dec 7, 2007 4:01 PM

Looking and sounding good, Bob! Just played the A800 version again, and it's amazing how close your version is getting to it. Will the building color change in yours as well?

#23 Cybergoth OFFLINE  

Cybergoth

    Quadrunner

  • 8,793 posts
  • This is Sparta!
  • Location:Bavaria

Posted Fri Dec 7, 2007 4:16 PM

Just downloaded this and gave it a try - fantastic work! Can't wait to buy the finished product.


Same here, I will definitely buy this one!

When having my extreme playtesting session over the weekend, I will try to fit this in as well :)

Bob, you think you can do a quick PAL60 version, so I can already have an eye on the colors?

#24 vdub_bobby OFFLINE  

vdub_bobby

    Quadrunner

  • Topic Starter
  • 5,831 posts
  • Boom bam.
  • Location:Seattle, WA

Posted Fri Dec 7, 2007 4:52 PM

Looking and sounding good, Bob! Just played the A800 version again, and it's amazing how close your version is getting to it. Will the building color change in yours as well?

Yes, that's on my list. That's one of the final changes that need to be made to the kernel, to un-hardcode the score/girder colors.

But I need to get a A800 color chart and compare to a 2600 color chart since the way A8 Squish 'Em does it is to just add $10 to the color every new level (with a few complications, of course ;)). It would be nice if I could do that too, but it will only work if the colors go in the same order...:ponder:

As for PAL colors, Manuel - I'll try to whip that up but I am swamped at work right now and probably won't be able to until much later tonight, if at all. I'll try, though. :)

#25 Cybergoth OFFLINE  

Cybergoth

    Quadrunner

  • 8,793 posts
  • This is Sparta!
  • Location:Bavaria

Posted Sat Dec 8, 2007 7:04 AM

This is such a marvellous project. I realize this is still pretty much a tech demo, but still it made me climbing the building for almost 20 minutes, stopping somewhere near a bunch of non-moving extra-life providers. Absolutely flawless and smooth so far. This is going to be your best game so far Bob, I even dare predicting that the final result will be playing in the league of Thrust and Lady Bug - a definite must-have for the 2600! :D




0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users