Attacking on a platformer

Get help using Construct 2

Post » Wed Aug 15, 2012 6:16 pm

Well, I've decided to make a little platformer, and I took the sprites from LoZ Link's Awekening, to try to make so he slashes his sword. I set the basics, like setting him mirrored when I click left arrow key and such. How do I make this trigger work:

When I push the spacebar button set animation to SlashSide

It simply doesn't work, then I tried space bar is down, it worked but it was messed up
Banned User
B
6
S
3
Posts: 105
Reputation: 1,170

Post » Thu Aug 16, 2012 8:41 am

"Hey guys can you please answer?!"
"NO"
"OK..."
Banned User
B
6
S
3
Posts: 105
Reputation: 1,170

Post » Thu Aug 16, 2012 10:35 am

Keep in mind that you may have conditions that are in conflict.

Say you hit space while moving (he tries to slash) but then you also hit forward (which might be making your character set the animation to walk instead).

Without a cap.x its pretty hard to give you an answer, as you could have coded up your game in 1 of 1 million ways.
ImageImage
B
74
S
17
G
6
Posts: 1,039
Reputation: 10,605

Post » Thu Aug 16, 2012 11:19 am

@GenkiGenga , here is the best way to do multi animations without any problem
http://www.scirra.com/tutorials/351/platform-behaviors-animation
if you found any problem on it tell me ^^
B
48
S
15
G
6
Posts: 795
Reputation: 12,035

Post » Thu Aug 16, 2012 11:26 am

Nice tutorial @Zsangerous. Definately worth a read :)GenkiGenga2012-08-16 11:27:18
ImageImage
B
74
S
17
G
6
Posts: 1,039
Reputation: 10,605

Post » Thu Aug 16, 2012 11:50 am

Thanks guys and GenkiGenga I even tried hiting space while standing still
Banned User
B
6
S
3
Posts: 105
Reputation: 1,170

Post » Thu Aug 16, 2012 12:40 pm

yeah this because this is the best way to do the animations on platforms ^^
B
48
S
15
G
6
Posts: 795
Reputation: 12,035

Post » Thu Aug 16, 2012 5:16 pm

Also, you can download the sandBOX and use it for reference.

I do it this way:
- Place a invisible object behind the player and pin it, with the origin point on the bottom, then, rotate the object to the same side of the player, check if this object is overlapping the enemy and subtract 1 from his life.

Another way:
- Every time you play fighting animations, create a invisible object behind the player, this object need to be larger than the player. Check if the object is overlapping the enemy, and, set to subtract his life.
ImageImageImageImageImageImage
B
93
S
20
G
12
Posts: 1,211
Reputation: 18,480

Post » Thu Aug 16, 2012 5:24 pm

@TELLES0808 , the problem if he doing multi-stuffs at the same time for example he is attack while jumping and moving so which animation he will use? also if he want to attack while moving only... he will keep fixing alot of stuffs with alot of events and then when he want to import a new animation he will take alot of time just to manage what happening thats why he is better to use the way i explained ^^
B
48
S
15
G
6
Posts: 795
Reputation: 12,035


Return to How do I....?

Who is online

Users browsing this forum: Kagubro and 21 guests