Use consistent and less verbose deprecation messages

This commit is contained in:
2024-06-17 20:35:24 +03:00
parent 6c8288f38a
commit 22b4f33984
14 changed files with 28 additions and 28 deletions

View File

@@ -171,7 +171,7 @@ namespace FlaxEngine
/// <param name="ray">The ray to test.</param>
/// <param name="distance">When the method completes, contains the distance of the intersection, or 0 if there was no intersection.</param>
/// <returns>Whether the two objects intersected.</returns>
[Obsolete("Deprecated in v1.4")]
[Obsolete("Use Intersects with 'out Real distance' parameter instead")]
public bool Intersects(ref Ray ray, out float distance)
{
var result = CollisionsHelper.RayIntersectsBox(ref ray, ref this, out Real dst);

View File

@@ -659,7 +659,7 @@ namespace FlaxEngine
/// <param name="plane">The plane to test.</param>
/// <param name="distance">When the method completes, contains the distance of the intersection, or 0 if there was no intersection.</param>
/// <returns>Whether the two objects intersect.</returns>
[Obsolete("Deprecated in 1.4")]
[Obsolete("Use RayIntersectsPlane with 'out Real distance' parameter instead")]
public static bool RayIntersectsPlane(ref Ray ray, ref Plane plane, out float distance)
{
//Source: Real-Time Collision Detection by Christer Ericson

View File

@@ -645,6 +645,7 @@ namespace FlaxEngine
/// <summary>
/// Maps the specified value from the given range into another.
/// [Deprecated on 17.04.2023, expires on 17.04.2024]
/// </summary>
/// <param name="value">The value to map from range [fromMin; fromMax].</param>
/// <param name="fromMin">The source range minimum value.</param>
@@ -652,8 +653,7 @@ namespace FlaxEngine
/// <param name="toMin">The destination range minimum value.</param>
/// <param name="toMax">The destination range maximum value.</param>
/// <returns>The mapped value in range [toMin; toMax].</returns>
// [Deprecated on 17.04.2023, expires on 17.04.2024]
[Obsolete("Please use Remap to upkeep the API consistency")]
[Obsolete("Use Remap instead")]
public static double Map(double value, double fromMin, double fromMax, double toMin, double toMax)
{
double t = (value - fromMin) / (fromMax - fromMin);

View File

@@ -808,6 +808,7 @@ namespace FlaxEngine
/// <summary>
/// Maps the specified value from the given range into another.
/// [Deprecated on 17.04.2023, expires on 17.04.2024]
/// </summary>
/// <param name="value">The value to map from range [fromMin; fromMax].</param>
/// <param name="fromMin">The source range minimum value.</param>
@@ -815,8 +816,7 @@ namespace FlaxEngine
/// <param name="toMin">The destination range minimum value.</param>
/// <param name="toMax">The destination range maximum value.</param>
/// <returns>The mapped value in range [toMin; toMax].</returns>
// [Deprecated on 17.04.2023, expires on 17.04.2024]
[Obsolete("Please use Remap to upkeep the API consistency")]
[Obsolete("Use Remap instead")]
public static float Map(float value, float fromMin, float fromMax, float toMin, float toMax)
{
float t = (value - fromMin) / (fromMax - fromMin);

View File

@@ -825,7 +825,7 @@ namespace FlaxEngine
/// <param name="rotation">When the method completes, contains the rotation component of the decomposed matrix.</param>
/// <param name="translation">When the method completes, contains the translation component of the decomposed matrix.</param>
/// <remarks>This method is designed to decompose an SRT transformation matrix only.</remarks>
[Obsolete("Deprecated in v1.8")]
[Obsolete("Use Decompose with 'out Matrix3x3 rotation' parameter instead")]
public void Decompose(out Float3 scale, out Matrix rotation, out Float3 translation)
{
Decompose(out scale, out Matrix3x3 r, out translation);

View File

@@ -149,7 +149,7 @@ namespace FlaxEngine
/// <param name="plane">The plane to test.</param>
/// <param name="distance">When the method completes, contains the distance of the intersection, or 0 if there was no intersection.</param>
/// <returns>Whether the two objects intersected.</returns>
[Obsolete("Deprecated in 1.4")]
[Obsolete("Use Intersects with 'out Real distance' parameter instead")]
public bool Intersects(ref Plane plane, out float distance)
{
return CollisionsHelper.RayIntersectsPlane(ref this, ref plane, out distance);
@@ -202,7 +202,7 @@ namespace FlaxEngine
/// <param name="vertex3">The third vertex of the triangle to test.</param>
/// <param name="distance">When the method completes, contains the distance of the intersection, or 0 if there was no intersection.</param>
/// <returns>Whether the two objects intersected.</returns>
[Obsolete("Deprecated in 1.4")]
[Obsolete("Use Intersects with 'out Real distance' parameter instead")]
public bool Intersects(ref Vector3 vertex1, ref Vector3 vertex2, ref Vector3 vertex3, out float distance)
{
var result = CollisionsHelper.RayIntersectsTriangle(ref this, ref vertex1, ref vertex2, ref vertex3, out Real dst);
@@ -305,7 +305,7 @@ namespace FlaxEngine
/// <param name="sphere">The sphere to test.</param>
/// <param name="distance">When the method completes, contains the distance of the intersection, or 0 if there was no intersection.</param>
/// <returns>Whether the two objects intersected.</returns>
[Obsolete("Deprecated in 1.4")]
[Obsolete("Use Intersects with 'out Real distance' parameter instead")]
public bool Intersects(ref BoundingSphere sphere, out float distance)
{
var result = CollisionsHelper.RayIntersectsSphere(ref this, ref sphere, out Real dst);