benilla-re systems structs docs

CRibbonEmitter

struct · models · 360 bytes

Meaning
Holds a ribbon emitter: its edge ring, node frames, texture cell, materials, colour and heights
Confidence
verified, proof one
Finding
models/ribbons#ribbon-ring

Finding: Ribbon ring in models: ribbons

A ribbon keeps its edges in a ring of n = ceil(ceil(rate)·L) + 2 slots, with rate the record's edges per second (+0x94) and L its lifespan (+0x98) raised to at least 0.25. Each slot holds an age and a 40-byte vertex pair, bottom then top, each a position and texture coordinates; edges live from the tail to the head, and the head slot holds the uncommitted edge at the bone. The index array holds i mod 2n for i below 4n, so a draw of the live run reads straight through the wrap. A new ribbon starts hidden, 10 above and 10 below, with no gravity.

The derivation is in the doc.

Fields 28

offsetsizetypenamemeaningconfidencefinding
0x00084uint32_tm_capacityHolds the ring capacity in edgesverified, proof onemodels/ribbons#ribbon-ring
0x000c4float *m_agesHolds each ring slot edge ageverified, proof onemodels/ribbons#edge-curve
0x00144uint32_tm_headHolds the head slot, the uncommitted edge at the boneverified, proof onemodels/ribbons#ribbon-ring
0x00184uint32_tm_tailHolds the oldest live slotverified, proof onemodels/ribbons#ribbon-ring
0x001c4floatm_carryHolds the fraction of an edge carried to the next updateverified, proof onemodels/ribbons#ribbon-update
0x002012float[3]m_lastPositionHolds the last node positionverified, proof onemodels/ribbons#node-frame
0x003c4uint32_tm_vertexCountHolds the number of ring vertices, two per slotverified, proof onemodels/ribbons#ribbon-frame-change
0x00404void *m_verticesHolds the ring vertices, 20 bytes each with the position firstverified, proof onemodels/ribbons#ribbon-frame-change
0x00584floatm_inverseLifespanHolds 1 over the lifespanverified, proof onemodels/ribbons#ribbon-ring
0x005c8float[2]m_cellSizeHolds the cell width in u and height in vverified, proof onemodels/ribbons#ribbon-texture-cells
0x006c16float[4]m_cellHolds the cell v0, u0, v1 and u1verified, proof onemodels/ribbons#ribbon-texture-cells
0x007c12float[3]m_lastUpHolds the last node up axis, matrix row 1verified, proof onemodels/ribbons#node-frame
0x008812float[3]m_upHolds the current node up axisverified, proof onemodels/ribbons#node-frame
0x009412float[3]m_lastForwardHolds the last node forward axis, matrix row 2verified, proof onemodels/ribbons#node-frame
0x00a012float[3]m_forwardHolds the current node forward axisverified, proof onemodels/ribbons#node-frame
0x00ac24float[6]m_tangentsHolds the last and current node tangentsverified, proof onemodels/ribbons#node-frame
0x00c448float[12]m_edgeEndsHolds the last and current bottoms, then the last and current topsverified, proof onemodels/ribbons#node-frame
0x00f44floatm_rateHolds the edges per second, rounded upverified, proof onemodels/ribbons#ribbon-ring
0x00f84floatm_lifespanHolds the lifespan, at least 0.25verified, proof onemodels/ribbons#ribbon-ring
0x012c4uint32_tm_colorHolds the colour word every vertex takesverified, proof onemodels/ribbons#ribbon-draw
0x013016float[4]m_rectHolds the texture rectangleverified, proof onemodels/ribbons#ribbon-texture-cells
0x01408uint32_t[2]m_gridHolds the texture grid rows and columnsverified, proof onemodels/ribbons#ribbon-texture-cells
0x01484uint32_tm_flagsHolds the flags: 1 started, 2 initialized, 4 visible, 8 updatedverified, proof onemodels/ribbons#ribbon-update
0x014c12float[3]m_positionHolds the current node positionverified, proof onemodels/ribbons#node-frame
0x01584uint32_tm_textureSlotHolds the texture cell indexverified, proof onemodels/ribbons#ribbon-texture-cells
0x015c4floatm_aboveHolds the height above the bone, 10 by defaultverified, proof onemodels/ribbons#node-frame
0x01604floatm_belowHolds the depth below the bone, 10 by defaultverified, proof onemodels/ribbons#node-frame
0x01644floatm_gravityHolds the gravityverified, proof onemodels/ribbons#ribbon-update