khoa94
New Member
Posts: 2
Posts: 2
|
Post by khoa94 on Jul 17, 2014 5:34:26 GMT
Hi, I’m using PlayMaker and Core GameKit. I attach the “Killable” script to a game object. I set the “HP Death Mode” to “Zero Hit Points”. When the hit point of my game object gets to 0 or below, the game object is despawned. Is there a way for my game object to play a dead animation (using PlayMaker) before it is despawned?
|
|
|
Post by DarkTonic Dev on Jul 17, 2014 5:38:59 GMT
Not currently, unless you use a workaround that might work. You could have a "death prefab" that's the same as your game object and has a death animation on it and immediately plays it. Then you could use a Timed Despawner on that death prefab so it too dies after the animation plays, and make the death prefab invincible and zero attack points as well to prevent any combat during the animation. It is on the to do list already to add a delay before despawning Killables. I'll upvote that feature to the top now
|
|
|
Post by propekes on Feb 6, 2018 22:03:03 GMT
So this is on the todo list for 3 years now... any news?
|
|
|
Post by DarkTonic Dev on Feb 6, 2018 22:08:53 GMT
So there's a Death Delay field so you can delay the death prefab and all that by a particular amount of time (the length of the animation), but you will have to play the animation yourself with Playmaker or whatever you use. You can hook up to the KillablePlaymakerListener and use the appropriate event to do that.
|
|