Jump to content

TROGBlog

  • entries
    47
  • comments
    219
  • views
    125,210

Stellar Fortress v0.20


TROGDOR

1,438 views

To placate my critics, here is another update for Stellar Fortress, as promised.

 

sf20kk4.png

I'm hit! I'm hit!

 

sf20.zip

New Features:

sf20.asm 1/10/08

- Major improvements to shield collision detection. Now uses a combination of coordinate checking and collision registers. Allows player to fly closer to the cannon, making the game feel less claustrophobic.

- Added 16-bit trig table for linear shots. This is now used for the Plasma ball. It imitates 16-bit motion with proper trig ratios, without the RAM overhead. Allows Plasma Cannon to be fired in 64 directions.

- Added ship-to-enemy collision detection. Ship can now be destroyed by missile, Plasma ball, and the Plasma Cannon.

- Plasma ball expands as it moves away from the cannon.

- Added animated ship explosion with color cycling. Thanks to Nathan for providing the original explosion. I had to stretch it a couple lines to match the size of the ship, but otherwise I like how it turned out.

- Lowered pitch of shield bounce sound. Sounds less rubbery.

- Added explosion sound and warp-in sound.

- Ship count is reduced when a ship is destroyed.

- Fixed two bugs that have been around for literally years. The first bug was visual artifacts on the player ship when the game first started. This was caused by an incorrectly initialized graphics vector. The other bug was a volume reset in the thrust code that was affecting all sound effects on audio voice 1. All sound effects now sound more crisp, particularly the player's Ion Cannon, and the shield bounce sound.

 

To Do:

- Add artificial intelligence to the evil forces of the Galactic Trade Union. Add a tracker for the missile, and targeting for the Plasma Cannon.

- Rewrite the kernel (again.) It currently contains suckage. Should handle the screen in sections, rather than trying to do everything in one kernel. This will open up cycles for a snazzy new game feature.

- Change the player shots to use the new trig engine. This will open up more RAM. The current code uses 6 bytes for each player shot: 2 for a 16-bit X position, 2 for a 16-bit Y position, plus one for direction and one for distance. Now I only have to use one byte for X and one for Y, and direction and distance can be combined into a single 2-nibble byte. This will free up another 6 bytes of precious RAM.

- Clean up the priorities and channel sharing on the sound effects, especially the thrust sound. The trust is interfering with the bounce and warp-in sounds.

- Stop making blog posts at 2 in the morning on a work night.

 

Known Issues:

- The player shot to shield collision detection is a little off. Gotta fix that.

 

Development Notes:

For the record, I am not anti-union. I understand that not all galactic trade unions are evil.

4 Comments


Recommended Comments

Are you forgetting how our grandfather toiled under the yoke of Marathon steel with the Arizona sun above and the blinding arc of a welder below? If it wasn't for the galactic steel workers' union, he never would have been able to afford that above ground pool we frolicked in or the majestic golden van of our youth.

 

I think your beef is with the galactic trade cartel, a genuinely malignant organization bent on cornering the market on solar panels.

Link to comment

The player ship explosion sound reminds me a lot of the crash noise on the Odyssey2.

 

The game generally looks pretty good, though if I might offer a couple of suggestions...

 

-1- I don't know how many segments there are in the shields, but it might be nice to have the segments be grouped into clumps (larger clumps on the outside).

 

-2- If you could make one of the rings rotate opposite the others, that would be nice.

 

Star Castle was a classic, so it will be nice if it can come to the 2600.

Link to comment

If you absolutely have a need for three more bits of RAM maybe you'd be interested in this:

http://www.atariage.com/forums/index.php?s...5226&st=375

 

Question to the hardware gurus:

The undefined bits in SWCHB (2,4, and 5)...are these used at all by either console? In the update, I was attempting to EOR bit 2 (in the ram copy "DifSw") to signify a board reset...which looks to work OK in emulation.

I'm not a hardware guru but these bits are not used by either console. You can use them for RAM if you would like. Before doing so though you must set the bits data direction.

 

   lda #%00110100
  sta SWBCNT

Link to comment
The player ship explosion sound reminds me a lot of the crash noise on the Odyssey2.

 

The game generally looks pretty good, though if I might offer a couple of suggestions...

 

-1- I don't know how many segments there are in the shields, but it might be nice to have the segments be grouped into clumps (larger clumps on the outside).

 

-2- If you could make one of the rings rotate opposite the others, that would be nice.

 

Star Castle was a classic, so it will be nice if it can come to the 2600.

 

The ship explosion sound is standard Atari fare. Just a low frequency white noise with a decreshendo. The explosion for the cannon will be more involved, both in sound and graphics. I'm starting to code up an effect that will make the remaining shield segments implode into the cannon before it explodes, similar to the original Star Castle.

 

There will be 6 shield rings in the final game. 3 will rotate clockwise and 3 will rotate counter-clockwise, alternating every other ring. If you look in the source, you'll see that about 300 bytes of ROM was used to hardwire the logic for the clockwise shield rotation. It doesn't use a loop. The diagonal movement of the bits is too complicated for looping. The whole thing is unwrapped, and it took several hours to code it up.

 

Version 0.16 used square rings, so it was easier to implement in a loop, but it only supported 5 rings because of the extra 28 byte RAM buffer that was necessary.

 

The game level will dictate how many rings are activated. On early levels, there will only be two or three shield rings. On the highest levels, you'll have to blast through all 6 rings. The game will get progressively harder with each level, to keep the player on his toes. Difficulty variations will include the speed of the cannon rotation, the speed of plasma cannon shots, the speed of the missiles, the speed of the shield rotation, the number of rings in the shield, and another feature that will be disclosed soon. Also, on the highest levels, colliding with the shield will be fatal, rather than just causing the ship to bounce off.

 

If you absolutely have a need for three more bits of RAM maybe you'd be interested in this:

http://www.atariage.com/forums/index.php?s...5226&st=375

 

Question to the hardware gurus:

The undefined bits in SWCHB (2,4, and 5)...are these used at all by either console? In the update, I was attempting to EOR bit 2 (in the ram copy "DifSw") to signify a board reset...which looks to work OK in emulation.

I'm not a hardware guru but these bits are not used by either console. You can use them for RAM if you would like. Before doing so though you must set the bits data direction.

 

   lda #%00110100
  sta SWBCNT

 

Thanks for the info, but I probably won't get that squeezed for RAM. If I really need the extra RAM, there are at least 10 more bytes that I can wring out of the current implementation. It will just mean a more efficient use of temp variables, and some nibble encoding. I'm also trying to remove all subroutines from the code, or at least limit the number of nested subroutines to one level, so I won't have to reserve more than 4 bytes for the stack.

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