Saturday, 27 March 2021

March 2021 Cruiser-X Progress Update #2

 27th March 2021

A couple of weeks ago I had left you with where I last left off. It was mainly based on the power ups based system. Now 2 weeks later, more work gets done. Last week, I finished off fixing the SEUCK Title Screen Maker disk, by fixing a bug in one of the example games (Which wasn't the fault of the title screen maker).

This session was mainly based on level setup. Of course I may not have the level graphics yet for level packing, etc. First I have to set up different sound effects for each bullet type the player carries.



I can still start on setting up the level scheme and enemy selection. Last time I managed to get all enemies to appear in order of sequence. Today I have been making a sequence for level 1 of the game. This is now based on the colour scheme table read, and also the alien selection table (based on levels).

After setting up the level routines, the enemies are able to fire bullets but the bullets do not collide into the player. So in order to fix this, a subroutine is programmed in to read the X, Y co-ordinate range of both sprites, and if inside the collision area. The player will die, unless a shield is in place. Then the player respawns.

Well, that looks good, but not really good enough. When shooting at aliens or shooting destructable background characters, The player should score points. A subroutine reads pointers for the player's score, lives and level. Then it copies it to the score panel on screen. I decided to do it this way this time round, because it is a way to prevent the player cheating by freezing the game with the Action Replay cartridge and editing the score/lives value with the screen editor. I cannot code protection routines, plus I cannot be bothered with those anyway :)

The enemy scoring should be based on the enemy sequence value that is used. I set a new table which creates the new score values for each alien, after it has been shot. The values are based as 1-5. Where 500 points is the maximum score which the player can score. Shooting background and collecting power ups also gives the player some points.So can the activation of the player's smart bomb (Which is triggered with the fire button).

The player's lives indicator also needed to be updated to decrement, and when lives have reached 00, the player will lose the game, and GAME OVER commences. Of course even if I was updating score, lives and level pointers (or restarting the game) I would need to update the score panel via a subroutine.  I am happy that it all seems to be working.

Now on to one final problem. The alien spawn sequence is set based on the chosen level, the enemy bullet can now kill the player, the score panel is working. The final problem for today - the aliens are firing too rapidly. How can that be solved? Simple, before randomly selecting the enemy to shoot a bullet. A delay pointer, and delay expiry counter should be set. Adding one of those makes the enemy fire bullets less rapidly. There is a chance I could make a table like with the scoring table, where I could base the enemy firing rate. That might be some time next weekend. We will have to wait and see. But for now, here's an updated video of my work in progress.




Saturday, 13 March 2021

March 2021: Cruiser-X progress Update

 13th March 2021

Yet more activity has been taking place with Cruiser-X 79. Well, what has been going on this time round. For a start off, earlier on this week (Wednesday or Thursday evening I think), I have been working on a few features in the game. The previous week (or two) had alien groups added to the game's code. These are not yet set according to level, but this will happen next week. This week was all about the player's capabilities, and also the enemies.

First of all, I have pictured a situation, where I always used the player's bullet to morph into an explosion and transform the alien animation into a blank sprite. This has been a typical case scenario for my C64 games. However, if I were to create a power up that activated a smart bomb feature. This method of explosion seriously would not look right one bit. There is a solution to this problem. I create some macro routines and pointers in order to check whether an alien is dead or active. If the alien is dead, morph the current alien animation into an explosion and then transform it into a blank sprite. After setting up the code for this feature, the trick worked.

Now it was time for the player to get its revenge on those aliens that try and take over the galaxy. In the game's background, there are three different tiles, which the player can pick up in order to gain power ups. Those are marked as S, M and B. Earlier on last time, I had created a border change to test that the player was able to collect the power up characters. Now I needed to put the power ups feature to reality.

The first thing to is generate a subroutine which tests the player's shield properties. I have to make an indicator that will test the player whether it is carrying a shield or not. If the shield is carried, it should be activated on the player. This indicator has been made by using a colour flash table, and also a couple of pointers. The first pointer does a shield countdown. I made the counter countdown the same amount of time as I did with another game of mine (200 - 0). It is more or less the same mount of time the player has invincibility inside a SEUCK/Sideways SEUCK game (Note that Cruiser-X is not a SEUCK game). I have also placed a subroutine which checks whether the player is dead or not. This is in order to avoid the player exploding while it is still exploding. A similar routine has been made to check that the player is still carrying a shield. This is so that aliens or deadly background cannot do any harm to the player.

Now the player's shield is out the way. I need to do something about the player's bullet. Saul did a few sprites, where there are 5 different bullet types which the player can shoot. A power up table was required. I setup the table, and made some pointers in which triggers the table read each time a new power up has been picked up. The power ups grow in size, and the player can shoot faster.

Next there is one more feature I need to create on the power ups side of things. That is of course the smart bomb feature. The player can pick up the smart bomb feature, but something needs to be done to activate it. I programmed a smart little indication feature by re-designing the HUD's layout. Then I created some subroutines that check for the number of bombs the player can carry. There are 3 bomb icons on the right of the panel, when lit in blue - this indicated no bomb available. However when lit in yellow, this means the bomb is active. 

 How do I get to use the smart bomb feature in the game? Well, first of all, the player's auto-fire had to be removed. For some strange reason I could not read the space bar key by checking the value of $DC01 as #$EF no more. There must have been something in the code blocking it. Instead, I had a brain wave. Since the success of my smart bomb feature in Border Blast 3, I thought that I should give it a blast with this game. I created a hold fire pointer, and made it count up to 16. If the counter times out, the smart bomb gets activated, but how does that happen?. I cheated a little with this method by automatically making all of the enemies pointers to reset the animation to 0 for explosion and trigger the enemy is dead function.

That's the power ups. What next? Well, the player can shoot and blow aliens up with one shot. What about the aliens? They can move about, but for some reason, they cannot attempt to blast the player?. Well, I think it would be fair if they can be trigger happy as well as the player. I create a few subroutines that trigger the enemies to fire and select the enemy to fire the bullets.  Unfortunately there are a few problems. The bullet just keeps on firing from the same alien and sometimes the bullet appears before the aliens enter the screen. A solution to this problem. I set boundaries where the bullets cannot be fired. However the same aliens are still firing until out of the screen. How do I solve this? Easy, a random alien select table, and death check routine. If the alien is dead, it should not shoot, and also the same alien object should not fire. Other aliens should also. I set a few more check routines, to ensure the aliens are alive and shoot. The trick worked. No there are no problems with the alien firing.

I'm nearly done for this week on this project, but before I do, there is just one more feature I would like to add into the game, before I update the GitHub with the newer source. I want to make the background flash. Also sort out the player level complete sequence. The player should fly to the middle and move upwards out of the screen, and "Well Done" should pop on to the screen. Also the smart bomb feature should flash. I added a flash table, and linked it to the raster split that triggers the game's background colour. I linked it with the smart bomb count down timer and the feature worked.

Progress is shaping up quite nicely. I'm pleased with the result so far. Next week, I will be working on the level setup code and select the aliens and background colour schemes  for those particular levels. 




2023 at a glance

2024 is here, and 2023 has been a really quiet year on the production front due to everything that had gone back to normality. The year has ...