Rename Math::stepify to snapped
This commit is contained in:
parent
be509bf5e4
commit
b743a2ef3c
28 changed files with 148 additions and 148 deletions
|
|
@ -618,10 +618,10 @@ namespace Godot
|
|||
/// This can also be used to round a floating point
|
||||
/// number to an arbitrary number of decimals.
|
||||
/// </summary>
|
||||
/// <param name="s">The value to stepify.</param>
|
||||
/// <param name="s">The value to snap.</param>
|
||||
/// <param name="step">The step size to snap to.</param>
|
||||
/// <returns></returns>
|
||||
public static real_t Stepify(real_t s, real_t step)
|
||||
public static real_t Snapped(real_t s, real_t step)
|
||||
{
|
||||
if (step != 0f)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -511,7 +511,7 @@ namespace Godot
|
|||
/// <returns>The snapped vector.</returns>
|
||||
public Vector2 Snapped(Vector2 step)
|
||||
{
|
||||
return new Vector2(Mathf.Stepify(x, step.x), Mathf.Stepify(y, step.y));
|
||||
return new Vector2(Mathf.Snapped(x, step.x), Mathf.Snapped(y, step.y));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
|
|||
|
|
@ -513,9 +513,9 @@ namespace Godot
|
|||
{
|
||||
return new Vector3
|
||||
(
|
||||
Mathf.Stepify(x, step.x),
|
||||
Mathf.Stepify(y, step.y),
|
||||
Mathf.Stepify(z, step.z)
|
||||
Mathf.Snapped(x, step.x),
|
||||
Mathf.Snapped(y, step.y),
|
||||
Mathf.Snapped(z, step.z)
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue