diff options
author | heavydemon21 <nielsstunnebrink1@gmail.com> | 2024-12-19 13:58:58 +0100 |
---|---|---|
committer | heavydemon21 <nielsstunnebrink1@gmail.com> | 2024-12-19 13:58:58 +0100 |
commit | b5c4879189a8ff55434c8c04c14163dfda83de65 (patch) | |
tree | 17595782d04038818f7ed4f6bb2199949ebd30a0 /src/crepe/system/RenderSystem.cpp | |
parent | ebe2fcfce52d9a303c5fa19d79554e20ac7f0bac (diff) | |
parent | 794efc4ef7a44b190a4d9ecc2dd84a66c62ab005 (diff) |
Merge branch 'master' into niels/UI
Diffstat (limited to 'src/crepe/system/RenderSystem.cpp')
-rw-r--r-- | src/crepe/system/RenderSystem.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/crepe/system/RenderSystem.cpp b/src/crepe/system/RenderSystem.cpp index b4b745f..3ec1922 100644 --- a/src/crepe/system/RenderSystem.cpp +++ b/src/crepe/system/RenderSystem.cpp @@ -118,12 +118,13 @@ bool RenderSystem::render_particle(const Sprite & sprite, const Transform & tm){ for (const Particle & p : em.particles) { if (!p.active) continue; + if (p.time_in_life < em.data.begin_lifespan) continue; ctx.draw(SDLContext::RenderContext{ .sprite = sprite, .texture = res, .pos = p.position, - .angle = p.angle, + .angle = p.angle + transform_angle, .scale = tm.scale, }); } |