2024-04-28 13:55:19 +00:00
|
|
|
|
using Godot;
|
|
|
|
|
|
|
|
|
|
namespace ColdMint.scripts;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// <para>SloganProvider</para>
|
|
|
|
|
/// <para>标语提供器</para>
|
|
|
|
|
/// </summary>
|
|
|
|
|
public static class SloganProvider
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// <para>Define how many banners you want to display</para>
|
|
|
|
|
/// <para>定义共有多少条标语需要展示</para>
|
|
|
|
|
/// </summary>
|
2024-05-09 13:07:14 +00:00
|
|
|
|
private const int Total = 5;
|
2024-04-28 13:55:19 +00:00
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// <para>Swipe the machine to get a slogan</para>
|
|
|
|
|
/// <para>刷机获取一个标语</para>
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
public static string GetSlogan()
|
|
|
|
|
{
|
2024-05-08 10:22:04 +00:00
|
|
|
|
return TranslationServer.Translate("slogan_" + GD.RandRange(1, Total));
|
2024-04-28 13:55:19 +00:00
|
|
|
|
}
|
|
|
|
|
}
|