[Make it easier] Switching events

This forum is currently in read-only mode.
  • If I add one to zero I get 1, that number is odd. If I add one to that, and get two, that number is even.

    If I add one to that and get three, I have a pattern, because that number is odd.

    http://dl.dropbox.com/u/666516/easyspace.cap

    + MouseKeyboard: On key Space pressed

    -> Sprite: Add 1 to 'num'

    -+ System: Sprite.Value('num') modulo 2 Different to 0

    ---> Sprite: Set Y to Sprite.Y-64

    -+ System: Else

    ---> Sprite: Set Y to Sprite.Y+64

  • Thank you very much!!!

    Your methods using variables are really working. I especially liked the ansmesnobody's solution:

    <img src="http://i48.tinypic.com/kapc9z.jpg">

    This is similar to my third method in the first post.

    I think the David's method is the best, because it consists only of 3 events and doesn't use any variables.

    <img src="http://i48.tinypic.com/8x63o5.jpg">

    It's really simple and works perfectly.

    Thanks! <img src="http://i987.photobucket.com/albums/ae352/constructgame/ew.gif">

  • You shouldnt need the trigger once for those sub events. also you could put them in with the comparison. the On key pressed acts as a trigger once for all the sub events.

  • You shouldnt need the trigger once for those sub events. also you could put them in with the comparison. the On key pressed acts as a trigger once for all the sub events.

    Thanks!

  • Duh! never thought of toggling groups from outside XD

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • It's great when there are many different solutions of the one task. When you combine methods you have the impression that play the logical game. <img src="http://i987.photobucket.com/albums/ae352/constructgame/ed.gif">

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