Exemplo n.º 1
0
        protected override void OnAwake()
        {
            base.OnAwake();

            _Settings = VR.Context.Settings as KoikatuSettings;
            _KeySet   = _Settings.KeySets[0];
        }
Exemplo n.º 2
0
        // XMLSerializerは配列にデフォルト値をつけると、指定値とデフォルト値の両方を含む配列にしてしまうので
        public static KoikatuSettings Load(string path)
        {
            KoikatuSettings settings = Load <KoikatuSettings>(path);

            if (settings.KeySets.Count == 0)
            {
                settings.KeySets = new List <KeySet> {
                    new KeySet()
                };
            }

            return(settings);
        }
Exemplo n.º 3
0
        public MainGameContext()
        {
            _Materials = new DefaultMaterialPalette();
            Settings   = KoikatuSettings.Load(Path.Combine(configPath, "VRSettings.xml"));

            ConfineMouse = true;
            EnforceDefaultGUIMaterials = false;
            GUIAlternativeSortingMode  = false;
            GuiLayer         = "Default";
            GuiFarClipPlane  = 1000f;
            GuiNearClipPlane = -1000f;
            IgnoreMask       = 0;
            InvisibleLayer   = "Ignore Raycast";
            PrimaryColor     = Color.cyan;
            SimulateCursor   = true;
            UILayer          = "UI";
            UILayerMask      = LayerMask.GetMask(UILayer);
            UnitToMeter      = 1f;
            NearClipPlane    = 0.001f;
            PreferredGUI     = GUIType.uGUI;
            CameraClearFlags = CameraClearFlags.Skybox;
        }