Commit 201baaaa authored by Sebastian's avatar Sebastian

fixed warning with velocity of static Rigidbody2D

parent 2ae7e55c
......@@ -17,7 +17,7 @@ namespace _Game.Scripts.Level_Hazards
if (other.gameObject.layer == LayerMask.NameToLayer("Player") || other.gameObject.layer == LayerMask.NameToLayer("Enemy") ||
other.gameObject.CompareTag("Fire"))
{
_rigidbody2D.velocity = Vector2.zero;
//_rigidbody2D.velocity = Vector2.zero;
_rigidbody2D.bodyType = RigidbodyType2D.Static;
}
}
......@@ -28,7 +28,7 @@ namespace _Game.Scripts.Level_Hazards
other.gameObject.CompareTag("Fire"))
{
_rigidbody2D.bodyType = RigidbodyType2D.Dynamic;
_rigidbody2D.velocity = Vector2.zero;
//_rigidbody2D.velocity = Vector2.zero;
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment