Beispiel #1
0
 public EngineScene(EngineScene s)
 {
     _shadowObjects = s._shadowObjects;
     _visibleObjects = s._visibleObjects;
     _objects = s._objects;
     _sceneGraph = s._sceneGraph;
 }
Beispiel #2
0
        public GameEngine(MyGame game)
        {
            screenLog = new ScreenLog();
            _hotkeys = new List<HotKey>();
            _hotkeys.Add(new HotKey(new Keys[] { Keys.O }, SwichDebugRender));
            _hotkeys.Add(new HotKey(new Keys[] { Keys.P }, SwichBehaviourModel));

            KeyboardManager.Manager.AddKeyboardUser(this);

            game._engine = this;
            packs = new PackList();
             //   newPacks = new ContentNew.PackList();
            Instance = this;
            lightDir.Normalize();

            gameScene = new EngineScene();
            Scene = gameScene.Scene;

            //разме рэкрана
            MyGame.DeviceManager.PreferredBackBufferWidth = (int)(GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Width *0.8 );
            MyGame.DeviceManager.PreferredBackBufferHeight = (int) (GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Height*0.8);
            GameConfiguration.ScreenResolution = new Vector2(MyGame.DeviceManager.PreferredBackBufferWidth, MyGame.DeviceManager.PreferredBackBufferHeight);

            MyGame.DeviceManager.IsFullScreen = false;

            _cashe = new ObjectCashe();
        }
Beispiel #3
0
 public GameLevel(EngineScene __scene)
 {
     _scene = __scene;
     _allLogicObjects = new MyContainer<BaseLogicController>();
     _objectsForRemove = new MyContainer<BaseLogicController>();
 }