Example #1
0
    // Use this for initialization
    void Start()
    {
        keyMenager = GameObject.Find("KeyMenager").GetComponent <KeyMenager>();

        gm          = GameObject.FindGameObjectWithTag("GameMaster");
        soundholder = GameObject.Find("SoundHolder").GetComponent <SoundHolder>();
        bindkey     = gameObject.GetComponent <BindKey>();


        DefaultUI.SetActive(false);

        bindkeyUI = false;

        ResolutionScroll = false;
        QualityScroll    = false;
        //kategorie poziomu trundoĊ›ci
        category[0].SetActive(true);
        category[1].SetActive(false);
        category[2].SetActive(false);
        category[3].SetActive(false);

        load();

        if (gm != null)
        {
            gm.GetComponent <Game_Master>().settings = this;
        }
        SettingUI.SetActive(false);
    }
        public KeyCode GetKey(BindKey key)
        {
            if (key == BindKey.Primary)
            {
                return(primary);
            }
            if (key == BindKey.Secondary)
            {
                return(secondary);
            }
            if (key == BindKey.Extra)
            {
                return(extra);
            }

            return(KeyCode.None);
        }