Miyavi's Forum Posts

  • Sure:

    I have a global variable called "soundPlaying", which is initially set to 0.

    Whenever I enter a menu layout, I do the following:

    If soundPlaying == 0 -> set soundPlaying to 1, play "menuLoop"

    This way, whenever I leave the initial layout, it's always set to 1, and hence, the sound won't overlap itself.

    When I go to a Level Layout, as it has a different music loop, I simply stop the menuLoop music.

    When the user comes back from the level, I set "soundPlaying" to 0 again, so it starts playing again in the menus.

  • Well, that was easier than I expected.

    You simply need a variable to control it all.

  • Hi guys,

    How do you implement your menu's music?

    I want a single sound to play along all my menus, but I'm hitting a wall trying to implement it.

    I've tried some ways already, but it won't work out.

    It would be really easy if we had an event such as:

    If Sound "X" is playing -> Do such.

    But we don't right? :(

  • Yeah, I was guessing right.

    After implementing that, it stills blocks my clicking path.

    I guess I could send it to a different layer number, and recover it back, but I was guessing if there was a different way.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The group is already disabled on the start of the layout, so I think that's not the matter.

    Even although it's disabled, if I have for example, a gotoLevel sprite, and click where the disabled sprite is meant to be, it blocks me from clicking on the gotoLevel sprite.

  • Hi guys,

    I'm using sprites for my buttons, and I'd like to know if there's any way to disable the clicking on a sprite anyhow.

    I've tried to disable its collision, but I guess that only works for one object touching another object.

    It's actually inside a group so its actions/events don't run unless I activate the group (which I do when the layer the sprite is on is visible).

    Thanks,

    Miyavi.

  • Quick question: Would WebGL only .fx work with Windows Phone 8?

  • Good to know.

    Thanks, Kyatric.

  • As I stated, I used it on another project for doing the same thing, a pause system, and I had no problems at all, but anyone could tell us what's up with the else statement.

  • I just did. Being on my mobile desktop, with many icons, I did that, and none was triggered :P

  • If the user puts the whole palm, nothing will happen, as mobile screens mostly recognize finger-touches.

  • Well, Pause system implemented.

    I remember it took me ages to do it on my previous project due to that it's impossible (or I haven't thought of if in another way) without the System - Else sub-event, and I didn't know of it >.<

  • That's for sure.

    When I'm in doubt, I usually post it in the forums (after doing a search), so anyone can help me with it, and so if anyone has the same problem, they can take advantage of the topic.

    While doing so, I'm also trying to solve my issue in 1000 different ways, haha.

  • Yeah, although I've done a couple of projects with Construct I'm not nearly good at it yet, that's why I was mainly asking :P

  • Couldn't I just do it with the "On any touch start", checking the user it touching the pause button, so I can completely avoid that "canPauseUnpause"?

    This way, a single touch won't trigger the event more than once (as I'm only checking when it's first touched).