diff options
author | JAROWMR <jarorutjes07@gmail.com> | 2024-12-16 21:17:03 +0100 |
---|---|---|
committer | JAROWMR <jarorutjes07@gmail.com> | 2024-12-16 21:17:03 +0100 |
commit | cfbfef8deb9e278ad9a9023bda36fd3aa3f17373 (patch) | |
tree | a5a4ed0ddbe735638979b0457c81941d2ac8234a /src/crepe/api/ParticleEmitter.cpp | |
parent | 16f3aa77cfbfd3327a50a3f11f27e7d7dd303026 (diff) | |
parent | 20d19e3c714d3e8ca3e35c170c07c563ecc719bb (diff) |
Merge branch 'jaro/particle-system-improvement' of github.com:lonkaars/crepe into jaro/collision-system-handeling
Diffstat (limited to 'src/crepe/api/ParticleEmitter.cpp')
-rw-r--r-- | src/crepe/api/ParticleEmitter.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/crepe/api/ParticleEmitter.cpp b/src/crepe/api/ParticleEmitter.cpp index 90b77a0..4f54bbd 100644 --- a/src/crepe/api/ParticleEmitter.cpp +++ b/src/crepe/api/ParticleEmitter.cpp @@ -1,11 +1,14 @@ #include "ParticleEmitter.h" +#include "api/Sprite.h" using namespace crepe; -ParticleEmitter::ParticleEmitter(game_object_id_t game_object_id, const Data & data) +ParticleEmitter::ParticleEmitter(game_object_id_t game_object_id, const Sprite & sprite, + const Data & data) : Component(game_object_id), + sprite(sprite), data(data) { for (size_t i = 0; i < this->data.max_particles; i++) { - this->data.particles.emplace_back(); + this->particles.emplace_back(); } } |