Jump to content

Aligning individual animations in Construct 2


Recommended Posts

I'm in a bit of a conundrum and I'm not sure whether its a problem I should solve in Construct 2, Spriter, or is a result of my own incompetence. 

I have a few animations i'm trying to put in a game that have the character move around a lot. the thing is it always begins relative to the position of the player controlled object.

 

For example if an animation moves the player like this: (X = original position, O = final position)
 

                   X-------------------------------O

and the next animation has the player move like this:
 

       O--------X

 

I want it to move like this

                   X-------------------------------O

                                            O----------X

Instead it moves like this

                   X-------------------------------O

       O--------X

Does anyone here know how to solve this problem or will i have to adjust all the animations like this manually?

Link to post
Share on other sites

In general, animation should not move the player Sprite, actual x or y movement should be in code.

 

Are you using an invisible rectangular sprite(regular C2 sprite, not Spriter object) and pinning the Spriter object to the rectangular sprite? This is the best way to do things.

 

Cheers,
Mike at BrashMonkey

Link to post
Share on other sites

I'd have to see your capx to know for sure, and your Spriter project... but if your character animations are moving in the animations themselves this is going to be incredibly diffucult to fix...

 

1) The Spriter animation is becoming far away from the sprite its supposed to be pinned to.

2) The end of one Spriter animation does not ligh up with the beginning of the next.

 

 

Do you understand my point about not moving the character in the spriter animations?

 

Did you look at the Essentials Platformer pack and see that for Walking, Jumping, Falling, Attacking etc, the characters actual coordinates never change, he just animates as though moving... The actual changeing of position like moving up i nthe air, falling downward, and traveling left or right should be done in events in C2, not in Spriter.  Does this make sense?

 

 

Thanks,
Mike at BrashMonkey

Link to post
Share on other sites

All of my basic animations work like those you've mentioned. However, these specific animations are much more elaborate, which is why i tried to make them in spriter and translate them into construct 2.

An example of what I mean: XTgvUdS.gif

 

If it is the case that I have to go back and animate/edit these individual animations separately (for example in the case of the above animation, separating the sword from the rest of the animation in order to control its movement separate from the main body) then I will do so. I was just not sure which part I was getting incorrect. 

Link to post
Share on other sites

Excellent job Celestient. Thats exactly what I was going to suggest... but a note to anyone else reading this thread...whenever possible its better the movements are done within the game engine and not "built into  the animations", howver, in complicated cases like this, Celestient came to the propper solution. :)

 

cheers,
Mike at BrashMonkey

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...