to rotate your camera around an object you must first create a vector like this:
direction = camera->position - object->position
then rotate this vector(direction) using your deltaX and deltaY and at last calculate your camera position :
newCameraPos = object->position + direction
Search found 4 matches
- Sat Mar 26, 2011 10:28 pm
- Forum: Beginners Help
- Topic: Basic Mouse Movement
- Replies: 15
- Views: 1980
- Thu Mar 24, 2011 11:07 pm
- Forum: Advanced Help
- Topic: managing collisions for a third person shooter game. help!
- Replies: 6
- Views: 1165
- Thu Mar 24, 2011 10:45 pm
- Forum: Advanced Help
- Topic: managing collisions for a third person shooter game. help!
- Replies: 6
- Views: 1165
- Thu Mar 24, 2011 10:19 pm
- Forum: Advanced Help
- Topic: managing collisions for a third person shooter game. help!
- Replies: 6
- Views: 1165
managing collisions for a third person shooter game. help!
hi every one.
i am working on a third person game and i have problems with collision detection.
code is a bit of complex so i make it simple.
we have a bunch of animatedmeshes in the scene and we want to detect whether they are collided or not.
my solution was to check their boundig spheres first ...
i am working on a third person game and i have problems with collision detection.
code is a bit of complex so i make it simple.
we have a bunch of animatedmeshes in the scene and we want to detect whether they are collided or not.
my solution was to check their boundig spheres first ...