添加了一些用于名称切换数据,可以满足随机名称的要求

This commit is contained in:
2023-11-24 19:54:59 +08:00
parent 1db23be3da
commit 7cbe59ca14
18 changed files with 250 additions and 44 deletions
+31
View File
@@ -0,0 +1,31 @@
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace XericLibrary.Runtime.MacroLibrary
{
/// <summary>
/// 缓动步进库
/// </summary>
public static class MacroInching
{
/// <summary>
/// 线性步进
/// </summary>
/// <returns></returns>
public static double LinearTowards(double from, double to, double maxStepDelta)
{
return from + Math.Clamp(to - from, -maxStepDelta, maxStepDelta);
}
/// <summary>
/// 线性步进
/// </summary>
/// <returns></returns>
public static float LinearTowards(float from, float to, float maxStepDelta)
{
return (float)LinearTowards((double)from, (double)to, (double)maxStepDelta);
}
}
}