sirkame's Forum Posts

  • Hi friends,

    I have a ball that doesn't want to stop. It's like the friction is not enough and only 0 to 1 values are available, so I don't know what to do.

    I made a code to slow it down but it's so cheap and not always effective. Am I missing something?

    I'm trying to change the density and raising the world gravity, but it still goes on and on.

    Thanks!

  • Thank you soooooooooo much. Works like a charm.

  • Hi again friends,

    I got a golf game where the power of the shot is equal to the distance between the mouse position and the ball position (with limitations, obviously).

    Now, the bar, for example, can be 300px long but I want to show a number with the percentage of the power.

    I'm horrible at maths xD

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Easy =)

    Conditions:

    System: For each BLOCK

    Player: is overlapping BLOCK at offset 0,1

    Action:

    BLOCK: Set Animation Frame to 1

    BLOCK: Set Solid on (this allows the character to step over the blocks, but if there's an enemy following you, he'll fall)

    Now, to recover the state of a single block, it's just the same:

    Conditions:

    System: For each BLOCK

    Player: is overlapping BLOCK at offset 0,1 (INVERT)

    Action:

    BLOCK: Set Animation Frame to 0

    BLOCK: Set Solid off

    Now I'm trying to do the same with a full animation. I'll be back

    EDIT: Done!

    If you want to use animation looping. First of all, of course, make the animation and set it on loop. Then, just change the action "animation frame" for "Start animation from beginning" in the NOT overlapping action line.

  • I solved it easily. I was making a silly mistake. Just in case someone find it useful:

  • Hello!

    New question. I'm trying to make something like a bridge made of blocks (cloned from one object) and I want to change their animation or frame when he's on them and go back to normal when he steps away. I managed to make the effect I want but I don't know how to deactivate in one block only :S

    How could I make blocks to turn on and off independently?

    Thank you in advance!

  • That's exactly what I want. I'm looking for a way to include it in my game. Thank you VERY much.

  • Hi friends,

    I made an enemy which has life as an instance variable. In this specific case: 2 hits.

    So when something hits the enemy, it's life goes down by one and, when life = 0, it dies.

    Now, if I spawn two of them, only one seems to handle the instance. Could someone show me how to do this correctly?

    And how to make a different lifebar for each instance of enemy, if that's possible.

    Thank you very much.

  • For some reason, it doesn't work. I'm thinking on multi-layering the ground so when the character moves along them, they change their Z position... It's a little bit too complicated but I can't find another way.

  • Hi friends,

    I'm trying to make the character come to the front by using layers and/or Z layering, but I got a problem.

    I got my main character and several enemies, but they're all the same. Same object, just copied several times, in order to preserve the AI.

    Now, my code says that when player.y is above or below enemy.y it changes it's position, coming to a front position or behind it.

    But this only works with one of the enemies: the first one created (so, the first instance).

    Do I have to make different objects for each enemy, even when they're all the same? Can't I clone them?