Skip to content

I made a better approach for the camera movement#1

Open
Denommus wants to merge 4 commits intoKermit:masterfrom
Denommus:master
Open

I made a better approach for the camera movement#1
Denommus wants to merge 4 commits intoKermit:masterfrom
Denommus:master

Conversation

@Denommus
Copy link

@Denommus Denommus commented Jan 3, 2012

The mouse handling was strange, and could make strange bugs. The algorithm handles it better, now. It works like this:

-At the beginning of the update, the current position of the mouse is compared with the center of the screen.
-The difference between them is accounted and translated as a movement.
-The position of the mouse is set to the center of the screen

This way, the mouse won't reach the border of the screen, or get out of the window, which would impede it from controlling the camera.

Yuri Albuquerque and others added 4 commits January 3, 2012 17:20
The mouse handling was strange, and could make strange bugs. The algorithm handles it better, now. It works like this:

-At the beginning of the update, the current position of the mouse is compared with the center of the screen.
-The difference between them is accounted and translated as a movement.
-The position of the mouse is set to the center of the screen

This way, the mouse won't reach the border of the screen, or get out of the window, which would impede it from controlling the camera.
Signed-off-by: Arkadiusz Neuman <mrmoro@o2.pl>
The mouse handling was strange, and could make strange bugs. The algorithm handles it better, now. It works like this:

-At the beginning of the update, the current position of the mouse is compared with the center of the screen.
-The difference between them is accounted and translated as a movement.
-The position of the mouse is set to the center of the screen

This way, the mouse won't reach the border of the screen, or get out of the window, which would impede it from controlling the camera.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant