2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-11 13:07:42 +00:00

General: Pass std::nullopt to CAnimData::Render instead of {}

Prevents some implementations (libstdc++ and libc++) from completely zeroing out the underlying
buffer and instead sets a single byte flag.

Eliminates unnecessary memsets.
This commit is contained in:
Lioncash
2020-04-05 08:15:45 -04:00
parent 786634e181
commit f77fb2089b
5 changed files with 11 additions and 11 deletions

View File

@@ -512,7 +512,7 @@ void CGunWeapon::DrawHologram(const CStateManager& mgr, const zeus::CTransform&
// g_Renderer->SetAmbientColor(zeus::skWhite);
CSkinnedModel& model = const_cast<CSkinnedModel&>(*x60_holoModelData->GetAnimationData()->GetModelData());
model.GetModelInst()->ActivateLights({CLight::BuildLocalAmbient({}, zeus::skWhite)});
const_cast<CGunWeapon*>(this)->x10_solidModelData->GetAnimationData()->Render(model, flags, {}, nullptr);
const_cast<CGunWeapon*>(this)->x10_solidModelData->GetAnimationData()->Render(model, flags, std::nullopt, nullptr);
// g_Renderer->SetAmbientColor(zeus::skWhite);
// CGraphics::DisableAllLights();
}