Spawn Collision box on an animation's ImagePoint

Get help using Construct 2

Post » Thu Dec 27, 2012 2:28 am

So I have my player character setup an animation sprite attached to the platform player box.

Since I have so many different attacks, I would like to spawn a specific hitbox onto 1 specific animation's custom image point.
I made it so the image point only exists between frames 5-8 (since this is where the player is actually attacking in the animation.)


Here's a caption of how I'm spawning the box

Here

Here's the .capx

https://www.dropbox.com/s/xwg79fwog77yjbg/fight.capx
B
32
S
4
Posts: 405
Reputation: 3,219

Post » Thu Dec 27, 2012 11:48 pm

I don't see any questions in your post, is this something you need help with or is it a guide?
B
27
S
8
G
8
Posts: 903
Reputation: 8,452

Post » Fri Dec 28, 2012 12:44 am

Sorry, It was late and I was tired, and I posted a horrible description haha. Here's a much better described and updated post.

I am trying to spawn a specific hitbox onto 1 specific animation's custom image point, but can't get it to work.

So I have my player character setup as an animation sprite attached to the player box.

I have imagepoint1 (strikeboxpoint) set to different spots, depending on the attack. Since I have so many different attacks, I would like to spawn a specific hitbox onto 1 specific animation's custom image point.
I made it so the image point only exists between frames 5-8 (since this is where the player is actually attacking in the animation.)

Here's an image.


Here's the .capx

DropBox
what am I doing wrong?
B
32
S
4
Posts: 405
Reputation: 3,219

Post » Wed Mar 13, 2013 8:37 pm

i have the same problem in my game someone help?
B
2
Posts: 2
Reputation: 404

Post » Thu Mar 14, 2013 1:56 am

I think you have to use numbers in stead of the image point's name.

And i was also trying to spawn the object on frame 1 image point 2 when the impage point only existed at 5-8
B
32
S
4
Posts: 405
Reputation: 3,219

Post » Thu Mar 14, 2013 4:12 am

if the image point only exists in some frames, you have to make sure that the particular frame that has it is being evaluated at the same time the event runs or else the image point won't be there and the event will not work. that is about the only way I can figure it. why not have more animations (for each scenario) and then have the collision box available in all frames of the particular animations it is needed in?
B
49
S
11
G
10
Posts: 1,833
Reputation: 14,418

Post » Thu Mar 14, 2013 4:13 am

also make sure if using names you put quotes around them "
B
49
S
11
G
10
Posts: 1,833
Reputation: 14,418

Post » Thu Mar 14, 2013 5:48 am

I actually have it check which frame of the attack it's on before spawning a collision box in my game.

You just check if the animation is playing, and the specific frame along with a couple other personal checks and it spawns the hitbox in that frame on that imagepoint.
B
15
S
4
G
4
Posts: 294
Reputation: 3,225


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 14 guests