Windows Audio crashes game on exit

Discussion in 'Programming' started by Wraithious, Feb 1, 2017.

  1. Wraithious

    Wraithious Member

    Joined:
    Jun 24, 2016
    Posts:
    1,166
    Hi, I'm having a strange problem with audio in my game, but only when exiting the game, it crashes and the 'windows is checking for a solution' window pops up and crashes the game, i have declaired audio_stop_all(); then game_end(); and even tried putting game_end(); in an alarm after but still the same issue, if I don't play the music there is no problem. any ideas?

    More info-
    2 low quality sounds of setting quality 2 and lowest compression setting,
    and 3 mp3s of setting quality 2 and the high compression option checked,
    And i call audio_stop_all(); before calling audio_play_sound(sound0,5,1);
     
  2. Wraithious

    Wraithious Member

    Joined:
    Jun 24, 2016
    Posts:
    1,166
    Please help, i have no idea why this is happening
     
  3. Wraithious

    Wraithious Member

    Joined:
    Jun 24, 2016
    Posts:
    1,166
    Also the problem does not occur when compiling to android

    If it can help this is my compile log:
    Compile started: 7:04:56 PM
    "C:\Users\compname\AppData\Roaming\GameMaker-Studio-Early-Access\GMAssetCompiler.exe" /c /m=win /config="Default" /tgt=64 /obob=True /obpp=False /obru=True /obes=False /i=3 /j=4 /cvm /tp=1024 /mv=1 /iv=0 /rv=0 /bv=525 /gn="Space S" /td="C:\Users\compname\AppData\Local" /cd="C:\Users\compname\Documents\GameMaker\Cache" /sh=True /dbgp="6502" /hip="127.0.0.1" /hprt="51268" /o="C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419" "C:\Users\compname\Documents\GameMaker\Examples\Space S.gmx\Space S.project.gmx"

    Reading project file....finished.
    Compile Constants...finished.
    Remove DnD...finished.
    Compile Scripts...finished.
    Compile Objects...finished.
    Compile Timelines...finished.
    Compile Triggers...finished.
    Compile Rooms...finished.
    Compile Extensions...finished.
    Global scripts...finished.
    Final Compile...finished.
    Saving IFF file... C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419\Space S.win
    Writing Chunk... GEN8
    Writing Chunk... OPTN
    Writing Chunk... LANG
    Writing Chunk... EXTN
    Writing Chunk... SOND
    *writing audio file C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419\sound0.ogg...
    *writing audio file C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419\sound1.ogg...
    *writing audio file C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419\sound2.ogg...
    *writing audio file C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419\sound3.ogg...
    *writing audio file C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419\sound4.ogg...
    Writing Chunk... AGRP
    Writing Chunk... SPRT
    Writing Chunk... BGND
    Writing Chunk... PATH
    Writing Chunk... SCPT
    Writing Chunk... GLOB
    Writing Chunk... SHDR
    Writing Chunk... FONT
    Writing Chunk... TMLN
    Writing Chunk... OBJT
    Writing Chunk... ROOM
    Writing Chunk... DAFL
    Writing Chunk... TPAGE
    Writing Chunk... CODE
    Writing Chunk... VARI
    Writing Chunk... FUNC
    Writing Chunk... STRG
    Writing Chunk... TXTR
    0 Compressing texture... writing texture texture_0.png...
    1 Compressing texture... writing texture texture_1.png...
    2 Compressing texture... writing texture texture_2.png...
    3 Compressing texture... writing texture texture_3.png...
    4 Compressing texture... writing texture texture_4.png...
    5 Compressing texture... writing texture texture_5.png...
    6 Compressing texture... writing texture texture_6.png...
    7 Compressing texture... writing texture texture_7.png...
    8 Compressing texture... writing texture texture_8.png...
    Writing Chunk... AUDO
    Writing Chunk... SCPT
    Writing Chunk... DBGI
    Writing Chunk... INST
    Writing Chunk... LOCL
    Writing Chunk... STRG
    Stats : GMA : Elapsed=3951.2249
    Stats : GMA : sp=32,au=7,bk=15,pt=0,sc=1,sh=0,fo=0,tl=0,ob=17,ro=2,da=0,ex=1,ma=16,fm=0x4092854DB82064
    Asset Compile finished: 7:05:06 PM
    -----------------------------------------------------------
    executing C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419\Space S.win
    -----------------------------------------------------------
    "C:\Users\compname\AppData\Roaming\GameMaker-Studio-Early-Access\Runner.exe" -game "C:\Users\compname\AppData\Local\gm_ttt_78174\gm_ttt_15419\Space S.win"

    Attempting to set gamepadcount to 12
    Total memory used = 12655114(0x00c11a0a) bytes
    Attempting to set gamepadcount to 0
    Compile finished: 7:20:17 PM

    And a visual of my sounds setup, but look how most are red in the tree list (pic on the left) and one is green, the one that's green has a volume slider on it, and the rest don't.
    sounds.png
     
    Last edited: Feb 6, 2017
  4. Wraithious

    Wraithious Member

    Joined:
    Jun 24, 2016
    Posts:
    1,166
    Anyone have an idea on this?
     
  5. Wraithious

    Wraithious Member

    Joined:
    Jun 24, 2016
    Posts:
    1,166
    Does anyone have any ideas on this???...
     
  6. Wraithious

    Wraithious Member

    Joined:
    Jun 24, 2016
    Posts:
    1,166
    Please help
     
  7. Strawbry_jam

    Strawbry_jam Member

    Joined:
    Jun 20, 2016
    Posts:
    217
    Try cleaning the build. If that doesn't work, try loading the audio in a new project and see if you can recreate the issue.
     
  8. Wraithious

    Wraithious Member

    Joined:
    Jun 24, 2016
    Posts:
    1,166
    ok thanks I'll try to re create it, I've tried deleting all the audio and re loading it, restarting my computer, it's really weird i haven't had much trouble with audio in projects since I learned the new audio engine, unless something changed in v1. 99. 525
     
  9. Wraithious

    Wraithious Member

    Joined:
    Jun 24, 2016
    Posts:
    1,166
    Hmmm well i made a test project and theres no audio crash problem, i'll have to go code block thru codeblock over the entire project (again), it's gotta be some weird error i made, just gotta find it.
     
  10. LV154

    LV154 Member

    Joined:
    Sep 9, 2016
    Posts:
    37
    I'm having a similar issue with this now. Did you ever get around to resolving it?
     
  11. LV154

    LV154 Member

    Joined:
    Sep 9, 2016
    Posts:
    37
    Apologies for bumping this thread but I wanted to ask whether or not external files should be preloaded or not. If I'm loading, playing and deleting sounds on demand, what exactly does "preloading" so, and does it hold any relevance to the issue?
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice