CRainSplashGenerator: Dehardcode line vector size in constructor

We can query the capacity instead.
This commit is contained in:
Lioncash 2020-04-01 00:27:53 -04:00
parent 254a96313a
commit da75543c76
1 changed files with 2 additions and 1 deletions

View File

@ -75,8 +75,9 @@ CRainSplashGenerator::SSplashLine::SSplashLine(boo::IGraphicsDataFactory::Contex
: m_renderer(ctx, CLineRenderer::EPrimitiveMode::LineStrip, 3, nullptr, false) {}
CRainSplashGenerator::SRainSplash::SRainSplash(boo::IGraphicsDataFactory::Context& ctx) {
for (int i = 0; i < 4; ++i)
for (size_t i = 0; i < x0_lines.capacity(); ++i) {
x0_lines.emplace_back(ctx);
}
}
void CRainSplashGenerator::SSplashLine::Update(float dt, CStateManager& mgr) {