Home   Help Search Login Register  

Author Topic: Remote Object Animation  (Read 1072 times)

0 Members and 1 Guest are viewing this topic.

vortex3d

  • Guest
Remote Object Animation
« on: 26 Aug 2004, 00:50:02 »
I'm trying to link the rotation of one object with another. how can I do this?

Example: I want to link the X, Y rotation of a chopper's gun turret to another object.

I have the object attached to the chopper with the axis named as 'camera1' but I have no clue how to read the angle of the turret and apply it to the camera.

Here's the turret script:


      class Turret
      {
         gunAxis="OsaHlavne";
         turretAxis="OsaVeze";
         body="OtocVez";
         gun="OtocHlaven";
         soundServo[]={"",0.05,1};
         gunBeg="usti hlavne";
         gunEnd="konec hlavne";
         minElev=-50;
         maxElev=45;
         minTurn=-360;
         maxTurn=360;
      };

DBR_ONIX

  • Guest
Re:Remote Object Animation
« Reply #1 on: 27 Aug 2004, 22:49:20 »
Maybe a loop with a getpos of the turret gunner
And a setdir the object

.. I suppose
- Ben

Unnamed

  • Guest
Re:Remote Object Animation
« Reply #2 on: 27 Sep 2004, 14:06:31 »
You still looking for a solution?

There is a way, but it involvers some relativly complex and processor hogging work arounds. The good news is, if it's just the direction and not the pitch, you wont need as much scripting.

There is a basic example here, the tank turret direction is the bit you want. Just apply the same priciple to the heli's gun.

http://homepages.gotadsl.co.uk/~gssoft/GameLogic.zip

Although the final, useable version was worked out by the MCar team over at Psychic Productions. You can get a beta tutorial here, but the more comprehensive stuff is on it's way.

http://homepages.gotadsl.co.uk/~gssoft/MCARGameLogics.zip