Jump to content

Photo

VS Squad (Early WIP) (Atari 2600)


8 replies to this topic

#1 triggthediscovery OFFLINE  

triggthediscovery

    Combat Commando

  • 2 posts

Posted Sun Apr 14, 2019 3:01 PM

Hello, I've been working on my first major 2600 project, and decided to post about it here just to see what people think about it.

 

It's a vertically scrolling shooter for the 2600 running on a stock 4k cart. I don't have a harmony cart, so I've only had the opportunity to test it in an emulator, so apologies if it's not stable on real hardware.

 

The kernel should theoretically support ~30 enemies on screen at a time. The current version technically supports this, but it can cause some bad artifacts with scrolling enemies. Currently it's more of a tech demonstration than a game, since I need to rewrite the kernel to allow for collision detection (I was planning on doing collision detection separately, but after calculating the timing it would take 30+ scanlines for all the math) but I figured before I gutted my code I would record the state things are in right now. Luckily, I won't have to remove any functionality shown in the current demo, so it should be representative of the game if I get the time to finish it

 

 

edit: replaced outdated version

 

Attached Files


Edited by triggthediscovery, Mon Apr 15, 2019 6:33 PM.


#2 Arenafoot OFFLINE  

Arenafoot

    Stargunner

  • 1,375 posts
  • videogamestores.net
  • Location:Watson, LA

Posted Sun Apr 14, 2019 7:06 PM

Could it be the beginning of a Galaga port to the 2600????? 



#3 MemberAtarian OFFLINE  

MemberAtarian

    Moonsweeper

  • 274 posts

Posted Mon Apr 15, 2019 12:06 AM

I don't have any words... The way you shoot, the 3D effect, the number of enemies, you made a really good job! If you could reduce the enemies to 20 and use that free time for calculating detections, that would be still impressive. :)



#4 Albert OFFLINE  

Albert

    Quadrunner

  • 35,309 posts

Posted Mon Apr 15, 2019 11:13 AM

That looks very cool!  Can't wait to see how it evolves.  :)  Thanks for sharing!

 

 ..Al



#5 SpiceWare OFFLINE  

SpiceWare

    Draconian

  • 12,749 posts
  • Medieval Mayhem
  • Location:Planet Houston

Posted Mon Apr 15, 2019 12:30 PM

I like your use of the ball to free up both players for all the enemy.

 

Picture rolls on real hardware.  

 

Attached File  IMG_1244.MOV.zip   31.64MB   3 downloads

 

Take a look at Step 1 of my tutorial and compare how it updates VSYNC and VBLANK, especially in relation to WSYNC.  As one example look at this bit of code:

VerticalSync:
        lda #2      ; LoaD Accumulator with 2 so D1=1
        sta WSYNC   ; Wait for SYNC (halts CPU until end of scanline)
        sta VSYNC   ; Accumulator D1=1, turns on Vertical Sync signal
        sta WSYNC   ; Wait for Sync - halts CPU until end of 1st scanline of VSYNC
        sta WSYNC   ; wait until end of 2nd scanline of VSYNC
        lda #0      ; LoaD Accumulator with 0 so D1=0
        sta WSYNC   ; wait until end of 3rd scanline of VSYNC
        sta VSYNC   ; Accumulator D1=0, turns off Vertical Sync signal
        rts         ; ReTurn from Subroutine

vs. what you're doing:

 

Screen Shot 2019-04-15 at 1.26.39 PM.png

 

The VSYNC should happen after WSYNC, not before.



#6 SpiceWare OFFLINE  

SpiceWare

    Draconian

  • 12,749 posts
  • Medieval Mayhem
  • Location:Planet Houston

Posted Mon Apr 15, 2019 4:19 PM

I hacked the ROM using Stella - besides the VSYNC WSYNC swap I also needed to move the lda #$00 sta VBLANK.  That should be done just before you start the kernel (drawing the visible screen), not during the Vertical Sync. Reason being is that will turn on video output, and the colors will interfere with the display's ability to detect the VSYCN signal.

 

 

changed the sta VBLANK to NOP NOP to remove it, swapped 2 occurrences of VSYNC and WSYCN

 

Screen Shot 2019-04-15 at 5.02.37 PM.png

 

Added sta VBLANK just before the screen gets drawn

 

Screen Shot 2019-04-15 at 5.03.11 PM.png

 

After that, the other thing I notice is the enemy only shows up on the right side of the screen.  It was like that in the video, so it's not due to the hacks I did.  For debugging purposes you should make each player a different color, which'll make it easier to figure out if the position problem is with player0 or player1.  

 

Attached File  vparallax.a26   4KB   12 downloads

 

I also suggest you read at least the first few parts of my tutorial, you'll want to use the timers (as shown in Step 2) rather than a bunch of writes to WSYNC (as shown in Step 1).

Attached Thumbnails

  • IMG_1245.jpg


#7 triggthediscovery OFFLINE  

triggthediscovery

    Combat Commando

  • Topic Starter
  • 2 posts

Posted Mon Apr 15, 2019 6:32 PM

I apologize, I accidentally uploaded an outdated bin file!

 

Thanks SpiceWare, I'm realizing I'm going to need a flashcart if I want to make sure it works properly on a real system. In regards to all my WSYNCs I might use the timer in the final version, but right now they were just the easiest way to get a stable game in Stella, I intend to hopefully use all that free CPU time for something fun.

 

But here's my current beta, and I know it works as a demo in Stella, but it doesn't have any added features, again sorry for the outdated bin

 

 

Attached Files



#8 SpiceWare OFFLINE  

SpiceWare

    Draconian

  • 12,749 posts
  • Medieval Mayhem
  • Location:Planet Houston

Posted Tue Apr 16, 2019 8:31 AM

There's no question that you will use the timers, without them it's too difficult to implement game logic while also maintaining a stable display.

 

Nicht sehr gut on hardware.

 

Attached File  IMG_1246.MOV   33.77MB   1 downloads

 

 

 

While it works in Stella, it doesn't work if you have Stella set for developer mode:

 

Screen Shot 2019-04-16 at 9.14.39 AM.png

 

 

 

Note the Developer text just after 4K.  This is part of the frame stats, which is toggled using a Developer Key in Stella (ALT-L for Linux or Windows, and COMMAND-L for Mac).  Do note that due to the randomize options of Developer mode, the game will sometimes start up differently:

 
Screen Shot 2019-04-16 at 9.14.45 AM.png
 
 
 
and sometimes work correctly:
 
Screen Shot 2019-04-16 at 9.15.19 AM.png
 
 
To turn on Developer Mode hit TAB to bring up the in-game menu:
Screen Shot 2019-04-16 at 9.15.25 AM.png
 
 
 
Click Developer... which is the bottom left button, then select the Developer Settings radio button at the top.

Screen Shot 2019-04-16 at 9.15.29 AM.png

 

 

 

As a developer you really want to turn that on, it will expose bugs in your code that will show up on some, but not all, Atari consoles. One of the most common bugs is to leave off a # in an immediate mode instruction, aka typing in LDA $02 when you really meant to type LDA #$02.  Same for LDX and LDY immediate mode instructions.

 

 

 

 

 


#9 SpiceWare OFFLINE  

SpiceWare

    Draconian

  • 12,749 posts
  • Medieval Mayhem
  • Location:Planet Houston

Posted Tue Apr 16, 2019 8:52 AM

Flash cart options are:

 

The Harmony - I have both versions, the original and the Encore that supports larger games.  One thing I like is games written to take advantage of the original Harmony's hardware (ie: utilize the ARM as a coprocessor) can be produced as stand along games by using the Melody board.  Recent examples of what can be down with that are my Draconian and John's Mappy (check the videos).  While you're not yet ready to create games like those, you will be in the future.

 

The UnoCart supports larger games as well. My understanding is they're working on a version for standalone games, but I don't know when that'll be ready.  Follow along with this topic if you'd like to keep up with UnoCart development, as well as where to buy one.

 

For smaller projects you could also use a Starpath Supercharger, it'll support 4K games; however, it's around the same cost as the Harmony or UnoCart and not as easy to work with.  You'll have to turn your BIN into an audio file and figure out how to play it into the Supercharger - games for it were sold on cassette tapes back in the 80s.  I started out with one of these, but haven't used it in over a decade.






0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users