|
resonance 1.0.1
|
One live particle of a Rnd::ParticleSys. More...
#include <particle.h>

Public Attributes | |
| Color | mCol |
| Colour, labelled "\n\tcol:" in the dump. | |
| Color | mColVel |
| Rate of colour change per frame. | |
| Vector3 | mPos |
| Position. | |
| Vector3 | mPrevPos |
| Position one frame earlier, which the line mode draws from. | |
| Vector3 | mVel |
| Velocity per frame. | |
| Vector3 | mBubbleSize |
| Displacement of the bubble motion, drawn from Rnd::ParticleSys's bubble size range. | |
| float | mBubbleFrequency |
| Angular rate of the bubble motion, drawn from the bubble period range. | |
| float | mBubblePhase |
| Phase of the bubble motion. | |
| float | mSize |
| Extent of the drawn primitive. | |
| float | mDeathFrame |
| Frame this particle is released on. | |
| float | mBirthFrame |
| Frame this particle was allocated on. | |
| Particle * | mPrev |
| Previous live particle, the particle itself at the head of the live list, or null while the particle is free. | |
| Particle * | mNext |
| Next live particle, or null at the end of the list. | |
| int | mReserved7c |
One live particle of a Rnd::ParticleSys.
The structure is not polymorphic and emits no RTTI descriptor. Its member names come from the labels its own dump writes at 0x00526308, "\n\tpos:", "\n\tprevPos:", "\n\tvel:", "\n\tcol:", "\n\tcolVel:", "size:", " deathFrame:", and " birthFrame:". The offsets below are the ones that dump reads, so those members are measured rather than inferred. mPrev and the three bubble members are named from their use by Rnd::ParticleSys instead.
A particle is 0x80 bytes, which the pool vector stride in Rnd::ParticleSys confirms. One word at the end is unrecovered, because no recovered routine reads it.
In line mode Rnd::ParticleSys::UpdateParticles() treats mPrevPos as the first of a run of quadwords and shifts a position history along it, one quadword per unit of line length. A line length above 1 therefore overwrites mVel and the bubble members with older positions.
Live particles form a doubly linked list through mNext and mPrev rather than occupying the pool vector in order, and free particles a singly linked list through mNext. Rnd::PsParticleSys::DrawSpritesDmaKicked() walks the live list, and Rnd::ParticleSys::FreeAllParticles() releases it.
The first two quadwords are the pair the vector unit path uploads, which is why the colour precedes the position. The upload writes half the size into the fourth word of mPos first, because a GS sprite takes a centre and a half extent rather than two corners.
| Color Rnd::Particle::mCol |
Colour, labelled "\n\tcol:" in the dump.
+0x00
| Color Rnd::Particle::mColVel |
Rate of colour change per frame.
+0x10
| Vector3 Rnd::Particle::mPos |
Position.
Its fourth word is overwritten with half of mSize by the vector unit upload.
+0x20
| Vector3 Rnd::Particle::mPrevPos |
Position one frame earlier, which the line mode draws from.
+0x30
| Vector3 Rnd::Particle::mVel |
Velocity per frame.
+0x40
| Vector3 Rnd::Particle::mBubbleSize |
Displacement of the bubble motion, drawn from Rnd::ParticleSys's bubble size range.
Inferred from use, because the particle dump does not read it. +0x50
| float Rnd::Particle::mBubbleFrequency |
Angular rate of the bubble motion, drawn from the bubble period range.
Inferred. +0x60
| float Rnd::Particle::mBubblePhase |
Phase of the bubble motion.
Inferred. +0x64
| float Rnd::Particle::mSize |
Extent of the drawn primitive.
+0x68
| float Rnd::Particle::mDeathFrame |
Frame this particle is released on.
+0x6c
| float Rnd::Particle::mBirthFrame |
Frame this particle was allocated on.
+0x70
| Particle* Rnd::Particle::mPrev |
Previous live particle, the particle itself at the head of the live list, or null while the particle is free.
The particle dump does not read it. The pool routines of Rnd::ParticleSys establish it. +0x74
| Particle* Rnd::Particle::mNext |
Next live particle, or null at the end of the list.
+0x78
| int Rnd::Particle::mReserved7c |