Changes to submarine<->outside teleporting logic:
- contacts between limbs and the sub are temporarily disabled before teleporting to prevent the character from "exploding" - impact damage is disabled for 0.25 seconds after teleporting in case the character still explodes - characters with disabled impact damage won't damage the walls when hitting - the collider of SubmarineBody is generated based on walls instead of hulls - fixed Submarine.CheckVisibilit ignoring fixtures with (CollisionWall | CollisionLevel) collisioncategory
This commit is contained in:
@@ -365,7 +365,7 @@ namespace Barotrauma
|
||||
GameMain.World.RayCast((fixture, point, normal, fraction) =>
|
||||
{
|
||||
if (fixture == null ||
|
||||
(fixture.CollisionCategories != Physics.CollisionWall && fixture.CollisionCategories != Physics.CollisionLevel)) return -1;
|
||||
(!fixture.CollisionCategories.HasFlag(Physics.CollisionWall) && !fixture.CollisionCategories.HasFlag(Physics.CollisionLevel))) return -1;
|
||||
|
||||
if (ignoreLevel && fixture.CollisionCategories == Physics.CollisionLevel) return -1;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user