Maverick air-to-ground missiles update
Maverick air-to-ground missiles
Harriers can take a payload of Sidewinder air-to-air and Maverick air-to-ground missiles. I thought it would be interesting to add more weapons to the game.
When an enemy ground sprite is scrolled onto the screen its coordinates are tracked. If a new enemy appears on the screen, the previous coordinates are dropped in favour of the new coordinates. If the player presses left and fire at the same time, a maverick missile is launched. No new enemies will be tracked as long as this missile remains active. Once the missile is far enough away from the player, I update its status to activate the guidance system. I imported a function from Mimo’s Quest that tests two sets of coordinates and produces an eight point direction finder. This number is then used to call a function in a table that moves the missile in the direction of the enemy sprite, specifying which sprite to display for the missile. Once the missile reaches its target it explodes as normal.
In order to make guided missiles, I had to make a setting that breaks the link between the player height and the missile height. This also makes the game a little more like your average shoot em up, although the player can still enable the feature if they want, so they can ‘guide’ their own missile manually in flight.
Files
Get Harrier Attack Reloaded
Harrier Attack Reloaded
A Plus adaption of the classic Amstrad shoot-em-up game
Status | Released |
Author | CP Soft |
Genre | Shooter |
Tags | harrier-attack |
More posts
- Armour health meter and smooth scrolling7 days ago
- Contrails and bugfixes37 days ago
- Bug fix on redefining keys51 days ago
- CDT (cassette tape) edition released65 days ago
- DSK edition for 464+/6128+ released76 days ago
- Fixed graphical glitch on sprites on real hardware80 days ago
- Fixed stack bug82 days ago
Leave a comment
Log in with itch.io to leave a comment.