Page 1 of 1

Camera Collision?

PostPosted: Sun Jul 06, 2008 9:32 am
by Kierra
If I recall correctly, there used to be a way to create an unseen camera collision plane that didn't create a physical collider, but I can't remember what it was, and I haven't been able to find anything similar on the wiki.

I remember camera regions (where the camera can be fixed to a certain spot, made to rotate around the avatar, etc), but what I'm trying to do is make the camera follow the avatar like it normally does in 3rd person POV, just lower.

I have a large room with a tall ceiling, but I want the camera to sink down so that it is a little bit above and behind the avatar's head.

Thanks for any help,

~Kia

Re: Camera Collision?

PostPosted: Sun Jul 06, 2008 9:43 am
by boblishman
create a new camara, plus a camera region inside the room ... then set the avatar poa to 0,0,5 and a offset of 0,7,7 ...

you alcscript should look something like this ... (obviously, change the names of the camera and region)

camera region.jpg
camera region.jpg (35.22 KiB) Viewed 3110 times



(play around with the poa and offsets tilll you get exactly what you want)

p.o.a. = point on avatar (the numbers are in feet from the avatars feet in x,y,z)
offset = how offset from the avatar (so it's not pointing directly at his back) , again, x,y, & z in feet

Re: Camera Collision?

PostPosted: Mon Jul 07, 2008 9:06 pm
by Chacal
Kierra, I achieved this effect with a good ol' collider. Not sure why it wouldn't do the job for you.
I vaguely remember hearing about another way, but nothing more specific.

Re: Camera Collision?

PostPosted: Tue Jul 08, 2008 7:35 pm
by Paradox
Now a question (since I actually don't know and I don't have access to documentation to research it right now)...

Can you have a collider that only affects the camera? Like a plane that the avatar and all other objects could pass through, but that would prevent the camera from passing through; or does this need to be handled using camera regions and specific camera messages with flags?

Re: Camera Collision?

PostPosted: Tue Jul 08, 2008 7:53 pm
by Chacal
maybe this flag on HKPhysical:

Flag3 = 0x80 kCameraAvoidObject

http://wiki.cobbs.ca/index.php/PrpObjec ... HKPhysical

Re: Camera Collision?

PostPosted: Tue Jul 08, 2008 10:21 pm
by Trylon
It can be done.
You'd need a none-type collider, and set the cameraavoidobject flag.

I'm just not 100% sure how to do it at the moment.

Re: Camera Collision?

PostPosted: Wed Jul 09, 2008 5:38 pm
by Aloys
Prior to 0.5 there used to be a specific col_flags for camera colliders: "col_flags5: 00000004" not sure how that translate to 1.4.1/1.5.0..