I'm creating a simple platformer in the style of Donkey Kong Country and I was wondering how would I code an event that would have my character roll forward to attack? I'm using the Platform Movement Object for my character.
This is what I have set up:
IF > Press Z
THEN > Change Animation to Attack
IF > Attack is playing
THEN > Set X Position +3
It sort of works, but it'll go through objects and get stuck and there's no gravity applied. I would really appreciate some help. Thanks!
Basically that rolling ability is the same character with a different animation and moving faster, while still being pulled by gravity.
So if you think of it that way, you're on the right way with changing to a rolling animation. But instead of xpos=xpos+3 use the Platform Movement Object. Make the character speed up by temporarily changing the maximum speed allowed.
Normal has like speed 30.
When holding a button, speed is 40.
When rolling, speed is 50 (and animation is set to rolling).
By using the Platform Movement Object instead of xpos=xpos+3 the character is still tied to gravity.
This comes up all to often well making click games. Somebody runs into problems trying to get custom movements to play nice with the automatic animation system of media fussion.
I've seen everything tried. On the click team site. they have that chaos engine example. Of the little street fighter guy. It uses the platform movement object. but he went with the option of useing seperate objects instead of change animation. He did this because its just so &*?!%*# hard to reliable test the animation playing agaist a collsion, that may be hundreds of lines apart.
Their is just such a big learning cruve. When it comes to what methods work with which objects. If your going to modify your data manually via = sign. You better be ready to do it to everywhere. Or pay the price. When something gay happens. Like your rolling right animation starts to play well your moving left.
I'm just saying. Media fussion is vary powerfull. but its a whole different animal then the old games factory days.
Oh yeah I forgot about that stupid animation system. It's a little hard, but with the Platform Movement Object you should be able to better control the animations. And if not, you should build your own animation system based on values which will take precedence over the default/build-in animations. And if that's not willing to work you should go custom all the way.