Jump to content

Anyone think Ballblazer is possible on the 2600?


767 replies to this topic

#201  

    River Patroller

  • 4,728 posts
  • Joined: 12-May 01

Posted Mon Oct 13, 2008 9:26 AM

View PostBen_Larson, on Sun Oct 12, 2008 10:35 AM, said:

View Postroland p, on Sun Oct 12, 2008 1:20 PM, said:

Any ideas on how to display 2 players and 2 missiles?
The goals are always going to be above the checkerboard when you're looking straight at them, though. So if you just don't display them when looking sideways, then can't you just use separate '2 player + 2 missile' and '2 player + checkerboard' kernels?

Why can't a couple color-coded squares indicate the goal zone? Maybe you wouldn't have posts when viewed from the side, but with the squares, that would be good enough.

Edited by mos6507, Mon Oct 13, 2008 9:27 AM.


#202  

    Stargunner

  • 1,361 posts
  • Joined: 14-September 07
  • RLA
  • Location:The Netherlands

Posted Mon Oct 13, 2008 10:07 AM

View Postmos6507, on Mon Oct 13, 2008 5:26 PM, said:

Why can't a couple color-coded squares indicate the goal zone? Maybe you wouldn't have posts when viewed from the side, but with the squares, that would be good enough.

But that would be quite different from the original ballblazer. The goal scrolls smoothly from side to side, and the game progresses, the goals are getting narrower too.

#203  

    Moonsweeper

  • 400 posts
  • Joined: 08-October 06

Posted Mon Oct 13, 2008 11:37 AM

Hmm....
Ball?
Every time you hit RESBL another ball is created. But it's need another huge kernel to set all positions for the two parts.

Edit :
...
ldx BallPosA
ldy BallPosB
SetBallPosA
dex
bne SetBallPosA
sta RESBL
SetBallPosB
dey
Bne SetBallPosB
sta RESBL

Not a smooth solution, though...

Edited by LS_Dracon, Mon Oct 13, 2008 12:23 PM.


#204  

    Moonsweeper

  • 336 posts
  • Joined: 05-November 01
  • Location:Columbus, OH, USA

Posted Mon Oct 13, 2008 12:08 PM

View Postroland p, on Sun Oct 12, 2008 6:56 PM, said:

I think that's an elegant solution. I'll try it.

Actually I think you'll need to do 2 players + ball + checkerboard...because you have to display the game ball too, right? There's a trick you can use with the stack pointer to display the ball which doesn't take many cycles though, although the one constraint is that the ball is a constant height. Here's an example which assumes that Y is being used as a line counter:

; before kernel
LDX #$1F
TXS

...

; in kernel
CPY BallYPosition
PHP
PLA

...

; after kernel
LDX #$FF
TXS

I used this in 'Incoming' after someone on the stella list (don't remember who) pointed it out to me.

Ben

Edited by Ben_Larson, Mon Oct 13, 2008 12:12 PM.


#205  

    Stargunner

  • 1,361 posts
  • Joined: 14-September 07
  • RLA
  • Location:The Netherlands

Posted Mon Oct 13, 2008 12:51 PM

@LS_Dracon,
I think I'm going to use the ball just for the ball and the missiles for the goals.

@Ben_Larson,
That's a nice trick. The compare sets the bit (pushed) needed in the ENABL ($1F) register if I understand correctly.


There are now 3 kernels:
1. Sky, Ball, 2 Missiles (only sets them) and 2 players
2. Variable height brown border, displaying 2 players, resets missiles when finished (the goals are aligned at the top of the checkerboard)
3. checkerboard, displaying 2 players

Kernel 2 is really nice. If it is displayed for 3 rows, it has to jump to row 4 of the checkerboard. It also has to scroll like the rest since the whole thing is based on cycles. I have it working right now, I only have to add some sprite code.

Edited by roland p, Mon Oct 13, 2008 12:52 PM.


#206  

    Stargunner

  • 1,004 posts
  • Joined: 23-February 04
  • Location:London / HK / Tokyo / San Fransisco

Posted Mon Oct 13, 2008 1:08 PM

If you only want to change one how about this...

ldx enable+n
ldy which+n
stx enam0,y

enable can be n entry table with values for turning on/off missile - which is table with values 0/1 selecting which to turn on/off

#207 ONLINE  

    Quadrunner

  • 5,752 posts
  • Joined: 19-February 03
  • Medieval Mayhem
  • Location:Planet Houston

Posted Mon Oct 13, 2008 1:11 PM

View Postroland p, on Mon Oct 13, 2008 12:51 PM, said:

@Ben_Larson,
That's a nice trick. The compare sets the bit (pushed) needed in the ENABL ($1F) register if I understand correctly.
I use that in Medieval Mayhem to set the ball and missiles.

		ldx #ENABL	   ; 2 75  need to reset stack
		txs			  ; 2 77
		cpy BLyOddRow	; 3  4
		php			  ; 3  7
		cpy M1yOddRow	; 3 10
		php			  ; 3 13
		cpy M0yOddRow	; 3 16
		php			  ; 3 19

I have an EvenRow and OddRow for each object so they appear over 2 scan lines instead of just 1.

#208  

    River Patroller

  • 4,728 posts
  • Joined: 12-May 01

Posted Mon Oct 13, 2008 4:37 PM

Remember that worst case scenario you CAN use flicker or interlacing the sprites. I think that would be a fair compromise.

#209  

    Stargunner

  • 1,169 posts
  • Joined: 12-March 05
  • Juno First!
  • Location:Glasgow, UK

Posted Wed Oct 15, 2008 4:31 AM

I think you should be able to use the stack/missile trick in your kernel. The first few lines of the screen are quite tight, so you probably won't be able to draw the missiles there, but after that you have plenty of NOPs spacing things out. For two missiles you can use the following code (assumes Y holds the line counter) - the trick will be to space things out into the available cycles.

ldx #ENAM1
; Any instructions that do not affect X
txs
; Any instructions here
cpy M1_POS
; Any instructions that do not affect the zero flag here (e.g. store instructions - see http://www.qotile.net/minidig/docs/6502.txt for details)
php
; Any instructions here
cpy M0_POS
; Any instructions that do not affect the zero flag
php

Chris

Edited by cd-w, Wed Oct 15, 2008 4:31 AM.


#210  

    Stargunner

  • 1,361 posts
  • Joined: 14-September 07
  • RLA
  • Location:The Netherlands

Posted Wed Oct 15, 2008 4:44 AM

View Postcd-w, on Wed Oct 15, 2008 12:31 PM, said:

I think you should be able to use the stack/missile trick in your kernel. The first few lines of the screen are quite tight, so you probably won't be able to draw the missiles there, but after that you have plenty of NOPs spacing things out. For two missiles you can use the following code (assumes Y holds the line counter) - the trick will be to space things out into the available cycles.

ldx #ENAM1
; Any instructions that do not affect X
txs
; Any instructions here
cpy M1_POS
; Any instructions that do not affect the zero flag here (e.g. store instructions - see http://www.qotile.net/minidig/docs/6502.txt for details)
php
; Any instructions here
cpy M0_POS
; Any instructions that do not affect the zero flag
php

Chris

Hi Chris,

Does this code enables the missiles until M0_POS/M1_POS is reached?

Roland.

#211  

    Thrust, Jammed, SWOOPS!

  • 16,625 posts
  • Joined: 25-April 01
  • Always left from right here!
  • Location:Düsseldorf, Germany

Posted Wed Oct 15, 2008 5:39 AM

View Postroland p, on Wed Oct 15, 2008 12:44 PM, said:

Does this code enables the missiles until M0_POS/M1_POS is reached?
No, it only enables the missiles in exactly one single line, when M0/M1_POS are reached.

To get vertical lines of missiles, more complicated code (not mine!) is required:
; M0Adjust = M0Height - 2

  lda M0Height
  dcp M0Y		 ; temporary variable, containing the top position
  sbc M0Adjust
  sta ENAM0	 ;14 cycles

http://www.atariage.com/forums/index.php?s...mp;#entry804737

#212  

    Stargunner

  • 1,361 posts
  • Joined: 14-September 07
  • RLA
  • Location:The Netherlands

Posted Wed Oct 15, 2008 5:58 AM

Well I just need code to disable the missile, as it is enabled in the sky and disabled below the sky.
The current idea is:
- sky kernel, enable missiles
- border kernel disable missiles at end
- checker board kernel

This will work pretty well. But missile-disable code in the kernel would be very nice and I would have less kernels, and goals at the sides.

#213  

    Thrust, Jammed, SWOOPS!

  • 16,625 posts
  • Joined: 25-April 01
  • Always left from right here!
  • Location:Düsseldorf, Germany

Posted Wed Oct 15, 2008 6:51 AM

You don't have a scanline counter, do you?

Else you could do:
; assuming Y is the scanline counter, counting down
  cpy M0end
  rol
  rol		 ; as long as Y is >= M0end, this results into bit 1 set.
  sta ENAM0   ; 10 cycles

Edited by Thomas Jentzsch, Wed Oct 15, 2008 6:52 AM.


#214  

    Stargunner

  • 1,361 posts
  • Joined: 14-September 07
  • RLA
  • Location:The Netherlands

Posted Thu Oct 16, 2008 1:31 AM

View PostThomas Jentzsch, on Wed Oct 15, 2008 2:51 PM, said:

You don't have a scanline counter, do you?

Else you could do:
; assuming Y is the scanline counter, counting down
  cpy M0end
  rol
  rol	; as long as Y is >= M0end, this results into bit 1 set.
  sta ENAM0 ; 10 cycles

I could change my Kernel so that A is used for data, Y as linecounter, X as pointer for what tiles to display (Chris already sent me some sample code).
But do ENAM0 and ENAM1 also make use of the vertical-delay just like player1 and player2?

btw, some improvements I've done:
- checkerboard dimensions in the view is now parameterized, so I can make 21x51 and 51x21 checkerboards (for rotation)
- moved the tile-setup-code to the sky-kernel (was before sky-kernel) so title/score can be displayed between player1 and player2 checkerboards.
- vblank is now free again so all game logic can be put there.

Edited by roland p, Thu Oct 16, 2008 2:03 AM.


#215  

    Quadrunner

  • 5,831 posts
  • Joined: 24-November 04
  • Boom bam.
  • Location:Seattle, WA

Posted Thu Oct 16, 2008 3:54 PM

No - missiles are not VDELed.

EDIT: And a question...
Are you going to translate the Ballblazer "riffology" algorithmic music generator to the 2600? :evil:
http://www.langston.com/LFGames/
http://www.langston.com/Papers/amc.pdf

Edited by vdub_bobby, Thu Oct 16, 2008 4:03 PM.


#216  

    Quadrunner

  • 6,339 posts
  • Joined: 23-May 02
  • Location:Jacksonville, Fl

Posted Thu Oct 16, 2008 4:43 PM

'atari refuses to let videogame fad die' (paraphrase,) that article is priceless. Guess whoever wrote that article is eating their feet. Fad indeed.

#217  

    Stargunner

  • 1,361 posts
  • Joined: 14-September 07
  • RLA
  • Location:The Netherlands

Posted Sun Oct 19, 2008 12:01 AM

View Postvdub_bobby, on Thu Oct 16, 2008 11:54 PM, said:

No - missiles are not VDELed.

EDIT: And a question...
Are you going to translate the Ballblazer "riffology" algorithmic music generator to the 2600?

I don't know. Is it important?

#218  

    Stargunner

  • 1,361 posts
  • Joined: 14-September 07
  • RLA
  • Location:The Netherlands

Posted Sun Oct 19, 2008 12:02 AM

I did some expririmenting on the goals. The goals are now fixed, but will grow if you move towards them, only in height.

Right now I calculate the checkerboard in reversed order in the sky, and just hit ENAM0, ENAM1 whenever I see a border. It doesn't look real enough yet, will work on that.

I have 351 bytes left, so I'm thinking of using bankswitching using the following scheme:

bank 1: framework for vertical blanking etc. + game logic + music + sound effects.
bank 2: sky-kernel, small code so lots of space left for sprites. fetches sprite data needed in checkerboard kernel into ram
bank 3: brown border + checkerboard kernel, 3kb so dedicated bank for this one. displays the sprite which was stored in ram by bank 2.

Attached Files



#219  

    River Patroller

  • 4,728 posts
  • Joined: 12-May 01

Posted Sun Oct 19, 2008 2:39 PM

A couple things. I noticed your timing is sometimes off and it's pushing the bottom display down by a scanline now and then. Also, why don't you implement border collision detection so that you can't fly off into no-man's land anymore?

#220  

    Quadrunner

  • 8,107 posts
  • Joined: 14-May 01
  • This is Sparta!
  • Location:Bavaria

Posted Mon Oct 20, 2008 1:47 PM

View Postvdub_bobby, on Thu Oct 16, 2008 10:54 PM, said:

Are you going to translate the Ballblazer "riffology" algorithmic music generator to the 2600? :evil:

I'll have to look into this :)

Here's a rough TA conversion for the start.

Attached Files



#221  

    Dragonstomper

  • 634 posts
  • Joined: 15-April 07
  • Singing crack rabbit
  • Location:Little Muu

Posted Mon Oct 20, 2008 5:15 PM

View PostCybergoth, on Mon Oct 20, 2008 1:47 PM, said:

View Postvdub_bobby, on Thu Oct 16, 2008 10:54 PM, said:

Are you going to translate the Ballblazer "riffology" algorithmic music generator to the 2600? :evil:

I'll have to look into this :)

Here's a rough TA conversion for the start.
That's soundin' pretty good, so far! You guys have done an amazing job with all of this. I can't wait to see the finished product. :cool:

#222  

    Stargunner

  • 1,453 posts
  • Joined: 03-September 07
  • Location:Coral Gables, FL

Posted Mon Oct 20, 2008 5:44 PM

That's amazing. Great job! :music:

#223  

    Stargunner

  • 1,361 posts
  • Joined: 14-September 07
  • RLA
  • Location:The Netherlands

Posted Tue Oct 21, 2008 1:01 AM

View PostCybergoth, on Mon Oct 20, 2008 9:47 PM, said:

View Postvdub_bobby, on Thu Oct 16, 2008 10:54 PM, said:

Are you going to translate the Ballblazer "riffology" algorithmic music generator to the 2600? :evil:

I'll have to look into this :)

Here's a rough TA conversion for the start.
Nice!


Quote

A couple things. I noticed your timing is sometimes off and it's pushing the bottom display down by a scanline now and then. Also, why don't you implement border collision detection so that you can't fly off into no-man's land anymore?
I guess that extra line is caused by some decision logic taking up just a little more than one scanline at that moment. I'll have to use one of the atari 2600 timers to stay in sync.
I'll do some border detection too.

The speed of the drones is now stored in velocityX and velocityY variables. This will have to change too. It should be a direction (vector angle) and a speed (vector length). If I have that, I can add de-acceleration and speed-limits.

#224  

    River Patroller

  • 3,077 posts
  • Joined: 08-December 02
  • Location:KC, KS, USA

Posted Tue Oct 21, 2008 9:36 PM

View PostCybergoth, on Mon Oct 20, 2008 2:47 PM, said:

View Postvdub_bobby, on Thu Oct 16, 2008 10:54 PM, said:

Are you going to translate the Ballblazer "riffology" algorithmic music generator to the 2600? :evil:
I'll have to look into this :)

Here's a rough TA conversion for the start.
Dude... ouch. Rough indeed!

Attached is the result of a couple days experimentation on my part. I gave up trying to get the last few notes in tune. Anyone is welcome to run with this.

Attached Files



#225  

    Quadrunner

  • 27,072 posts
  • Joined: 23-January 01
  • Location:NGC 224

Posted Wed Oct 22, 2008 8:19 AM

View PostZylonBane, on Tue Oct 21, 2008 10:36 PM, said:

View PostCybergoth, on Mon Oct 20, 2008 2:47 PM, said:

View Postvdub_bobby, on Thu Oct 16, 2008 10:54 PM, said:

Are you going to translate the Ballblazer "riffology" algorithmic music generator to the 2600? :evil:
I'll have to look into this :)

Here's a rough TA conversion for the start.
Dude... ouch. Rough indeed!

Attached is the result of a couple days experimentation on my part. I gave up trying to get the last few notes in tune. Anyone is welcome to run with this.
Sounds pretty good, even with the notes that are not quite in tune. :)

..Al





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users