Example #1
0
        public GameEditor(GameScene scene)
        {
            actions = new ActionStack();
            gameScene = scene;

            hotkeys1 = new List<HotKey>();
            KeyboardManager.Manager.AddKeyboardUser(this);
            var ctrlz = new HotKey(new[] { Keys.LeftControl, Keys.Z }, revertAction);
            hotkeys1.Add(ctrlz);
            var biggerarrows = new HotKey(new[] { Keys.OemPlus }, biggerArrows);
            hotkeys1.Add(biggerarrows);
            var smallerarrows = new HotKey(new[] { Keys.OemMinus }, smallerArrows);
            hotkeys1.Add(smallerarrows);
            var deleteobjects = new HotKey(new[] { Keys.Delete }, DeleteSelectedObjects);
            hotkeys1.Add(deleteobjects);
            activeObject = new ObjectContainer();
        }
Example #2
0
 public void setNewLevel(GameScene scene)
 {
     Clear();
     gameScene = scene;
     GameEngine.levelController.ObjectsAdded(scene.objects);
 }