Exemplo n.º 1
0
 public void SetText(int localizedID)
 {
     if (localizedID == 0)
     {
         text.text = "";
     }
     else
     {
         text.text = Localization.text(localizedID);
         typeWriter.Play();
     }
 }
Exemplo n.º 2
0
 static int Play(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         FXTypeWriter obj = (FXTypeWriter)ToLua.CheckObject(L, 1, typeof(FXTypeWriter));
         obj.Play();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
Exemplo n.º 3
0
    IEnumerator Play()
    {
        int index = 0;

        while (index < localizedID.Length)
        {
            yield return(new WaitForSeconds(_TimeDelay[index]));

            if (index < text.Length)
            {
                _Text.text = text[index];
            }
            else
            {
                _Text.text = Localization.text(localizedID[index])[0].ToString();
            }
            _TypeWriter.Play();
            index++;
        }
    }