Audio Looping Not Working

LuMa GamesLuMa Games USAMember Posts: 129

The "Loop Sound" button is not working for me. As you can see in the attached image, my audio is playing directly at the start and continues through the end - there are no blank spots. However, when I attempt to use the loop function there is a little half-second pause between each audio clip. Someone please help me :(
http://gyazo.com/ec305c2e654aabdbbe8baa1a78adbec6

Comments

  • HoneyTribeStudiosHoneyTribeStudios Member Posts: 1,792

    The loop function in GS works fine. What format audio clip are you using? If mp3 a slight delay might be added, although it wouldn't be as long as 0.5s. Mp3s don't tend to loop cleanly.

    m4a/aac, the format that itunes converts too, is better for music tracks. Or wav files if you have very short clips.

  • LuMa GamesLuMa Games USAMember Posts: 129

    @HoneyTribeStudios said:
    The loop function in GS works fine. What format audio clip are you using? If mp3 a slight delay might be added, although it wouldn't be as long as 0.5s. Mp3s don't tend to loop cleanly.

    m4a/aac, the format that itunes converts too, is better for music tracks. Or wav files if you have very short clips.

    That's great to hear that the audio loop function works fine and that im just making a mistake. It's just really frustrating because I can't figure out what I'm doing wrong. I'm using .WAV mostly. Maybe I'll try some different formats

  • HoneyTribeStudiosHoneyTribeStudios Member Posts: 1,792

    @Luma said:
    That's great to hear that the audio loop function works fine and that im just making a mistake. It's just really frustrating because I can't figure out what I'm doing wrong. I'm using .WAV mostly. Maybe I'll try some different formats

    I'm guessing you already confirmed your audio clip loops cleanly in other music players outside of GS? If yes, maybe try an m4a file.

    Also, are you testing on a device using an "ad hoc" build on on the desktop preview? Testing on a device is the only way to test for sure.

  • LuMa GamesLuMa Games USAMember Posts: 129

    @HoneyTribeStudios, Yes, I have tested it outside of GS, and it loops fine. I am still new to GS, and I don't know how to ad hoc test yet. For now I am just testing it in the GS previewer

  • HoneyTribeStudiosHoneyTribeStudios Member Posts: 1,792

    @Luma said:
    HoneyTribeStudios, Yes, I have tested it outside of GS, and it loops fine. I am still new to GS, and I don't know how to ad hoc test yet. For now I am just testing it in the GS previewer

    Yeah the previewer is pretty good but might not be perfect and audio can glitch in it sometimes. Testing on device is the best way. Looping works fine though so you don't have to worry about that.

    Section 3 of the GS guide will tell you how to get your game up and running on an iOS device:
    https://help.gamesalad.com/hc/en-us/articles/203081277-3-1-Setting-up-Development-Certificates

  • SocksSocks London, UK.Member Posts: 12,822
    edited October 2014

    @Luma said:
    The "Loop Sound" button is not working for me. As you can see in the attached image, my audio is playing directly at the start and continues through the end - there are no blank spots. However, when I attempt to use the loop function there is a little half-second pause between each audio clip. Someone please help me :(
    http://gyazo.com/ec305c2e654aabdbbe8baa1a78adbec6

    Firstly could you not trim the helicopter sound down to just a single cycle ? (Or does it modulate / change as the sound progresses ?).

    . . . . . . . .

    If you can still not get it to loop cleanly you could throw it inside a timer of some kind and use that to loop it.

    Find the length of your sound in seconds (let's say it's 3.4 seconds long) . . .

    Sound Actor:

    Play Sound (switch loop off)

    Rule when self.time is larger/equal to 3.4

    Destroy

    Spawn: 'Sound Actor'

  • SocksSocks London, UK.Member Posts: 12,822
    edited October 2014

    Example:

    https://www.mediafire.com/?pew5gs81j7pm6mz

    . . . . . . .

    An 'every' timer would also work . .

    Every 3.4 seconds:
    Play Sound

    . . . although the timer method does't seem as tight as the first method, the loop seems slightly early sometimes and others times a fraction late, although this kind of thing can screw up music it might not matter with sound effects.

  • LuMa GamesLuMa Games USAMember Posts: 129

    @Socks‌
    Originally, I did have the helicopter sound trimmed down the smallest I could make it. (Which is just two different blip noises). It looked like the picture you outlined above. After not having any success with the looping in GS, I made the sound effect longer. (It doesn't make much sense why that would even make a difference, but I was losing hope and started trying different things). As far as the timer method goes, I haven't had much luck with it. Like you said, sometimes they would overlap each other if I started it too early, and If I tried to adjust that then it would be a tad too late. Not to mention GS would have to "load" every time it replayed that sound and cause my test preview to lag when a new sound would play. Very odd stuff...

  • SocksSocks London, UK.Member Posts: 12,822

    @Luma said:
    Socks‌
    Originally, I did have the helicopter sound trimmed down the smallest I could make it. (Which is just two different blip noises). It looked like the picture you outlined above. After not having any success with the looping in GS, I made the sound effect longer. (It doesn't make much sense why that would even make a difference, but I was losing hope and started trying different things). As far as the timer method goes, I haven't had much luck with it. Like you said, sometimes they would overlap each other if I started it too early, and If I tried to adjust that then it would be a tad too late. Not to mention GS would have to "load" every time it replayed that sound and cause my test preview to lag when a new sound would play. Very odd stuff...

    Did you download my example file (above) ?

  • LuMa GamesLuMa Games USAMember Posts: 129
    edited October 2014

    @Socks said:
    Did you download my example file (above) ?

    Yes I did, It said the audio file wasn't supported but I saw your rules.
    http://gyazo.com/0f860b6a3240d1d0737ef9bb7d896072

  • LuMa GamesLuMa Games USAMember Posts: 129
    edited October 2014

    @Socks‌ Also, when trying to play a sound in GS or listen to it in a test preview, 50% of the time I can't even hear it, and you have no idea how much that is pissing me off. I'm exporting audacity files as .ogg or .wav. but no, GS doesn't want me to hear specific sounds I guess. Any suggestions?

Sign In or Register to comment.