Ejemplo n.º 1
0
        public void pictureBox1_MouseWheel(object sender, MouseEventArgs e)
        {
            if (mCameraInputActive)
            {
                TabPanelData    data = (TabPanelData)mTabMap[mActiveTabPage];
                GodzGlue.Camera cam  = data.mPrimaryCamera;

                float mousedelta = (float)e.Delta / 120.0f;
                cam.MoveForward(mousedelta);

                //tick the actors so they send events over to renderer
                GodzUtil.RunMainPass();
            }
        }
Ejemplo n.º 2
0
        public void pictureBox1_MouseMove(object sender, MouseEventArgs e)
        {
            if (mCameraInputActive && e.Button == MouseButtons.Right)
            {
                TabPanelData    data = (TabPanelData)mTabMap[mActiveTabPage];
                GodzGlue.Camera cam  = data.mPrimaryCamera;

                PictureBox pictureBox = sender as PictureBox;
                if (pictureBox != null)
                {
                    cam.UpdateView(Cursor.Position.X, Cursor.Position.Y, origin.X, origin.Y, 0.1f);
                    centerCursor(pictureBox);
                }

                //tick the actors so they send events over to renderer
                GodzUtil.RunMainPass();
            }
        }