Game likes stuttering when sounds are included

This forum is currently in read-only mode.
From the Asset Store
Remake this game. Make a skill based bubble game in construct 3 using this fully commented source code template
  • Hello

    I have a problem:

    I make a game, and everything is OK... until I insert a sound. When I set sound related with (for example:) "collision between object 1 and object 2", When this event should take place, now the game is stuttering (game is stopped during 0.5-1 second <screen is frozen> and then plays again. I understand that's a kind of a burden for the whole game, when the sound is playing. But I cannot build the game without sound - it must be some way to solve this problem. Perhaps this question has already been raised, but unfortunately I didn't find anything on the forum.

    I will be grateful for any advice given to me.

    Sincere greetings

    Chris/bodzio_stawski

  • I don't have enough details to say for sure, but my guess is that the problem lies in the way your events are structured. Can you upload your CAP file so we can see what's going on in your game?

  • Yes, please upload a .CAP file so we can see actuall problem.

    P.S.

    Polak?

  • OK

    sendspace.pl/file/a9f35ac1e378a82c2224d5b

    (click on "pobierz")

    PS: There are more problems than I thought. Just check it :)

    <img src="smileys/smiley20.gif" border="0" align="middle" /> Polak :)

  • I didn't notice any stuttering or brief pause when the ball hits the paddle or bricks. Did you already fix this before uploading your CAP file?

    Anyhow, when I lost the game, there was a noticeable stuttering of sound and the program became unresponsive. To fix this problem, add a "trigger once" condition to your game-over event, as shown below.

    <img src="http://i396.photobucket.com/albums/pp45/Elyzius/sound.jpg" border="0" />

    By the way, I found your game to be very entertaining. It made me laugh to see the paddle getting destroyed bit by bit every time the ball hit it. <img src="smileys/smiley1.gif" border="0" align="middle" />

  • I'm terribly sorry for this, I didn't write about fixing of the first issue - I managed to solve this, and the sentence "There are more problems than I thought" is attached just to this error with "GameOver" sound, which you rightly have found.

    You're right, "trigger once" condition solve the problem with playing sound, so thanks :)

    But unfortunately, the game after losing the ball still stops responding. So it's not the end of the problem :(

    ---

    Thanks, the "bit by bit" destroying is conceived to be a key feature of this game :-)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • That strange MOD object is causing the crash. I don't know what it is, or why you've added it to the game, since i've never used it, but if you just erase it the game works fine after losing.

  • You're right! Once I inserted an object MOD (MOD is a specific audio format), because I wanted to see if many recurring sound problems depend on the sound format (and I forgot to remove it later). But as the one MOD file can make that the game is unresponsive... :)

    As my sound problems have been solved, .I can close this topic. So great thanks for Elyzius and shadowlord!!!

  • So how You solve this ...

    "game is stopped during 0.5-1 second <screen is frozen> and then plays again"

    Because I have a similar problem.

    Pozdrawiam rodaka ;)

  • Yes, it was precisely this problem, about which I wrote at the very beginning, and that I solved it later, and I forgot to mention about it ...

    I do not know how about you, but in my game it appeared when sound was playing by setting this system event:

    <img src="http://i725.photobucket.com/albums/ww251/bodziostawski/system.jpg" border="0" />

    So, as the normal system event worked bad, I decided to use an object "XAudio2". I set the action:

    On collision between <object> and <another object> (because I wanted to hear sound in such a situation)

    ===>             1)XAudio2: Load file "abc.wav" to channel 1 (no loop)

    2)XAudio2: play channel 1

    And that's all. In my game it works fine. :)

    PS: wybacz, ze po angielsku, ale moze to innym tez sie przydac :)

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