diff options
author | Matthew Kosarek <mattkae@protonmail.com> | 2021-10-14 07:39:38 -0400 |
---|---|---|
committer | Matthew Kosarek <mattkae@protonmail.com> | 2021-10-14 07:39:38 -0400 |
commit | 9d590665caa9f282e4a7365b10e1ba8a85e384d9 (patch) | |
tree | 508ff160936cf9a2bed170f93e8392147715121b /themes/LeafParticleRender.h | |
parent | f6fe40e125a99bd3ea47c476f6a95b6e820a51aa (diff) |
Leaves can now fall off of the tree
Diffstat (limited to 'themes/LeafParticleRender.h')
-rw-r--r-- | themes/LeafParticleRender.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/themes/LeafParticleRender.h b/themes/LeafParticleRender.h index c305363..0627322 100644 --- a/themes/LeafParticleRender.h +++ b/themes/LeafParticleRender.h @@ -15,11 +15,23 @@ struct LeafParticleUpdateData { Renderer2dVertex* vertexToFollow = NULL; Vector4 color = Vector4(1.f, 0.f, 0.f, 0.f); float32 scale = 1.f; - Vector2 fallDirection; + + float32 timeFallingSeconds = 0.f; + bool isFalling = false; + int32 fallChance = -1; + Vector2 fallPosition; + float32 fallVerticalVelocity; + float32 fallHorizontalFrequency; + + bool onGround = false; + Renderer2dVertex* vertexPtr = NULL; }; struct LeafParticleRender { + float32 elapsedTimeSeconds = 0.5; + float32 fallIntervalSeconds = 1.f; + // Update data int32 numLeaves = 0; |