Game Development Community

Problems with MotionTrack again...

by Joel Schilling · in Verve · 02/01/2011 (3:31 pm) · 6 replies

I'm trying to make a video capture of my level using Verve, but am having troubles with the MotionTrack's OrientationMode set to TOPATH again. The AIPlayer does follow the path, and in fact does orient to the path, but turned at 90 degrees clockwise!

I tried dropping back to using a VActor with VActorData, which does in fact orient correctly, but the problem is even worse... When I load the level it doesn't appear until I move him a little. If I put him on the MotionTrack, he starts in the right position, but doesn't move until I pause and hit play again, and then he jumps where he should have gone to. It's very possible I am doing something wrong, because I can't find any good examples how to use VActor.

One thing I've noticed is when I hit pause, the AIPlayer orients himself correctly, wherever he is on the path, and goes back to twisted 90% clockwise when I hit play again.

Help please! I really don't want to have to record this by walking around manually.

Thanks.

#1
02/01/2011 (4:24 pm)
How are you playing the sequence? Are you doing it from TorqueScript or the Verve editor itself?

You are welcome to send me am example scene so I can see how you're setting it all up.

AIPlayer definitely won't work with the pathing system, nor will Player. They would require too much modification to get working correctly which is why I created VActor.
#2
02/01/2011 (5:47 pm)
From the Verve editor. I'd be glad to use the VActor, but I can't find any examples anywhere. I took my best shot but like I said I got some pretty bizzare behaviour

YouTube video of the problem--the places he orients correctly is where I hit pause: http://www.youtube.com/watch?v=cuFDtl5LiL4

Here's the vsf:

<?xml version="1.0" ?>
<VerveControllerSequence Version="0.0.0a">
    <Properties>
        <Time>14679</Time>
        <Duration>78893</Duration>
        <TimeScale>1</TimeScale>
        <Loop>0</Loop>
        <LoopBackwards>0</LoopBackwards>
        <LoopCount>-1</LoopCount>
        <LoopDelay>0</LoopDelay>
        <ResetOnCompletion>1</ResetOnCompletion>
    </Properties>
    <DataTable>
        <DataItem Type="STATIC" Name="ThePath" Value="ChristianPath" />
        <DataItem Type="STATIC" Name="TheChristian" Value="Christian" />
        <DataItem Type="STATIC" Name="SceneGroup" Value="Christian" />
    </DataTable>
    <VObject Type="VSceneObjectGroup">
        <Properties>
            <Enabled>1</Enabled>
            <Label>SceneGroup</Label>
            <Reference>TheChristian</Reference>
        </Properties>
        <VObject Type="VMotionTrack">
            <Properties>
                <Enabled>1</Enabled>
                <Label>MotionTrack</Label>
                <Reference>ThePath</Reference>
                <OrientationMode>TOPATH</OrientationMode>
                <OrientationData></OrientationData>
                <Relative>0</Relative>
            </Properties>
            <VObject Type="VMotionEvent">
                <Properties>
                    <Enabled>1</Enabled>
                    <Label>MotionEvent</Label>
                    <TriggerTime>0</TriggerTime>
                    <Duration>0</Duration>
                </Properties>
            </VObject>
            <VObject Type="VMotionEvent">
                <Properties>
                    <Enabled>1</Enabled>
                    <Label>MotionEvent</Label>
                    <TriggerTime>6303</TriggerTime>
                    <Duration>0</Duration>
                </Properties>
            </VObject>
            <VObject Type="VMotionEvent">
                <Properties>
                    <Enabled>1</Enabled>
                    <Label>MotionEvent</Label>
                    <TriggerTime>9304</TriggerTime>
                    <Duration>0</Duration>
                </Properties>
            </VObject>
            <VObject Type="VMotionEvent">
                <Properties>
                    <Enabled>1</Enabled>
                    <Label>MotionEvent</Label>
                    <TriggerTime>17780</TriggerTime>
                    <Duration>0</Duration>
                </Properties>
            </VObject>
            <VObject Type="VMotionEvent">
                <Properties>
                    <Enabled>1</Enabled>
                    <Label>MotionEvent</Label>
                    <TriggerTime>78893</TriggerTime>
                    <Duration>0</Duration>
                </Properties>
            </VObject>
        </VObject>
    </VObject>
</VerveControllerSequence>
#3
02/01/2011 (5:48 pm)
And here's what I have in my level:

new VPath(ChristianPath) {
      position = "0 0 0";
      rotation = "1 0 0 0";
      scale = "1 1 1";
      canSave = "1";
      canSaveDynamicFields = "1";
      PathType = "LINEAR";
         node0 = "111.731346 -72.964340 92.822029 1.000000 0.000000 0.000000 0.000000 10.000000tFREE";
         node1 = "118.000000 -73.599998 93.000000 1.000000 0.000000 0.000000 0.000000 10.000000tFREE";
         node2 = "121.000000 -73.699997 93.000000 1.000000 0.000000 0.000000 0.000000 10.000000tFREE";
         node3 = "129.000000 -70.900002 93.000000 1.000000 0.000000 0.000000 0.000000 10.000000tFREE";
         node4 = "175.421143 -31.152279 93.000000 1.000000 0.000000 0.000000 0.000000 10.000000tFREE";
   };
   new Player(Christian) {
      dataBlock = "DefaultPlayerData";
      position = "112.365 -73.0571 91.4943";
      rotation = "1 0 0 0";
      scale = "1 1 1";
      canSave = "1";
      canSaveDynamicFields = "1";
         dmg_accum = "0";
         enableUse = "1";
         mountVehicle = "1";
   };
#4
02/01/2011 (5:51 pm)
Here's what I attempted to do with VActor:

new VActor(Christian) {
      dataBlock = "DefaultActorData";
      position = "112.365 -73.0571 91.4943";
      rotation = "1 0 0 0";
      scale = "1 1 1";
      canSave = "1";
      canSaveDynamicFields = "1";
         dmg_accum = "0";
         enableUse = "1";
         mountVehicle = "1";
   };

And the datablock:

datablock VActorData(DefaultActorData)
{
   shapeFile = "art/shapes/players/Christian/Christian.dae";
   cameraMaxDist = "0.75";
};
#5
02/02/2011 (4:51 pm)
Try changing VActor and VActorData to VHumanoidActor and VHumanoidActorData.

Give that a whirl and get back to me.
#6
02/03/2011 (6:07 pm)
Cool, that does the trick! Do you know is there an easy way to attach a follow camera to the moving actor at a standard distance away, or will I need to make a separate camera track and sync it up myself?