So i add music in my game and put the music into "music" file and make the music on, but when i touch the spike the music start playing again from beginning. Can anyone tell me how to make the music not restart?
Develop games in your browser. Powerful, performant & highly capable.
Give it a tag 'music' and then when you start the music you can check "is 'music' playing", if it is, do nothing. If it isn´t start it.