From 7cab3cea2035845fa8e6357ad50d4c91e6b9333d Mon Sep 17 00:00:00 2001 From: IbanPlay <56191483+IbanPlay@users.noreply.github.com> Date: Thu, 6 Jan 2022 19:06:24 +0100 Subject: [PATCH] Accidental int division! --- Particles/GenericSparkle.cs | 2 ++ Particles/Particle.cs | 2 +- Particles/Sparkle.png | Bin 0 -> 707 bytes Particles/ThanatosSmokeParticle.cs | 2 +- 4 files changed, 4 insertions(+), 2 deletions(-) create mode 100644 Particles/Sparkle.png diff --git a/Particles/GenericSparkle.cs b/Particles/GenericSparkle.cs index a83c687b6d..7e8b44a156 100644 --- a/Particles/GenericSparkle.cs +++ b/Particles/GenericSparkle.cs @@ -10,6 +10,8 @@ namespace CalamityMod.Particles { public class GenericSparkle : Particle { + public override string Texture => "CalamityMod/Particles/Sparkle"; + public GenericSparkle(Vector2 position, Vector2 velocity, Color color, float scale, int lifeTime, float rotationSpeed = 1f) { Position = position; diff --git a/Particles/Particle.cs b/Particles/Particle.cs index 70bfe50976..ee9467d316 100644 --- a/Particles/Particle.cs +++ b/Particles/Particle.cs @@ -27,7 +27,7 @@ namespace CalamityMod.Particles /// public int Lifetime = 0; - public float LifetimeCompletion => Lifetime != 0 ? Time / Lifetime : 0; + public float LifetimeCompletion => Lifetime != 0 ? Time / (float)Lifetime : 0; /// /// The offset of the particle in relation to the origin of the set it belongs to. This is only used in the context of a Particle Set diff --git a/Particles/Sparkle.png b/Particles/Sparkle.png new file mode 100644 index 0000000000000000000000000000000000000000..79930b6e9941d798bfd88216c66f9d6f9e005eb2 GIT binary patch literal 707 zcmV;!0zCbRP)Px%eMv+?R9J=0n7wWjK@i7(dp_HIB~cnW+JHcY4hf0E&%v8epeUl?O?V25AR!^q z0RlltJQ1)!g3f?fiCj_QQ5`6z{#$V*&J~SHMCV=bZ1- zXORiu^z9|!rF5b9w%z$d7>N+Qn(pL$69}hL2k05w)*uRC0PIK?Y!M=gH_ivDXUQfI z17Hr6(u3TN%8YN~R9pe}<$PbZDH#!I9SO7Sya0OqnUp=f_qF!t2Vta7ipGerM~p~` z+3(t6D+n{HlC(?i0hfVm(tD&`w5)yCC}%m*;)4Ph%E=CJA9y5N)Gr8Ix0hZu^&7YM zq9s6_?+9=}82MQCvFZo1_epv4SBZYhHRnMcDDDG8Lga1&w}IVSyIsBaz&islM+ckr zuXo;i?_BLvw8fL=c&O)lz%9a(JX|xlBj7vm33w|i!72SDkZ^8)b-@8EhA^XYr1@UTd3>JA-suNW z&h;)vVXFF^ur#NbW!FVEx#-5rZAH5DX2~WHj