70 return mSortKey > other.mSortKey;
121 void *
operator new(
size_t nSize) {
122 return PoolMemAlloc(
static_cast<int>(nSize),
"Arena", 0);
130 void operator delete(
void *pBlock) {
324 std::vector<Section> mSections;
325 std::list<Sort> mSorts;
Stream of raw bytes, the base of the memory, file, and network streams.
Definition binstream.h:22
Text output stream.
Definition prnstream.h:16
RndAnimatable()
Construct an animatable at frame 0 without children or filters.
Definition rndanimatable.h:600
float GetSortKey() const
Definition rndarena.h:74
RndView * GetView() const
Definition rndarena.h:84
void SetView(RndView *pView)
Definition rndarena.h:89
void SetSortKey(float fSortKey)
Definition rndarena.h:79
bool operator<(const Sort &other) const
Order the entries farthest along first.
Definition rndarena.h:69
Sort()
Construct an entry without a view.
Definition rndarena.h:60
void DumpText(PrnStream &stream) override
Write a description of the track and its bases.
void Load(BinStream &stream) override
Read what Save() wrote, or an earlier version of it.
int SetFrameSelf(float fFrame) override
Place and show the view of each section for the filtered frame, then sort the drawing order.
void ReleaseRefs()
Drop the references on the views and empty the drawing order.
static int sLoadRev
The version Load() read last.
Definition rndarena.h:274
static RndObject * New(const char *pszName)
Create a track.
Definition rndarena.h:250
void Replace(RndObject *pFrom, RndObject *pTo) override
Replace a view with another object.
int DrawShowing() override
Draw the views in the drawing order.
~RndArena() override
Drop the references on the views.
void UpdateSection(Section §ion)
Place a section's view for the filtered frame and show it while the frame is in its window.
void Collide(const Segment &segment, std::list< Collision > &collisions) override
Add what each showing view strikes to a list.
const char * ClassName() const override
Report the class name.
Definition rndarena.h:217
int UpdateWorldXfm(RndTransformable *pParent, int bForce) override
Update the world transform, then that of every showing view.
static const char * sClassName
The class name a .rnd file writes, Arena.
Definition rndarena.h:260
void SetSectionLoop(Section §ion, int nLoop)
Move a teleporting section's view on by the loop distance for each loop between its loop and a new on...
static int sRev
The format version Save() writes and Load() accepts.
Definition rndarena.h:267
void Save(BinStream &stream) override
Write the track and its bases.
RndArena(const char *pszName)
Construct an empty track that loops every 1000 frames over no distance.
void Copy(const RndObject *pSource, int nFlags) override
Copy another track and its bases.
void AcquireRefs()
Take a reference on each view and give the drawing order one entry per section.
virtual void Collide(const Segment &segment, std::list< Collision > &collisions)
Test a segment against the collideable and add what it strikes to a list.
RndCollideable()
Construct a collideable without children.
Definition rndcollideable.h:34
RndDrawable()
Construct a showing drawable without a highlight or children.
Definition rnddrawable.h:23
RndObject(const char *pszName)
Construct an object and register it under a name.
View that shows the children of another view, its children owner, under its own transform and frame.
Definition rndview.h:27
void * PoolMemAlloc(int nSize, const char *pszTag, int nAlign)
Allocate a block from the pool heaps and bill it to a tag.
void PoolMemFree(void *pBlock)
Return a block PoolMemAlloc() handed out to the pool heap that owns it.
BinStream & operator>>(BinStream &stream, RndArena::Section §ion)
Read a section the section writer wrote, or an earlier version of it.
PrnStream & operator<<(PrnStream &stream, const RndArena::Section §ion)
Write a section's view, frame, loop, window, and flags.
One view of the track and the window it is shown in.
Definition rndarena.h:38
RndView * mView
Definition rndarena.h:44
int mSortStart
Definition rndarena.h:48
float mDelta
Definition rndarena.h:46
Section()
Construct a section without a view that teleports and sorts by its start.
Definition rndarena.h:40
float mFrame
Definition rndarena.h:45
int mLoop
Definition rndarena.h:49
int mTeleport
Definition rndarena.h:47
Two points that fix a line or a segment.
Definition plane.h:39
Three-component vector, padded to a PlayStation 2 quadword.
Definition vector3.h:14