3dshapes Trigger problem
by Chris Labombard · in Torque Game Builder · 02/19/2006 (7:45 am) · 1 replies
I'm trying to get a 3dshapes animation trigger working, and it just won't.
I used the blueguy that comes with the milkshape dtsplus exporter, created an animation and added 2 triggers to it.
I exported it and set up the cs file and everything
I got him into T2D and his animation plays but the trigger just wn't seem to trigger for anything.
Here's what Im using:
I used the blueguy that comes with the milkshape dtsplus exporter, created an animation and added 2 triggers to it.
I exported it and set up the cs file and everything
I got him into T2D and his animation plays but the trigger just wn't seem to trigger for anything.
Here's what Im using:
$player1 = new t2dShape3D() { scenegraph = t2dScene; };
$player1.setShape($boxguyPath);
$player1.setPosition( "-25 0" );
$player1.setSize( 40 );
$player1.setShapeRotation ("0 270 0");
$player1.playAnimation( basic1 );
$player1.setTriggerActive( true );
function t2dShapeObject3D::onAnimationTrigger( %this, %triggerChannel )
{
echo( "Trigger on Object" SPC %this.getId() SPC "in channel" SPC %triggerChannel );
}About the author
I have been a professional game programmer for over 5 years now. I've worked on virtually every platform, dozens of games and released a few of my own games, including 2 iPhone titles and a title waiting release on Big Fish Games.
Torque Owner Chris Labombard
Premium Preferred
t2dShapeObject3D should be t2dShape3D ... I edited the wiki page.