public TransformManager(GameEditor edit) { ma = new MoveArrows(); rc = new RotateCircles(); editor = edit; currentState = TransformManagerState.select; activeObject = new ObjectContainer(); GameEngine.renderController.setSelect(); }
public void Initalize() { FPSCounter = new Helpers.FpsCounter(); this.Camera = new Camera(this, new Vector3(20, 20, 10), new Vector3(0, 15, 0)); spriteBatch = new SpriteBatch(DeviceManager.GraphicsDevice); #region create physic scene /*CoreDescription coreDesc = new CoreDescription(); UserOutput output = new UserOutput(); Core = new Core(coreDesc, output); Core.SetParameter(PhysicsParameter.ContinuousCollisionDetection, false); Core.SetParameter(PhysicsParameter.ContinuousCollisionDetectionEpsilon, 0.01f); SceneDescription sceneDesc = new SceneDescription() { SimulationType = SimulationType.Software,//Hardware, MaximumBounds = new Bounds3(-1000,-1000,-1000,1000,1000,1000), UpAxis = 2, Gravity = new Vector3(0.0f, -9.81f*1.3f, 0.0f), GroundPlaneEnabled = false }; this.Scene = Core.CreateScene(sceneDesc); manager = Scene.CreateControllerManager(); */ #endregion // _sceneGraph = new Logic.SceneGraph.SceneGraph(); editor = new GameEditor(gameLevel); GraphicPipeleine = new RenderPipeline(DeviceManager.GraphicsDevice, Camera); CreateShader(); editor.SetDestEngine(); editor.SetFont(Font1); }
public override void CancelAction(GameEditor Editor) { MyContainer<PivotObject> objects = new MyContainer<PivotObject>(operatingObject.Length, 1); objects.AddRange(operatingObject.objects.ToArray()); Editor.AddObjects(objects, true); }