MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / renderLightSources

Method renderLightSources

source/game/StarProjectile.cpp:382–388  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

380}
381
382void Projectile::renderLightSources(RenderCallback* renderCallback) {
383 for (auto renderable : m_pendingRenderables) {
384 if (renderable.is<LightSource>())
385 renderCallback->addLightSource(renderable.get<LightSource>());
386 }
387 renderCallback->addLightSource({position(), m_config->lightColor.toRgbF(), m_config->lightType, 0.0f, 0.0f, 0.0f});
388}
389
390Maybe<Json> Projectile::receiveMessage(ConnectionId sendingConnection, String const& message, JsonArray const& args) {
391 return m_scriptComponent.handleMessage(message, sendingConnection == world()->connection(), args);

Callers

nothing calls this directly

Calls 2

addLightSourceMethod · 0.80
toRgbFMethod · 0.80

Tested by

no test coverage detected