Strange problem when disabling platform behavior

0 favourites
  • 5 posts
From the Asset Store
Strange factory themed set of tiles for your platformer game
  • Hi guys, i am facing an strange problem <img src="smileys/smiley19.gif" border="0" align="middle" /> in my game i have a bike which i created by the help of this tutorial

    I have added some extra features to the game.

    Ex : When user activated the power watch enemy movement will be slow down for 5 seconds.Below is the steps i have used.

    <img src="" border="0" />

    This is my events to move the bicycle.

    <img src="" border="0" />

    My problem is when user selects the power watch ,

    1. if the bicycle is moving at that time i cannot stop the bicycle though i pressed the left arrow key. it moves forward untill game ends.

    2. if the bicycle is not moving at that time i cannot move the bicycle though i pressed the right arrow key.

    Need help guys <img src="smileys/smiley1.gif" border="0" align="middle" /> i cannot find where i went wrong..Thank you...

  • Platform and Physics are two "moving" behavior, meaning they can handle movement for your sprites.

    When you activate platform, if you let the controls to Default (you can change this in the behavior parameters), it will capture the keyboard, and use the arrows to control the Platform sprite (here, your enemy).

    Doing this, you loose control of the bicycle.

    The solution is simple : change the parameters of the behavior to "Custom controls", and all should be good.

  • Hi, Thanks for the reply <img src="smileys/smiley1.gif" border="0" align="middle" /> now i have added the custom controls to enemies.and i tried to slow down the enemy.But same problem occurs   <img src="smileys/smiley5.gif" border="0" align="middle" /> <img src="smileys/smiley5.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
  • So if I understand right, the bike stops reacting to inputs, and the enemy don't slow down. Could you share the capx ?

    There may be something with the enemy movement. How do you move them ? Using the platform behavior and simulate input ?

  • I used platform behavior for enemies. I have used keyboard input instead of buttons.Now it works fine <img src="smileys/smiley1.gif" border="0" align="middle" /> <img src="smileys/smiley1.gif" border="0" align="middle" /> (I don't know why.But now it works    <img src="smileys/smiley1.gif" border="0" align="middle" /> ) Thank you very much for your help <img src="smileys/smiley1.gif" border="0" align="middle" /> <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)