Ai Forced to Jump
by MrTroy · in Technical Issues · 07/08/2007 (9:04 am) · 5 replies
I've been trying to figure this out for the past few hours. I can't seem to get the AI to jump when I want him to. I've tried
Bob.setImageTrigger(1,true)
Bob.setImageTrigger(2,true)
which does nothing visible and using
Bob.playThread("Jump");
causes the Ai Player to studder, then it doesn't work the second time and when the Ai dies, Krok stands there with his hands up. The death animation plays but he doesn't lay down.
Is there a way I can just say to the AI "You jump now!" with a keystroke?
Bob.setImageTrigger(1,true)
Bob.setImageTrigger(2,true)
which does nothing visible and using
Bob.playThread("Jump");
causes the Ai Player to studder, then it doesn't work the second time and when the Ai dies, Krok stands there with his hands up. The death animation plays but he doesn't lay down.
Is there a way I can just say to the AI "You jump now!" with a keystroke?
About the author
#2
07/09/2007 (8:40 am)
Ah thanks... I was reading somewhere that "The same way you make them fire, is the same way you make them jump" and was trying to apply that the same way it works with the player. I think Trigger 2 means jump for the player. I'm going to try applyimpulse tonight and see how well that works!
#3
07/10/2007 (6:51 pm)
ApplyImpulse is cool, it unfortunately isn't what I was looking.
#4
$thisConnection.Hopper.setImageTrigger(2,%val);
It's good now.
07/14/2007 (7:18 pm)
Weird... I don't know what happened but now it's working.$thisConnection.Hopper.setImageTrigger(2,%val);
It's good now.
#5
10/09/2007 (9:14 am)
Try modifying the ::onTrigger function to echo %trigger, %num, and %val to figure out the values
Torque Owner Jeremy Jenkins
P.S. I think the setimagetrigger stuff causes the weapons to be fired. That means your code is telling the weapons in nodes one and two to be active.