コード例 #1
0
ファイル: MainMenu.cs プロジェクト: mrdivdiz/bpvita
    private void InitButtons(DeviceInfo.DeviceFamily platform)
    {
        GameObject gameObject = GameObject.Find("HDBadge");

        if (gameObject != null)
        {
            gameObject.SetActive(Singleton <BuildCustomizationLoader> .Instance.IsHDVersion && platform != DeviceInfo.DeviceFamily.Pc);
        }
        if (Singleton <SocialGameManager> .IsInstantiated())
        {
            this.ShowGameCenterButton(Singleton <SocialGameManager> .Instance.Authenticated);
        }
        if (this.shopButton)
        {
            this.shopButton.SetActive(Singleton <BuildCustomizationLoader> .Instance.IAPEnabled);
        }
    }
コード例 #2
0
    private void Awake()
    {
        DeviceInfo.DeviceFamily activeDeviceFamily = DeviceInfo.ActiveDeviceFamily;
        bool flag = false;

        foreach (DeviceInfo.DeviceFamily deviceFamily in this.enabledOnDevices)
        {
            if (activeDeviceFamily == deviceFamily)
            {
                flag = true;
                break;
            }
        }
        if (!flag)
        {
            base.gameObject.SetActive(false);
            UnityEngine.Object.Destroy(base.gameObject);
        }
    }