perezbalen's Recent Forum Activity

  • thanks.

    That was my first thought, but the problem is that the hitbox stays floating in mid air when the player moves (for the 0.2 seconds).

  • Hi

    I?m implementing a brawler, with a collision logic as this one:

    raywenderlich.com/24452/how-to-make-a-side-scrolling-beat-em-up-game-like-scott-pilgrim-with-cocos2d-part-2

    and I want to do this:

    whenever the player (using the platformer behavior) presses a button, I want to spawn a HitBox (that will represent the fist). It?s location should be x pixels in front of the character (so it the HitBox hits the enemy, it dies).

    The hit box should exist for half a second, and then disappear.

    The thing is that when my player is moving, his HitBox should move with him.

    How can I do that?

    So far, I spawn a hitbox by the playerBox, but this leaves it floating on space on the place it was created.

    I considered a main game OnEveryTick, but the HitBox should be local to the player, as the enemies will use their own HitBox.

    Thanks.

  • Hi

    I?m having this problem:

    When the left arrow is pressed, my player runs left.

    When I press the spacebar, it shoots, and it plays a shooting animation.

    When the left key is pressed, and without releasing it the spacebar is pressed too, the player moves while playing the firing animation (so far, so good).

    The thing is that when that happens, and the user lets go of the spacebar but keeps holding the left arrow, the sprite is stuck on the last frame of the firing animation (it does not return to the running animation).

    Basically, this is my code.

    <img src="http://s9.postimage.org/wt301jukv/Screenshot_178.png" border="0" />

    s9.postimage.org/wt301jukv/Screenshot_178.png

    The function PlayerForwardAttack is called when the spacebar is pressed.

    So far I?m thinking of a couple of ways to return the animation to running, but I?m thinking I?m missing something really obvious. Since the Run animation is executed on the "On Player Moved" event, shouldn't it be called every time the player is moving? shouldn't it be called after the spacebar is released?

    thanks.

  • Hi

    I?m using a Vaio Duo 11 with Windows 8 Pro, and this thing uses a stylus and touch input. For the right click, the stylus uses a combination of touching the screen and pressing a button. For the touch input, you are supposed to keep hold of the finger for about a second.

    None of those work in Construct 2. If I right click with a mouse, the menu opens ok, but since this hybrid has no mouse, it?s rather inconvenient that there?s no way to right click on Construct 2 with the default input.

    Operating system & service pack: Windows 8 Pro 64 bits

    Construct 2 version: 114 64 bits

  • Found the problem. It was the origin point not set to the left edge of the sprite.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi

    I basically cut&pasted the Kyatric's linked project, and got this.

    <img src="http://s7.postimage.org/5u479bszv/photo.png" border="0" />

    There's some kind of gap between each segment of the line. Actually is more like the Touch X&Y coordenates are not being red correctly (but when I run the linked project, things run fine) .

    Anyone has any idea why this could be happening?

  • Thanks to all for the info. Deeply appreciated!

  • Hi

    I want to draw a line between two points, yet have been unable to figure out a way to do that.

    My end game is to draw the path of the touch interface (or the mouse), in the same way it's done in Fruit Ninja.

    So far, my approach has been to create a small round object under the Touch coordinates, and then have it slowly die. This creates a trace like it's shown in the screenshot:

    <img src="http://s3.postimage.org/ej3f3dx0z/photo.png" border="0" />

    s3.postimage.org/ej3f3dx0z/photo.png

    But this approach won't get me the pointy line that's wide at the front, and gradually gets thinner as it fades away.

  • Thanks. Settting customMovement Horizontal back to zero did the trick.

  • So far I tried this:

    (playerBox has both Platform and CustomMovement behavours)

    <img src="http://s11.postimage.org/5usx08sxf/code1.png" border="0" />

    s11.postimage.org/5usx08sxf/code1.png

    But the result is that player always jumps forward. And if it was running before the function is called, it stays moving (and I can't stop it) towards the right.

  • Adagar, thanks for the responses.

    I'm trying to do an action platformer. My player is a ninja, and his attack is a swing of his sword. What I'm trying to do is for him to jump in the direction he's facing/running when the attack button is pressed.

    So when he's running forward, the attack will leap him forward 200 pixels in 0.2 seconds, inflicting damage to everything in his path.

    Later (When I figure how to implement the previous part), when he jumps, and hits the attack button, he will jump 200 pixels in 0.2 seconds in 45 or 90 degrees (inflicting damage to everything in his path).

    And later still, he will be able to do that in mid air (so he can dash in any angle including down; in a double-jump fashion.)

  • Now the problem is that it allways jumps straight to the right, regardless of motion.

    My guess is that using the platform behavior and the customMovement behavior, I need to bridge information from one to the other, right? (or just use one, but that would be to much work).

perezbalen's avatar

perezbalen

Member since 6 Feb, 2013

None one is following perezbalen yet!

Connect with perezbalen

Trophy Case

  • 11-Year Club
  • Email Verified

Progress

12/44
How to earn trophies