Jump to content
  • entries
    657
  • comments
    2,689
  • views
    897,746

Explosions


SpiceWare

1,050 views

  • preliminary explosion sequence
  • asteroids, mines and enemy ships are deadly to touch
  • station shots are deadly
  • Player Lost a Life routine
  • added a buffer space around the ships spawn point so asteroids/mines aren't placed next, or even on, the ship.

Collision routines don't support quad sized sprites yet, so flying thru a station won't kill you (their shots on the other hand...)

 

The new buffer space around the spawn point increased the odds of there being screen jitter or roll when a level is initialized. I plan to revise the way the routines work so that the level init is run mid-screen like I do in Stay Frosty 2.

 

In Stay Frosty 2 I originally used RLE to compress 2328 bytes of level data down to 1524. Thomas Jentzsch worked up Huffman coding routines which got that down to 959 bytes*, but the decompression routines took longer which caused jitter when starting some levels. I ended up changing it so that instead of decompressing during Over Scan it would decompress mid-screen. For testing I changed the background color so you could see how long it took:

 

Level 1 - the white scanlines below the horizon is how long the decompression took to run

blogentry-3056-0-75295500-1398310368_thumb.jpg

 

Level 11 - longer

blogentry-3056-0-62232300-1398310374_thumb.jpg

 

Level 31 - longest

blogentry-3056-0-58666200-1398310381_thumb.jpg

 

ROM

draconian_20140423.bin

 

Source

Draconian_20140423.zip

 

*The savings were used to add the branch object and additional unique levels (some levels reuse previous layouts).

 

Edit: Station Collision Images

blogentry-3056-0-50467600-1398349030_thumb.gif

7 Comments


Recommended Comments

I'm glad too :D

 

Yeah, forgot to mention that when I mentioned the stations. I only have 1x sprite collision routines in place at the moment. I'd removed the 2x logic from the routine I copied over from Frantic as I realized they could be better optimized for performance. I plan to drop the rewritten routine back into Frantic with the hopes that it decreases the occurrence of jitter/roll. I don't have any 4x collision logic so that'll be written from scratch. It'll also be obtaining shape data from RAM instead of ROM, which changes the routine a little bit.

 

If I'm not mistaken, hitting a support on a station does not cause any damage - you have to hit the pod or center opening for that. As such I'll be making 2 images on the fly for each station. I currently make the display image, will add another for collision processing. Examples of station collision images have been added to the blog entry.

 

Hmm - got to thinking that might not work as is as I think hitting the support causes the shot to go away. If I test collisions using that example the shot will end up flying thru the station, possibly hitting another part of the station or something on the other side of the station.

Link to comment

Yeah, I imagine we're going to have multiple iterations for the stations.

 

I think I'm going to implement a few more things then start posting the periodic build in the homebrew forum:

  • deadly explosions (in place as of last night)
  • can destroy the ships in formation (they'll still fly the up/right cycle)
  • can shoot stations. Pod remove will probably not be accurate for the initial homebrew forum post (ie: topmost pod hit, but the one next to it got destroyed).

Hopefully that'll get posted tomorrow. If not, it'll be sometime next week as I'm keeping my Sundays code free.

Link to comment

Incidentally, collisions with explosions are fatal in the arcade game (not sure that applies to asteroid explosions though).

Played a little Bosconian last night via MAME on my iPad. Asteroid explosions are not deadly. Their explosions are also smaller and faster than the mine explosions. Asteroid explosion sequence is also used for station pod explosions.

Link to comment

Also, the center pod opens and closes, and is only vulnerable when open. Haven't worked out graphically how to show that yet.

 

Just wrapped up my yardwork and had some ideas on this while trudging along behind the mower:

  • Since the stations are drawn using 4X sprites, always open the middle pod in the up/down direction so it can be gradually opened.
  • If the middle pod is open, draw the "energy" thing by using the other missile (ie: station drawn with player0, energy drawn with missile1). We can't control the color of the missile, so that gives it a chance that the "energy" thing will be a different color than the station.
  • Draw the energy thing by alternating between 2 missile shapes.
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...