Ticket #44 (new enhancement)
Asteroids
| Reported by: | knowknowledge | Owned by: | |
|---|---|---|---|
| Priority: | minor | Milestone: | 0.6.0 |
| Component: | Source | Version: | |
| Keywords: | Cc: |
Description
Asteroids are just rocks that float around the Epiar universe.
They're the simplest form of sprite there is, and thus very easy to implement. You can pull the asteroid art off 0.6.0 or find a new one: you'll probably need to build it using our .ani format and perhaps augment the sprite class to support using Animation in option to Image as a sprite's visage.
You'll also need to establish a form of asteroid field generation, e.g. "field at 50, 50, 0.8 density, expands 1000 in all directions" and then implement random asteroid creation in that area. It should be noted that such an effect should be gradual, e.g. if I fly in from -1000, I should see one or two asteroids and have the density increase until I hit 50,50, and then drop off naturally by +1000 (x coord).
Some undecided Asteroid features:
Should they collide with ships?
Should they absorb weapon shots? (None, Some, or All?)
Should they be destructable?
If Asteroids can be hit by weapons, then that means that they will become 'terrain' during dogfights.
If Asteroids can be hit, but do not collide with ships, then some ships might be able to 'hide' by staying in the shadow of a larger Asteroid.
Change History
comment:2 Changed 22 months ago by knowknowledge
I've implemented, but turned off, a start to this ticket. This will create asteroids near planets that wander.
Unfortunately, they don't stay near the planets or disappear eventually, so they just clog up the universe and slow things down.
comment:3 Changed 22 months ago by chris
Any chance you could just delete asteroids that are more than 3 screens away? We don't have to maintain the real field unless we get some kind of multiplayer in the future.
comment:4 Changed 21 months ago by knowknowledge
I'm sure it would be possible, but that's not the way that we manage any of the other sprites so we'll have to come up with a new system; all other sprites exist even when the player isn't there to see them.
When should we create the asteroids?
We can easily check if the asteroid is offscreen for too long or if it is too far from the player.