Turret rotation

Got questions, comments and/or feedback regarding Craft Director Studio? Post them here.
Forum rules
We only allow posts that
  • Is in English
  • Is related to our tools and the programs they support.

If these rules are not met you are most likely going to be banned.

Please Note:
  • New users will have their posts reviewed before being publicly available for other to see.
Post Reply
Makkster
Posts: 14
Joined: Wed Sep 29, 2010 1:31 pm

Turret rotation

Post by Makkster » Wed Sep 29, 2010 1:34 pm

I'm currently learning how to configure the CrawlerExt and apply this to a tank model in Maya that I'd like to rig up.

I have added a firepower and would like to attach this to my high poly gun turret so that I can then use the right thumbstick on my xbox controller to make the gun turret rotate. Unfortunately I am lost trying to work out how to do this part.

Can anyone provide any pointers please?

User avatar
Micael Belin
CTO
Posts: 168
Joined: Thu Apr 03, 2008 9:39 am
Location: Gothenburg, Sweden
Contact:

Re: Turret rotation

Post by Micael Belin » Wed Sep 29, 2010 2:05 pm

The Firepower only deals with firing the actual cannon. To make the turret rotate, i recommend using the observercam. Not the most obvious use of a camera, i know, but it actually does it fairly well.

Place the camera on the pivot location for the turret. Then parent the camera to the chassis and the turret to the camera. The hierarchy would look something like chassis->camera->turret, where chassis is the grand parent.

Then simply bind yaw and pitch on the camera to your controller and you have a rotating turret.

Most turrets actually have two joints, one being the tower controlling yaw, then the barrel only controlling pitch. You can achieve this using two observercams, one controlling the tower and yaw, the other controlling the barrel and pitch. It's hierarchy would look something like:

chassis->obscam1_yaw->tower->obscam2_pitch->barrel.
[email protected]
http://www.craftanimations.com

Makkster
Posts: 14
Joined: Wed Sep 29, 2010 1:31 pm

Re: Turret rotation

Post by Makkster » Wed Sep 29, 2010 3:06 pm

Ha ha, no wonder i couldn't get it then. Thanks I shall give this method a try.

Makkster
Posts: 14
Joined: Wed Sep 29, 2010 1:31 pm

Re: Turret rotation

Post by Makkster » Wed Sep 29, 2010 3:43 pm

Ok, I gave that a go - it worked a treat! Thanks again.

Makkster
Posts: 14
Joined: Wed Sep 29, 2010 1:31 pm

Re: Turret rotation

Post by Makkster » Thu Sep 30, 2010 4:01 pm

"Most turrets actually have two joints, one being the tower controlling yaw, then the barrel only controlling pitch. You can achieve this using two observercams, one controlling the tower and yaw, the other controlling the barrel and pitch. It's hierarchy would look something like:

chassis->obscam1_yaw->tower->obscam2_pitch->barrel."

If I want to restrict the pitch of the barrel how would I do this?

Thanks.

Patrik Martin
Partner
Posts: 416
Joined: Mon Feb 25, 2008 1:07 pm
Location: Gothenburg, Sweden
Contact:

Re: Turret rotation

Post by Patrik Martin » Fri Oct 01, 2010 3:40 pm

Makkster wrote:"Most turrets actually have two joints, one being the tower controlling yaw, then the barrel only controlling pitch. You can achieve this using two observercams, one controlling the tower and yaw, the other controlling the barrel and pitch. It's hierarchy would look something like:

chassis->obscam1_yaw->tower->obscam2_pitch->barrel."

If I want to restrict the pitch of the barrel how would I do this?

Thanks.
You are also able to use DirectInputLink and 1DRotator. The way you restrict it is to only set up the input setting for that perticular movement. In the case of the ObserverCam only use the Pich input for the barrel.
Partner
http://www.craftanimations.com
patrik.martin-at-craftanimations.com

Post Reply

Who is online

Users browsing this forum: No registered users and 36 guests