HeavenStudio/Assets/Scripts/Util/ParticleSystemHelpers.cs

22 lines
693 B
C#
Raw Normal View History

See Saw (#423) * Basic Set Up * See Saw - Init, Rod Anims * Got some basic code down * Got the basics down * The man won't jump now unless he is ready! * High jumps added * Fixed a bug * See Saw - Base Animation Stuff * See Saw - The Hard Animations fuck fuck fuc, fuck * See saw more animations yeah * im almost done * home stretch baby * See Saw - wait what do you mean i'm done * Basic setup for curves * Jump start curve is in * smol figs * OutOut curves * They now how to get up now, may need tweaking * InIn curves added * Implemented more curves * Added ground jumps * Saw properly positions himself * Fixed an issue with see not landing correctly out or in * See reacts to you missing now * High jumps + get up plays at the correct moment now * Tweaks to high jumps * particles and missing stuff * anims * new sheet and anim fixes * oops * bigger background * Oops. Again * more anim fixes sorry * see saw tweaks and visual additions also added a way to scale particle systems to the tempo * bg color change added * Bops and choke added * Fix * lightning anim * particle particle particle * See saw - implemented lightning anim and fixed logic * Gradient is now actually a gradient * Implemented inverted colors on the see saw guys * Recolorable See saw! * Tiny tweak * Some things that weren't recolorable are now recolorable * Fixed a bug with the bg * new sheet the end * Barelies fixed --------- Co-authored-by: saladplainzone <chocolate2890mail@gmail.com> Co-authored-by: ev <85412919+evdial@users.noreply.github.com>
2023-05-19 22:20:57 +00:00
using UnityEngine;
namespace HeavenStudio.Util
{
public static class ParticleSystemHelpers
{
public static void PlayScaledAsync(this ParticleSystem particleSystem, float timeScale)
{
ParticleSystem.MainModule main = particleSystem.main;
main.simulationSpeed = (1 / Conductor.instance.pitchedSecPerBeat) * timeScale;
particleSystem.Play();
}
public static void SetAsyncScaling(this ParticleSystem particleSystem, float timeScale)
{
ParticleSystem.MainModule main = particleSystem.main;
main.simulationSpeed = (1 / Conductor.instance.pitchedSecPerBeat) * timeScale;
}
}
}