cpp file
Expand|Select|Wrap|Line Numbers
- void Camera::vUpdate( const float &fTimeMovement )
- {
- vec2Rotation = C_Input.vec2Update( fTimeMovement, vStrafeCamera, vMoveCameraFoward );
- }
- void Camera::vStrafeCamera( const float &fMovement )
- {
- // does stuff
- }
- void Camera::vMoveCameraFoward( const float &fMovement )
- {
- // does stuff
- }
Expand|Select|Wrap|Line Numbers
- D3DXVECTOR2 vec2Update( const float &fTimeMovement, void (*Strafe)(const float&), void (*Advance)(const float&) )
- {
- // stuff
- }
The problem is that the compiler i think gets confused, thinking i need to pass a variable through the functions like so ->
vec2Update( fTimeMovement, vStrafeCamera(variable), vMoveCameraFoward(variable) )
of course, with out compiling, you can see that would be completely wrong.
so any ideas how to fix this problem? with out making the functions global?