How do I move to new layout with button and coins

0 favourites
  • 4 posts
From the Asset Store
112 High-Quality Coins and Chest SFX specially crafted for video games
  • Since I am new at this, this question is probably out of my league. I'm thinking it will require some programming skills (which I don't have). But here it goes anyway,

    When my player collides with a door, and if he has 5 coins. He will be asked if he really wants to continue, then, when the player clicks on a "Continue" button, he can

    go to the next level and 5 coins will be removed from his collection of coins.

    I have looked at tutorials and on this forum but can't find anything like this.

    Thanks

  • If coins is a global variable

    on clicked continue

    • system subtract 5 from coins
    • system goto layout

    Oh.. you probably only want to show continue if coins is more than 5

    player on collision with door

    system compare variable coins bigger or equal to 5

    • door spawn object continue (or any other way you'd like to have continue appear)

    By right clicking the event you can add another condition, for if you didn't know.

  • Works Great! Thanks !!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I wouldn't have learned without this forum, just returning the favour..

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