Very unfinished attempt at changing the coordinate system to work relative to the level and to move the sub instead of the whole level
This commit is contained in:
@@ -59,7 +59,7 @@ namespace Barotrauma
|
||||
|
||||
this.position = position;
|
||||
|
||||
drawPosition = position + Level.Loaded.Position;
|
||||
drawPosition = position;
|
||||
|
||||
steeringManager = new SteeringManager(this);
|
||||
|
||||
@@ -153,7 +153,7 @@ namespace Barotrauma
|
||||
if (velocity.X < 0.0f) rotation -= MathHelper.Pi;
|
||||
}
|
||||
|
||||
if (Level.Loaded != null) drawPosition = position + Level.Loaded.Position;
|
||||
if (Level.Loaded != null) drawPosition = position;// +Level.Loaded.Position;
|
||||
|
||||
if (depth > 0.0f)
|
||||
{
|
||||
|
||||
@@ -889,7 +889,7 @@ namespace Barotrauma
|
||||
|
||||
if (Submarine.Loaded!=null && Level.Loaded !=null)
|
||||
{
|
||||
protectedFromPressure = protectedFromPressure && (Position-Level.Loaded.Position).Y > SubmarineBody.DamageDepth;
|
||||
protectedFromPressure = protectedFromPressure && Position.Y > SubmarineBody.DamageDepth;
|
||||
}
|
||||
|
||||
if (!protectedFromPressure &&
|
||||
|
||||
Reference in New Issue
Block a user