how to make my music play without stopping

ok, so I watched tshirtbooth's videos online about adding music and he said that you need to find an actor at the beginning of the game that isn't going to be in the rest of the game. Then put the "play music" behavior on that actor and then click loop. and that did work, but on my game I have levels and on my levels I say, when " so and so "actor collides with "so and so" actor, reset scene. But when they collide and reset the scene they stop the music. can somebody help me.

Best Answer

  • The_Gamesalad_GuruThe_Gamesalad_Guru Posts: 9,922
    Accepted Answer
    When you use reset it turns everything to default this includes reset scene what you need is an actor in each scene that has play music and select resume current music. Yes when you do a hard reset the music will stop there is no way around that but you can resume it when that scene loads after the reset. Reset is easier to reestablish a scene but it does have it's drawbacks and the way around them is to code ones own quasi reset.

Answers

  • jamies15-3jamies15-3 Member Posts: 94
    Put somewhere in the scene a rule that resumes the music. On load of the scene i think would be best. I think ive understood the question right, hope that helps.
  • future_games_101future_games_101 Member Posts: 58
    that didn't work????
  • BluemoonstudiosBluemoonstudios Member Posts: 156
    Do you have a start button before your game starts? If you do, then you can have an attribute (boolean) call it music play or something, set it to false. Then when start button is pressed change attribute music play to true and play music. When your actors collide change music play to false. When the scene resets the boolean will be false and when you press start again it go back to true and the music will play again.
    :)
  • future_games_101future_games_101 Member Posts: 58
    i don't have a start button before my game starts. but thanks for trying
  • CORE GameCORE Game Member, PRO Posts: 280
    when it resets it doesnt start again ?

    can you please tell me what is the structure of the scenes you have?
    for example: intro > menu > gameplay ?
    if so you can have an actor in the intro with the music in a rule which will check if the music is running, and if not it will start the music.

    this actor can be placed in any scene you want.

  • MonDieu72MonDieu72 Member Posts: 27

    I know this is an old thread but just in case someone searches the forum I´ll just tell how I did this. Made an "init" scene in front of all other scenes, put an actor in it that starts the music and then directly changes to the start scene

  • civumakcivumak Member Posts: 1

    You can get all latest music for free on your Android and iOS devices using Setbeat app. Download it from http://setbeatapp.com

Sign In or Register to comment.