Exemplo n.º 1
0
    public void DoSwap()
    {
        if (horizontal)
        {
            states[activeState].horizontalSwipe(swipeVal);
        }
        else
        {
            states[activeState].Deactivate();

            if (downUp)
            {
                activeState++;
                activeState %= states.Length;
            }
            else
            {
                activeState--;
                if (activeState < 0)
                {
                    activeState += states.Length;
                }
            }

            states[activeState].Activate();
            //SetStateTitle( states[activeState].gameObject.name );
        }

        titleMaker.StartMaking();
        avatarNameMaker.StartMaking();

        SetMap();
    }
Exemplo n.º 2
0
 public override void horizontalSwipe(float val)
 {
     if (val < 0)
     {
         activeInfo++;
         activeInfo %= infos.Length;
     }
     else
     {
         activeInfo--;
         if (activeInfo < 0)
         {
             activeInfo += infos.Length;
         }
     }
     // rotator.eulerAngles = new Vector3(0, infos[activeInfo] / (2* Mathf.PI) * 360 + 180, 0);
     infoMesh.text = infos[activeInfo].info;
     stateMachine.SetTitle(infos[activeInfo].title);
     stateMachine.SetInfo(activeInfo, infos.Length);
     infoMaker.StartMaking();
 }
Exemplo n.º 3
0
    public void NewLetter()
    {
        currentLetter++;
        lastLetterTime = Time.time;
        aud.pitch      = Random.Range(.6f, 1.4f);
        aud.Play();
        if (currentLetter == totalCount)
        {
//      print("donzo");
            making = false;
            if (next != null)
            {
                next.StartMaking();
            }
        }
    }