58 lines
772 B
C#
58 lines
772 B
C#
using System;
|
|
using UnityEngine;
|
|
|
|
[Serializable]
|
|
public class BMSymbol
|
|
{
|
|
public string sequence;
|
|
|
|
public string spriteName;
|
|
|
|
private UISpriteData mSprite;
|
|
|
|
private bool mIsValid;
|
|
|
|
private int mLength;
|
|
|
|
private int mOffsetX;
|
|
|
|
private int mOffsetY;
|
|
|
|
private int mWidth;
|
|
|
|
private int mHeight;
|
|
|
|
private int mAdvance;
|
|
|
|
private Rect mUV;
|
|
|
|
public int length
|
|
{
|
|
get
|
|
{
|
|
if (mLength == 0)
|
|
{
|
|
mLength = sequence.Length;
|
|
}
|
|
return mLength;
|
|
}
|
|
}
|
|
|
|
public int offsetX => mOffsetX;
|
|
|
|
public int offsetY => mOffsetY;
|
|
|
|
public int width => mWidth;
|
|
|
|
public int height => mHeight;
|
|
|
|
public int advance => mAdvance;
|
|
|
|
public Rect uvRect => mUV;
|
|
|
|
public void MarkAsChanged()
|
|
{
|
|
mIsValid = false;
|
|
}
|
|
}
|