Jump to content

Photo

Need help compiling and updating DPC+ information


119 replies to this topic

#101 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Tue Sep 17, 2013 8:36 AM

No. DPC+ has an arm based 32-bit LFSR for random numbers.

 

Thanks. I better add that to the bB page.



#102 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Tue Sep 17, 2013 12:40 PM

At a y position of zero, the missiles and sprites are a little lower than the top of the playfield:

 

not-high-enough.png

 

Is there any way to fix that?



#103 RevEng OFFLINE  

RevEng

    River Patroller

  • 4,700 posts
  • Bitnik
  • Location:Canada

Posted Tue Sep 17, 2013 2:15 PM

Yeah, a few of the elements are delayed by a scanline, namely P0, M0, M1. I don't think that's going away without some other equally odd delay taking its place.

Currently you can set ENAM0 and ENAM1 before your drawscreen and the missiles will start enabled. They won't be the right color at the top line though - for that you'll need to wait for the next release, which won't be too long.

#104 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Wed Sep 18, 2013 11:03 AM

The stack is useless to me at this time since I don't know how to use it. Are there any bB variables that the DPC+ kernel doesn't use that we can use as variables?

 

There could be an additional way to get variables. Say I only use 4 virtual sprites in a game, I could use player5x, player6x, player7x, player8x, and player9x as variables as long as player5y, player6y, player7y, player8y, and player9y are set to something like 200 to avoid any trouble with collision detection.



#105 RevEng OFFLINE  

RevEng

    River Patroller

  • 4,700 posts
  • Bitnik
  • Location:Canada

Posted Wed Sep 18, 2013 12:52 PM

I'm still planning get around to some more stack examples, but even the example of how to push and pull 1 variable is enough to get started.

 

There aren't additional unused variables; you just get a-z. And as you observed, you can steal the NUSIZ and X variables for any unused virtual players.



#106 Byte Knight OFFLINE  

Byte Knight

    Stargunner

  • 1,023 posts
  • Robinett Rules!
  • Location:Waconia, MN

Posted Wed Sep 18, 2013 10:35 PM

The stack is useless to me at this time since I don't know how to use it. Are there any bB variables that the DPC+ kernel doesn't use that we can use as variables?

 

The stack isn't that complicated, but it uses a lot of cycles.  It's best utilized between levels or room changes.  I used the stack in EMR II to store and retrieve the y position of items with room changes.  You can check it out in the code that's posted here, although there's no rem statements...

 

 

There could be an additional way to get variables. Say I only use 4 virtual sprites in a game, I could use player5x, player6x, player7x, player8x, and player9x as variables as long as player5y, player6y, player7y, player8y, and player9y are set to something like 200 to avoid any trouble with collision detection.

 

Yes, this works and setting the corresponding player1-9y value to 200 will avoid flicker of the on-screen virtual sprites as well.



#107 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Sun Sep 22, 2013 2:20 PM

Here's something I didn't realize. Since we have to use collision(player0,player1) for all virtual sprites, if I use a virtual sprite as the ball and another virtual sprite as a bonus item in a Breakout rip-off and they would happen to be at the same y position when only one of them touches the paddle (player0), the program wouldn't know which item was touching the paddle if I only check y. I'll have to know how wide the paddle is and check x and y to avoid any problems.



#108 iesposta OFFLINE  

iesposta

    River Patroller

  • 3,356 posts
  • Retro-gaming w/my VCS
  • Location:Pennsylvania

Posted Sun Sep 22, 2013 5:44 PM

Collision(player0,AnyVirtualPlayer) works just fine for me. :)

#109 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Sun Sep 22, 2013 6:03 PM

Collision(player0,AnyVirtualPlayer) works just fine for me. :)

 

Forget what I posted here earlier if you saw it before I edited this post. The problem is that collision isn't detecting the part of player0 that is double-sized or quad-sized. Using collision(player0,player1) works on all parts of a stretched player0, but collision(player0,player2) only works on the first left 8 bits of a stretched player0.



#110 RevEng OFFLINE  

RevEng

    River Patroller

  • 4,700 posts
  • Bitnik
  • Location:Canada

Posted Fri Oct 25, 2013 8:47 PM

RT, this bit of your Playfield Resolution (DPC+) docs can now be dropped...
  • Although you can have 176 single scanline rows, part of the bottom scanline will appear in the upper right side of the screen, so it's best to leave it unset or the color of the background.
...the bug that caused it was fixed a release or two back.

#111 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Fri Oct 25, 2013 9:45 PM

RT, this bit of your Playfield Resolution (DPC+) docs can now be dropped...

  • Although you can have 176 single scanline rows, part of the bottom scanline will appear in the upper right side of the screen, so it's best to leave it unset or the color of the background.
...the bug that caused it was fixed a release or two back.

 

 

Thanks. I'll fix it tomorrow. If you see anything else that needs to be changed, please let me know.



#112 RevEng OFFLINE  

RevEng

    River Patroller

  • 4,700 posts
  • Bitnik
  • Location:Canada

Posted Fri Oct 25, 2013 9:55 PM

Will do.

#113 RevEng OFFLINE  

RevEng

    River Patroller

  • 4,700 posts
  • Bitnik
  • Location:Canada

Posted Sat Oct 26, 2013 12:52 PM

I took a look over all of the DPC+ info, and it's good. Just this small typo...
  • Nine of the six sprites are subject to certain limitations, however.
...obviously it should read "Nine of the ten"

#114 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Sat Oct 26, 2013 1:52 PM

I took a look over all of the DPC+ info, and it's good. Just this small typo...

  • Nine of the six sprites are subject to certain limitations, however.
...obviously it should read "Nine of the ten"

 

 

Thanks. I just fixed it.



#115 RevEng OFFLINE  

RevEng

    River Patroller

  • 4,700 posts
  • Bitnik
  • Location:Canada

Posted Tue Nov 12, 2013 12:42 PM

Byte Knight found a limitation of the DPC+ kernel that should probably be documented...

The missile bit of the kernel is actually 2 lines in resolution. If you set missile height to 1, it doesn't show up, depending on if it's on an even or odd row.

#116 iesposta OFFLINE  

iesposta

    River Patroller

  • 3,356 posts
  • Retro-gaming w/my VCS
  • Location:Pennsylvania

Posted Tue Nov 12, 2013 1:32 PM

Byte Knight found a limitation of the DPC+ kernel that should probably be documented...

The missile bit of the kernel is actually 2 lines in resolution. If you set missile height to 1, it doesn't show up, depending on if it's on an even or odd row.

That explains why my Missile stick (vertical) and vertical Ball do not exactly line up!

#117 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Tue Nov 12, 2013 2:33 PM

Byte Knight found a limitation of the DPC+ kernel that should probably be documented...

The missile bit of the kernel is actually 2 lines in resolution. If you set missile height to 1, it doesn't show up, depending on if it's on an even or odd row.

 

Thanks. I noticed that DPC+ missile height didn't work the same as the standard kernel when I made the example program below, but I thought it was a known difference in kernels:

 

randomterrain.com/atari-2600-memories-batari-basic-commands.html#ex_dpc_13_objects



#118 iesposta OFFLINE  

iesposta

    River Patroller

  • 3,356 posts
  • Retro-gaming w/my VCS
  • Location:Pennsylvania

Posted Tue Nov 12, 2013 8:41 PM

Random Terrain,
I just wanted to repeat this info, I don't know if you have it on your site or not.

The older DPC+ template is wrong. Put temp1=temp1 in Bank 6. It is a whole bank, and not reserved for anything. (ScumSoft had his info wrong about that bank.)
The next bank (after bank six) is used for graphics and sprites and colors. Those definitions and data for players, playfields and colors get copied to that bank.
In other words, the Playfield defined in bank 2 and Playfield colors defined in bank 2 and sprites defined in bank 2 don't use any bank 2 space, they use space after bank 6.

So your batari Basic DPC+ rom gets compiled to:
Bank 1: batari Basic code (a few free bytes)
Bank 2-6: Your game code
Bank 7: Graphics bank (no user control)
Bank 8: ARM code (no user control)
Each bank is 4K
8 Banks times 4K equals your 32K binary!

#119 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • Topic Starter
  • 28,179 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Sat Nov 16, 2013 1:40 AM

Random Terrain,
I just wanted to repeat this info, I don't know if you have it on your site or not.

 

I think it is:

 

http://www.randomter...ds.html#dpcplus

 

http://www.randomter...tml#dpc_harmony



#120 iesposta OFFLINE  

iesposta

    River Patroller

  • 3,356 posts
  • Retro-gaming w/my VCS
  • Location:Pennsylvania

Posted Sat Nov 16, 2013 11:09 AM

Thank you for being both random AND accurate! :thumbsup:




0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users