Hi all! My first post on these forums, although ive been lurking for a while.
First of all thank you all for the help I have found on these forum so far, it is been a great source of information.
Also playmaker is awesome, via a combination of these forums and youtube for info, playmaker has allowed me to figure out how to do everything I ever wanted so far...
The short version:
I have been trying to make one animation start time be dependant on another animation's finish time. So if an animation on my character was transitioned to another animation - an animation on my projectile would start from a certain time.
An example of what im trying to do is that if two animations are 5 seconds long, If animation A ends 2 seconds after starting- I need animation B to start 2 seconds from it's end.
After trying a few strange attempts at this I think I just got muddled up in all the logic lol. To be honest im not sure if it is even possible and what actions to use. Apart from timing the start and end somehow in the fsm itself, which I need to experiment more with.
But really I was hoping the animator could make this easier and maybe im just missing the right action.
Thank you all for reading, I hope it made some sense after all my rambling and I really hope someone can help.
Also let me apolagize in advance if this should be totally obvious, im still quite a noob. Ive literally only been learning game making for a few months and this is the first thing that has really stumped me, I think it may be because i just have no idea how to search for the answer and have tried many different searches.
The full story of the problem:
I am trying to make a 2d 'tentacle like' rope attack for a side-scrolling 2d game. I guess it could be compared to the mortal combat 'get over here move' but without the dragging over here of the enemy.
I would like my character to fire a rope/tentacle which extends from his hand. Upon reaching an enemy the tentacle would detach from the player's hand and appear to dissapear into the enemy.
The issue is I want the tentacle to be able to be fired, detach and disappear into the enemy regardlesa of the distance the character is from the enemy.
A diagram:
Character = [] Enemy= () Tentacle= ----
[]---- () =character fires tentacle
[]-------- ()
[]----------() =tentacle hits enemy
[] -------()
[] ---() =tentacle disapears into enemy
[] ()
The way ive been trying to do it is by having the character play an anim of the tentacle coming out. At the same time the character creates a moving invisable object, which i have timed to move perfectly with the animation (the object is parented to char upon creation).
When the object triggers an enemy it stops moving and plays the 'retracting tentacle' animation on where the object is.
When the object hits an enemy it sends event to char and stops the character from playing the 'extending tentacle' animation.
That all more or less works (i think i need to parent the object to the enemy it hits, but that is not the problem).
The problem is that I need to make the 'retracting tentacle' animation be dependant on the length of the 'extending tentacle' animation.
Also ive considered using scaling to do it also, just havnt thought it through yet.
The main body of the tentacle can be scaled on the X axis without it affecting the way it looks (basic green tentacle), just has a pointy end- if that gives anyone an easy idea to do it with scaling...
Thank you all, especially if you have read this far, I appreciate any input. The great thing is that im such a noob that i bet there is plenty of ways to do what im doing and im just not seeing it.
(also just realised the way i described the attack- it sounds gruesome, in the game the tentacle does not disapear into the enemy's body, rather it binds the enemy lol. Also sorry for the super long post, just realising now...)