Decompile 2 functions in Source/Contents/Effects/EffectPrimitiveMotion.cpp, Source/Contents/Effects/EffectParticle.h
Batch #1992 by ragnarok-clanker: 2 byte-identical, 0 confirmed by peer review. - fn_19966 EffectParticle::FollowMasterAndAdvance: byte-identical - fn_19952 EffectParticle::FollowMasterAndTickSlots: byte-identical Merged automatically: every function is byte-identical to the original.
This commit is contained in:
parent
7e716e8506
commit
b7fce8bdd9
2 changed files with 36 additions and 0 deletions
|
|
@ -44,6 +44,9 @@ struct EffectParticle : CRenderObject {
|
|||
void PrimWaterFall();
|
||||
|
||||
bool AdvanceFrame();
|
||||
bool FollowMasterAndAdvance();
|
||||
void FollowMasterAndTickSlots();
|
||||
void FollowMasterAndTickSlots2();
|
||||
void UpdateRecords();
|
||||
|
||||
/* 0138 */ EffectPrimitiveState state;
|
||||
|
|
|
|||
|
|
@ -2266,3 +2266,36 @@ void EffectParticle::UpdateRecords() {
|
|||
const std::uint32_t blue = static_cast<unsigned char>(this->state.blue);
|
||||
first.color = (static_cast<std::uint32_t>(static_cast<int>(this->state.alpha)) << 24) | (red << 16) | (green << 8) | blue;
|
||||
}
|
||||
|
||||
// INLINED
|
||||
static void FollowMaster(EffectParticle& particle) {
|
||||
const AttachedEffect* master = particle.state.master;
|
||||
particle.render.position.x = master->render.position.x;
|
||||
particle.render.position.y = master->render.position.y;
|
||||
particle.render.position.z = master->render.position.z;
|
||||
}
|
||||
|
||||
// INLINED
|
||||
static void TickLiveSlots(EffectPrimitiveSlot* slots) {
|
||||
for (int index = 0; index < 4; ++index) {
|
||||
if (slots[index].life == 1) {
|
||||
++slots[index].process;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// OFFSET: 0x00BEB020
|
||||
// FUNCTION: fn_19966
|
||||
bool EffectParticle::FollowMasterAndAdvance() {
|
||||
FollowMaster(*this);
|
||||
return this->AdvanceFrame();
|
||||
}
|
||||
|
||||
// OFFSET: 0x00BE9560
|
||||
// FUNCTION: fn_19952
|
||||
void EffectParticle::FollowMasterAndTickSlots() {
|
||||
FollowMaster(*this);
|
||||
TickLiveSlots(this->state.slots);
|
||||
}
|
||||
|
||||
// OFFSET: 0x00BE8770
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue