Exemplo n.º 1
0
    // Use this for initialization
    void Start()
    {
        Vector3 h = this.transform.position;

        mousePos = this.transform.position;
        PlayerPrefs.SetInt("sets", 0);
        posTest.transform.position = this.transform.position;

        RB2D = GetComponent <Rigidbody2D> ();
        PlayerPrefs.SetInt("sets", 0);
        audioMixer = Resources.Load("Audio/CardMixer") as AudioMixer;
        audio      = GetComponent <AudioSource> ();

        if (Application.platform == RuntimePlatform.Android)
        {
            currentControls = controlScheme.TouchTap;
        }
        else if (Application.platform == RuntimePlatform.OSXEditor ||
                 Application.platform == RuntimePlatform.OSXPlayer ||
                 Application.platform == RuntimePlatform.WindowsEditor ||
                 Application.platform == RuntimePlatform.WindowsPlayer)
        {
            currentControls = controlScheme.Mouse;
        }
    }
Exemplo n.º 2
0
 public void SettingsUpdate()
 {
     volume = PlayerPrefs.GetFloat("Volume") / 100;
     if (PlayerPrefs.GetString("Controls") == "WASD")
     {
         controls = controlScheme.WASD;
     }
     else if (PlayerPrefs.GetString("Controls") == "Arrows")
     {
         controls = controlScheme.Arrows;
     }
 }