#include <space_map.h>
Public Member Functions | |
| void | reset () |
| void | reseed (uint32 seed) |
| void | advance () |
Static Public Member Functions | |
| static bool | withinView (int x, int y) |
The panning warp starfield drawn in the first-person cockpit view - SPACE.EXE's setupStars / advanceStarfield. Purely visual (not saved)
| void Ultima::Ultima1::Data::SpaceStarfield::reset | ( | ) |
Fresh random stars, centre and pan back to their defaults (setupStars)
| void Ultima::Ultima1::Data::SpaceStarfield::reseed | ( | uint32 | seed | ) |
Replaces every star with new ones rolled from a seed. The same seed always gives the same stars, and the same ones replacing them as they leave the view, so a run of advance() calls can be replayed exactly
| void Ultima::Ultima1::Data::SpaceStarfield::advance | ( | ) |
One frame: every star drifts further from the centre (respawning at an edge once it leaves the viewport), then the centre pans by the current pan velocity, which is zeroed on hitting a viewport edge (advanceStarfield, normal-cruise path)
|
inlinestatic |
True if a screen point is inside the cockpit viewport (starWithinView)