Positioning out-of-sub particles relative to the level, easier to climb stairs
This commit is contained in:
@@ -353,12 +353,12 @@ namespace Barotrauma
|
||||
|
||||
GameMain.ParticleManager.CreateParticle("blood",
|
||||
Position,
|
||||
particleVel * Rand.Range(100.0f, 300.0f));
|
||||
particleVel * Rand.Range(100.0f, 300.0f), 0.0f, character.AnimController.CurrentHull);
|
||||
}
|
||||
|
||||
for (int i = 0; i < bloodAmount / 2; i++)
|
||||
{
|
||||
GameMain.ParticleManager.CreateParticle("waterblood", Position, Vector2.Zero);
|
||||
GameMain.ParticleManager.CreateParticle("waterblood", Position, Vector2.Zero, 0.0f, character.AnimController.CurrentHull);
|
||||
}
|
||||
|
||||
damage += Math.Max(amount,bleedingAmount) / character.MaxHealth * 100.0f;
|
||||
|
||||
@@ -612,24 +612,19 @@ namespace Barotrauma
|
||||
}
|
||||
}
|
||||
//the limb has gone through the surface of the water
|
||||
if (Math.Abs(limb.LinearVelocity.Y) > 3.0 && inWater != prevInWater)
|
||||
if (Math.Abs(limb.LinearVelocity.Y) > 5.0f && inWater != prevInWater)
|
||||
{
|
||||
|
||||
//create a splash particle
|
||||
GameMain.ParticleManager.CreateParticle("watersplash",
|
||||
new Vector2(limb.Position.X, limbHull.Surface),
|
||||
new Vector2(0.0f, Math.Abs(-limb.LinearVelocity.Y * 10.0f)),
|
||||
0.0f);
|
||||
|
||||
//if (splash != null) splash.yLimits = ConvertUnits.ToSimUnits(
|
||||
// new Vector2(
|
||||
// limbHull.Rect.Y,
|
||||
// limbHull.Rect.Y - limbHull.Rect.Height));
|
||||
0.0f, limbHull);
|
||||
|
||||
GameMain.ParticleManager.CreateParticle("bubbles",
|
||||
new Vector2(limb.Position.X, limbHull.Surface),
|
||||
limb.LinearVelocity*0.001f,
|
||||
0.0f);
|
||||
0.0f, limbHull);
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user