when i call setPositon() and give coords, the camera seems to jump randomly to a position,
irr::core::vector3df(0,0,0) always jum[s to the right position but when i set in to irr::core::vector3df(20,-10,10) i get 4 randomly positions,
example:
irr::core::vector3df(20,-10,10)
jumps to
irr::core::vector3df(20,2,11) or
irr::core::vector3df(23,0,13) or
irr::core::vector3df(200,100,25)
only + coords seems to work well most of the time
setposition cameraFPS
Does the camera has a collision response animator (and the map, too) ???
If so this could cause this behavior if you set the cam to a position that the cam has to move through an obstacle for moving to !!!
If so this could cause this behavior if you set the cam to a position that the cam has to move through an obstacle for moving to !!!
while(!asleep) sheep++;
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
IrrExtensions:

http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
yes i have, so do i have to stop it and restart it when i moved?
Compete or join in irrlichts monthly screenshot competition!
Blog/site: http://rex.4vandorp.eu
Company: http://www.islandworks.eu/, InCourse
Twitter: @strong99
Blog/site: http://rex.4vandorp.eu
Company: http://www.islandworks.eu/, InCourse
Twitter: @strong99
I had this problem too, when I first used the Irrlicht collision...
AFAIR I created a second cam, positioned it at the new pos and then I added a new collision response animator (probably there are better ways)...
There are also some threads about this problem in the forum...
But I switched verry fast to Newton, and with Newton you can disable a collision (freeze) and after positioning enable it again (unfreeze)...
AFAIR I created a second cam, positioned it at the new pos and then I added a new collision response animator (probably there are better ways)...
There are also some threads about this problem in the forum...
But I switched verry fast to Newton, and with Newton you can disable a collision (freeze) and after positioning enable it again (unfreeze)...
while(!asleep) sheep++;
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
IrrExtensions:

http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
before i do the setPostion() i remove the world from the animator, then setPos and then add the selctor to the animator, when i don't do the last step ( readding the selector ) i got on the position, but when i enable the world i jump back to a random position (same positions as before)
Code: Select all
this->gamecore->getSettings()->response_player->setWorld(0);
this->gamecore->getSettings()->getActiveCamera()->setPosition(irr::core::vector3df(1795,-420,486));
this->gamecore->getSettings()->response_player->setWorld(this->gamecore->getLoadEngine()->getSceneLoader()->getSelector());Compete or join in irrlichts monthly screenshot competition!
Blog/site: http://rex.4vandorp.eu
Company: http://www.islandworks.eu/, InCourse
Twitter: @strong99
Blog/site: http://rex.4vandorp.eu
Company: http://www.islandworks.eu/, InCourse
Twitter: @strong99
This is because the animators are updated even if detached from the node. So just removing them, seting the camera pos and attaching them would not help. You could remove the animator, drop it, change the position, create a new animator and attach it to the camera.
Maybe there are better solutions but I am not aware of them.
Regards
Maybe there are better solutions but I am not aware of them.
Regards