Jump to content

The Southsider

  • entries
    81
  • comments
    767
  • views
    136,277

Star Castle Collision Detection

cd-w

1,833 views

After much head-scratching and code optimisation, I finally have collision detection working! In this version you can shoot the ring segments. For now they only take one hit, but this can easily be changed.

 

blogentry-6563-0-26452900-1326914138.png

 

I think I now have all of the pieces necessary to make the game. However, I now need to put it all together and rewrite significant parts of it, such as the kernel. The main issue now is running out of ROM space as all the unrolled code has nearly used up the full 12KB.

 

Let me know if you have any suggestions, or if you find any collision detection bugs.

 

Chris

 

P.S. Remember to hit Alt-P in Stella to avoid the flicker.

 

starkernel6.bin

starkernel6.zip



14 Comments


Recommended Comments

Hi Chris.

 

Works great. How about blinking the piece of shield after a shoot colision? In the original they reduce the bright of the vector line, you know.

 

Do you going to use the Thrust filled space ship or it's a place holder? Can I make new ship graphics based on the original?

Share this comment


Link to comment

Hi Ivan,

 

Thanks for the comments. I'm not sure I have enough spare cycles to blink the shield, but I'll see. It is a pity that the colour brightness can't be changed, but it was already a real struggle to get the 3 ring colours to display!

 

The Thrust sprite and the rotating gun at the centre are just place holders. Nathan has kindly said that he will work on them, but I'm sure he wouldn't mind you stepping in as he is rather busy at the moment.

 

The ship sprite has 32 rotation positions and is limited to 8 pixels width. The height is currently 8 pixels (2LK) but that is not fixed. The gun sprite currently has 16 rotation positions (it would be nice if this could be increased) and is also limited to 8 pixels wide.

 

Thanks,

Chris

Share this comment


Link to comment
The Thrust sprite and the rotating gun at the centre are just place holders. Nathan has said that he will work on them, but I'm sure he wouldn't mind you stepping in as he is rather busy at the moment.

 

If Nathan is going to produce the sprites, they are on good hands. :)

 

About the blink shield parts, I forgot it's already using fliker, will not looks good certainly.

Share this comment


Link to comment

I think the shot sometimes does not touch the centre but it still "explodes" = flashes the screen

 

see this - it flashes but no collision between shot and the object:

 

xor60o.jpg

Share this comment


Link to comment

Thanks for the complements - they are keeping me motivated to work on this!

 

maiki - well spotted - the collision detection for the centre gun is done using an 8x8 bounding box. However, the gun sprite is only 7x7 in that position. I'll tighten up the bounds when the real gun sprite is implemented.

Share this comment


Link to comment

It uses CBS RAM+ bankswitching (not Supercharger) which gives 256 bytes of extra RAM. It can be released on a melody board when it is completed.

 

Chris

Share this comment


Link to comment

Planning on making this game 16k? If it ends up being 12k, wouldn't it work only on a Supercharger?

SC is 6K RAM + 2K ROM containing the boot screen & load routines. All of the RAM is writable via an indirect process. The RAM is also three 2K banks, but there are restrictions on the bank combinations.

Share this comment


Link to comment
Guest
Add a comment...

×   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...