Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Need help with camera movement

Author
Message
Jasmin
12
Years of Service
User Offline
Joined: 18th May 2012
Location:
Posted: 19th May 2012 10:52
This is probem:

I made project with camera movement on matrix and strafing, but when I press "W" for move camera forward, camera is going forward, but falling down...simillar problem when I want back "S"...but in this case...camera is going back and gaoing more and more in air.. xD

And just one more problem...when I Hold "W+A" "W+D" "S+A" and "S+D" camera has normal movement, but unnormal speed...

This is Code:



Help !

Jasmin
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 19th May 2012 15:10 Edited at: 20th May 2012 14:12
You need to point the camera straight ahead after you position it. Regarding the movement, typically moving on the diagonal is faster, but here is a way you could do it so the amount moved is the same.



EDIT: Code was edited. Fixed it so you can move left / right if either one of them is the only key being pressed.

So many games to code.......so little time.

MrValentine
AGK Backer
13
Years of Service
User Offline
Joined: 5th Dec 2010
Playing: FFVII
Posted: 19th May 2012 15:54
Nose DiveĀ”

[jumping in again]

Jasmin
12
Years of Service
User Offline
Joined: 18th May 2012
Location:
Posted: 20th May 2012 10:18
Tnx man...but U made mistake..now I can't move left and right

Jasmin
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 20th May 2012 22:06
Please check my post above - I edited the code to include left / right movement by itself.

So many games to code.......so little time.

Login to post a reply

Server time is: 2024-11-23 21:08:09
Your offset time is: 2024-11-23 21:08:09