randomized particle play starting conditions
This commit is contained in:
parent
32bb4364d6
commit
7de0458ef4
1 changed files with 5 additions and 0 deletions
|
@ -21,6 +21,11 @@ static class VFX
|
|||
for (int i = 0; i < 8; i++)
|
||||
{
|
||||
index = (index + 1) % particles.Length;
|
||||
Particle particle = particles[index];
|
||||
particle.pos = pos.ToVec3;
|
||||
particle.vel = Quat.FromAngles(Random.Shared.NextSingle() * 360, 0, 0) * Quat.FromAngles(0, Random.Shared.NextSingle() * 360, 0) * Vec3.Forward * 6.0f;
|
||||
particle.ori = Quat.Identity;
|
||||
particle.scl = (1.0f / 8) * Maths.smooth_stop(Random.Shared.NextSingle());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue