Esempio n. 1
0
 private void OnActorAddedHandler(ActorViewModel model)
 {
     CommandManager.InvalidateRequerySuggested();
 }
        private void xna_OnDropActorHandler(
            ActorViewModel model, 
            System.Drawing.Point pointInGamePanel, 
            System.Drawing.Point gamePanelDimensions
        )
        {
            var sceneVM = SelectedScene;
            if(sceneVM == null) return;

            var position = sceneVM.Scene.GetPointInGameWorld(pointInGamePanel, gamePanelDimensions);

            if (OnDropActor != null)
                OnDropActor(model, sceneVM, position);

            if (OnActorAdded != null)
                OnActorAdded(model);
        }