Hookshot-like Help

This forum is currently in read-only mode.
From the Asset Store
Push the Box Puzzle Game likes Sokoban made with Illustrator
  • Hello, how would you go about creating a hookshot-like attack in a side scrolling 2d game when a key is pressed on the keyboard? I know there is topic for this on the Scirra forums, but it is mainly for C2 environment. I would like to know how to do do this in CC environment... Please help.

  • Something similar to this game called Bravoman.

    youtube.com/watch

  • Never mind guys I figured it out now. <img src="smileys/smiley1.gif" border="0" align="middle" />

  • Ah great, how were you able to do it?

  • Sure thing bud, So basically I have a Robot Character in my game that can extend it's arms when attack like punch. So what I did is made the frame by frame animation of the punch. have those "punch stretch attack" like animations followed closely by and hit box that plays a "bullet object" form that spawns from the "Player's hit box", that hit box spawning from the player cancels out at the end of the animation once the attack is done.   <img src="smileys/smiley2.gif" border="0" align="middle" />

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I'm a little confused. The way You do did it sounds so complicated. In theory all You had to do was make the sprite animation frame by frame. Then play that animation, and check if any enemy object overlaps it.

  • Not quite Shindoh, I think he only wanted the attack to count when the enemy was at the end of a punch, and when it was going forward right ChromeGadget?

  • Not quite Shindoh, I think he only wanted the attack to count when the enemy was at the end of a punch, and when it was going forward right ChromeGadget?But even then, if I understand You right, then he could also just check if the last frame of animation is playing, and if any enemy collides with it.

    Or if the enemy is colliding with the last frame.right side plus/minus offset to increase the area for hit detection.

    Or alternatively just create a hitbox sprite at the desired area; easily with an image point, while the last frame of animation is shown, or for every frame of animation at the fist area.

  • Jayjay Yes you are right buddy, I did want the attack to count at the end of the punch.

    Shindoh Yea, that would be a less of a hassle with your theory as well. although, when it comes to Players and Enemies performing an attack. I can't help but use separate hitboxes to declare attacks, especially being somewhat of a newbie the Construct.

    For example, if you had a rotating "Spike Chain Ball" animation that swing back and forth and you want only the Spike ball of the sprite to effect the Player you would create an hitbox for the Spike Chain ball only.

    Now, I know there is a better way of doing a rotating "Spike Chain Ball" but I am using this as an example to explain my answer in a greater detail (I hope) if this was one full on sprite.       <img src="smileys/smiley1.gif" border="0" align="middle" />

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)