chip-gameV3/Assets/StringExtensions.cs
2026-07-14 11:14:13 +03:00

12 lines
336 B
C#

using UnityEngine;
public static class StringExtensions
{
public static string ColorWrap(this string text, Color color)
{
string hexColor = ColorUtility.ToHtmlStringRGB(color);
return $"<color=#{hexColor}>{text}</color>";
}
public static string UnderlineWrap(this string text) => $"<u>{text}</u>";
}