How can i get correct local position of character?
my code for test:
// Use this for initialization
void Start () {
SuperTextMesh stm = GetComponent<SuperTextMesh>();
string stringForSearch = "TEST!";
stm.text = "Hello, World!! Hello, World!! Hello, " + stringForSearch + " World!! Hello, World!! Hello, World!!"
int characterIndex1 = stm.hyphenedText.IndexOf(stringForSearch);
int characterIndex2 = characterIndex1 + stringForSearch.Length -1;
STMTextInfo ti1 = stm.info[characterIndex1];
STMTextInfo ti2 = stm.info[characterIndex2];
Debug.Log(ti1.character + " - " + ti2.character);
Vector2 boxSize = new Vector3(ti2.BottomRightVert.x - ti1.BottomLeftVert.x, stm.size);
Vector3 boxLocalPos = new Vector3(ti1.BottomLeftVert.y + boxSize.x / 2f, ti1.BottomLeftVert.y + boxSize.y/2f, 0);
//create box for test pos
GameObject testObj = new GameObject("TestPosition");
testObj.transform.SetParent(stm.t);
testObj.AddComponent<BoxCollider>().size = boxSize;
testObj.transform.localPosition = boxLocalPos;
}


