Particle fixes/improvements:

- Fixed particles going through closed gaps (e.g. closed doors).
- Gaps can emit particles even if the target hull is full of water (-> water running into the sub through an already flooded room is more apparent).
- The air-only splash & waterdrop particles are not emitted if the target room is full of water.
- Fixed heavy water particles never moving upwards (even if the water is rushing into a room from a gap on the floor).
This commit is contained in:
Joonas Rikkonen
2018-01-12 15:40:13 +02:00
parent 4e7e6ef60e
commit 10db837ef0
2 changed files with 24 additions and 13 deletions
@@ -261,7 +261,7 @@ namespace Barotrauma.Particles
bool gapFound = false;
foreach (Gap gap in hullGaps)
{
if (gap.IsHorizontal != (collisionNormal.X != 0.0f)) continue;
if (gap.Open <= 0.0f || gap.IsHorizontal != (collisionNormal.X != 0.0f)) continue;
if (gap.IsHorizontal)
{