hover camera

7 views
Skip to first unread message

claudiul25

unread,
Aug 24, 2009, 11:06:24 AM8/24/09
to away3d.dev
i'm having a problem with the hover camera. if the target isn't set at
(0,0,0) the camera will behave wierd, it won;t orbit as you would
expect.
this problem was mentioned here with the solution, i took notice of it
and applied it to my project, but when i updated the engine with v 3.4
the as file was gone and so did the solution. i tried to find it here
but it wasn't anymore. i think it was deleted or something, although
it had a fix to a very annoying bug. i hope the next release of away
implements the simple solution to the hovercamera class.

claudiul25

unread,
Aug 27, 2009, 5:56:19 AM8/27/09
to away3d.dev
i found it ...

Just add

gx += target.x; gy += target.y; gz += target.z;

before

if ((x == gx) && (y == gy) && (z == gz)) return false;

in...@morphean.co.uk

unread,
Aug 27, 2009, 6:12:10 AM8/27/09
to away3...@googlegroups.com
I think i am experiencing the same issue, could you post the rest of the function to orbit a different point.

If set on 0,0,0 it works as expected, but if I change the target to 100,0,0 then the camera goes nuts...

tia

claudiul25

unread,
Aug 27, 2009, 8:30:16 AM8/27/09
to away3d.dev
the lines of code i posted should be inserted into the
hovercamera3d.as in the library in the moveCamera() function

morphean

unread,
Sep 3, 2009, 5:55:36 PM9/3/09
to away3d.dev
Perfect!! you are a genius my orbit is now resolved.

Will this patch be committed to the svn tree?

Rob Bateman

unread,
Sep 11, 2009, 6:17:22 PM9/11/09
to away3...@googlegroups.com
Thanx for the patch guys! this has now been updated in all versions

cheers

Rob
--
Rob Bateman
Flash Development & Consultancy

rob.b...@gmail.com
www.infiniteturtles.co.uk
www.away3d.com
Reply all
Reply to author
Forward
0 new messages