Frictional Games Forum (read-only)

Full Version: Enemy Lure and Animation Script?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have dogs.

Well, in real life I have dogs too, but I mean I have dogs that in a map, and the objective is to 'lure' them to a spot in order to get an object and then flee for ones life.

Using fresh meat placed at a particular spot, certain dogs are supposed to come over to it without attacking the player and eat.

I have the penumbra dogs from plutomaniac's post (HERE), and they have multiple animations, one of them being an eat animation.

I figure it's just about scripting it so that their triggers are turned off once the meat is placed, and then somehow scripting them to follow specific path nodes over to the meat, but is there a way to have them use their eat animation?

I know there's a part in the PatrolNode script that lets you pick an animation for the enemy to do when it reaches a path node, however I was told this was useless.

Sooooooo is this possible? Or would I be wasting time trying?
Tried this?
PHP Code:
void PlayPropAnimation(stringasPropstringasAnimationfloat afFadeTimebool abLoopstringasCallback); 
Makes the prop play an animation and calls a function.
Callback syntax:void MyFunc(string &in asProp)

asProp - internal name of the prop
asAnimation - animation to play
afFadeTime - ?
abLoop - determines whether the animation loops
asCallback - function to call
(03-30-2014, 12:45 AM)Mudbill Wrote: [ -> ]Tried this?
PHP Code:
void PlayPropAnimation(stringasPropstringasAnimationfloat afFadeTimebool abLoopstringasCallback); 
Makes the prop play an animation and calls a function.
Callback syntax:void MyFunc(string &in asProp)

asProp - internal name of the prop
asAnimation - animation to play
afFadeTime - ?
abLoop - determines whether the animation loops
asCallback - function to call

I didn't think about it. (Because it's prop stuff).

Would it work with enemy dogs?
I'm not actually sure, but I've seen other people suggest it for monsters.
Worth a shot, I guess.
(03-30-2014, 12:49 AM)Mudbill Wrote: [ -> ]I'm not actually sure, but I've seen other people suggest it for monsters.
Worth a shot, I guess.

Das is true. I'll give it a go.