mirror of https://github.com/AxioDL/metaforce.git
CElitePirate/etc: Use prefix increment/decrement
This commit is contained in:
parent
bb7699be46
commit
0c1f4fa738
|
@ -87,7 +87,7 @@ void CBouncyGrenade::CollidedWith(TUniqueId id, const CCollisionInfoList& list,
|
|||
ApplyImpulseWR(impulse, angle);
|
||||
CSfxManager::AddEmitter(x258_data.GetBounceSfx(), GetTranslation(), zeus::skUp, false, false, 0x7f,
|
||||
GetAreaIdAlways());
|
||||
x294_numBounces--;
|
||||
--x294_numBounces;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -341,7 +341,7 @@ void CElitePirate::DoUserAnimEvent(CStateManager& mgr, const CInt32POINode& node
|
|||
case EUserEventType::BecomeShootThrough:
|
||||
if (HasWeakPointHead()) {
|
||||
u32 numCollisionActors = x730_collisionActorMgrHead->GetNumCollisionActors();
|
||||
for (u32 i = 0; i < numCollisionActors; i++) {
|
||||
for (u32 i = 0; i < numCollisionActors; ++i) {
|
||||
const auto& description = x730_collisionActorMgrHead->GetCollisionDescFromIndex(i);
|
||||
if (TCastToPtr<CCollisionActor> actor = mgr.ObjectById(description.GetCollisionActorId())) {
|
||||
actor->AddMaterial(EMaterialTypes::ProjectilePassthrough, mgr);
|
||||
|
|
|
@ -31,7 +31,7 @@ CGrenadeLauncher::CGrenadeLauncher(TUniqueId uid, std::string_view name, const C
|
|||
}
|
||||
GetModelData()->EnableLooping(true);
|
||||
const CPASDatabase& pasDatabase = GetModelData()->GetAnimationData()->GetCharacterInfo().GetPASDatabase();
|
||||
for (int i = 0; i < x3c8_animIds.size(); i++) {
|
||||
for (int i = 0; i < x3c8_animIds.size(); ++i) {
|
||||
const auto result = pasDatabase.FindBestAnimation({22, CPASAnimParm::FromEnum(i)}, -1);
|
||||
x3c8_animIds[i] = result.second;
|
||||
}
|
||||
|
|
|
@ -77,7 +77,7 @@ void CShockWave::Think(float dt, CStateManager& mgr) {
|
|||
x150_ += x154_ * dt;
|
||||
x154_ += dt * x114_data.GetX30();
|
||||
x110_elementGen->SetExternalVar(0, x150_);
|
||||
for (int i = 0; i < x110_elementGen->GetNumActiveChildParticles(); i++) {
|
||||
for (int i = 0; i < x110_elementGen->GetNumActiveChildParticles(); ++i) {
|
||||
auto& particle = static_cast<CElementGen&>(x110_elementGen->GetActiveChildParticle(i));
|
||||
if (particle.Get4CharId() == SBIG('PART')) {
|
||||
particle.SetExternalVar(0, x150_);
|
||||
|
|
Loading…
Reference in New Issue