Some questions about the camera and mouse
Posted: Wed Jan 14, 2009 4:15 am
I have a working 3rd person camera (or so at least). The camera is the child of the player's node and it is behind the player's node. I can already move it using the mouse and shooting using mouse click. (the bullet ran from the player's node toward where the player's looking, I don't have any weapon model right now)
what I want to ask is:
1.) When I hold down the mouse click (left mouse button), it only shot once but when I hold down the 'H' key (I wrote it for testing) the player keeps firing the gun without any delay (just like a machine gun).
How can this happen? what is the difference between mouse input and keyboard input? I want the mouse input shooting to behave just like the keyboard input shooting. (I'm using EMIE_BUTTON_DOWN or something like that, I'm not at home and I don't have my code with me)
2.)I wrote my camera using addCameraSceneNode(); and am able to make it looks towards where to mouse pointer is. (just like the addCameraSceneNodeFPS(); mine just more flexible to what I need) but when I looked up, up, and up until I faced the spot right above the player's node, and then looked up again, the camera suddenly 'jumps' to the player's feet (or foot, I don't know the difference).
How can this happen? I realize at addCameraSceneNodeFPS(); you can't look more up than the spot right above you or the spot right below you (the camera node),how does it does this?
I think that's about it, I hope my English is right and you guys can understand me.
thanks in advance, any help is appreciated
what I want to ask is:
1.) When I hold down the mouse click (left mouse button), it only shot once but when I hold down the 'H' key (I wrote it for testing) the player keeps firing the gun without any delay (just like a machine gun).
How can this happen? what is the difference between mouse input and keyboard input? I want the mouse input shooting to behave just like the keyboard input shooting. (I'm using EMIE_BUTTON_DOWN or something like that, I'm not at home and I don't have my code with me)
2.)I wrote my camera using addCameraSceneNode(); and am able to make it looks towards where to mouse pointer is. (just like the addCameraSceneNodeFPS(); mine just more flexible to what I need) but when I looked up, up, and up until I faced the spot right above the player's node, and then looked up again, the camera suddenly 'jumps' to the player's feet (or foot, I don't know the difference).
How can this happen? I realize at addCameraSceneNodeFPS(); you can't look more up than the spot right above you or the spot right below you (the camera node),how does it does this?
I think that's about it, I hope my English is right and you guys can understand me.
thanks in advance, any help is appreciated