when i make a pc build of a unity game the menu screen of the game freezes for 10 seconds after i press the start button on the menu screen. after it freezes for 10 seconds it then goes into gameplay. the gameplay is fine. but whenever i go back to the menu screen and press start it freezes again for 10 seconds. how do i fix it? i’ve attached a picture to show all the messages i get after a pc build is created and after the menu screen freezes for 10 seconds.
HEY GUYS can i have some support?
can i have some thoughts? the menu screen freezes for 10 seconds on pc windows builds. why? and how to fix it?
We don’t know, we only can guess like you’re doing too much in Awake methods or you’re loading too much data. We don’t see or can examine your setup. Debug it. You have the debugger and the profiler. And if you have more data, feel free to come back and present it, maybe then we will have some ideas what’s happening.
well. i do have lots of music tracks i use in the game. could that be why menu screen freezes for 10 seconds after i hit start button on a pc windows build?
the more music tracks i have in the game the more the menu screen freezes. the less tracks i have in the game the less the menu screen freezes. so how do i get all the songs i want in without causing the menu screen to freeze more time?
https://docs.unity3d.com/Manual/class-AudioClip.html
Is Load in background enabled on them?
And/or Load Type: Streaming? Depending on what is your goal.
either way causes menu screen to freeze on pc build. the thing is i have a merged audio file that creates a wall of sound in the game played during gamplay. but the file is 118 MB. and because of that the menu screen freezes for about 4 seconds. not a quick 4 seconds. but like a long 4 seconds. the reason the file is a merged file is because in unity 20203.3f1 uses audio clip array. and not causes the music tracks to play out of order and sometimes repeats the same track after you die. and it never plays the songs in order. so i had merge all the tracks together. but it is a big merged size in 118 MB. so how do i compress the size of the 118 MB file to at least 10 MB or less without compromising any of the audio quality in the 118 MB file? i need it to be 10 MB or less because 10 MB or less audio file causes the menu screen to freeze for only about a second. and freezing for about a second isn’t too bad. i need to know how to reduce the 118 mb file size to at least 10 mb or less without messing up audio quality. how do i do it?
i set the tracks single each for streaming and it solved the menu freeze problem for pc build. but it took out the song on the menu screen and with the tracks on streaming it wouldn’t build a webgl build at all. it was empty folder for webgl build with streaming tracks. so how do i put song back on menu screen for pc build with all tracks streaming? and how do i make a webgl build that works with all tracks streaming?
can somebody on unity help me please?
