I can't select sounds in dropdown

JelmerHPJelmerHP Member Posts: 37
edited March 2015 in Working with GS (PC)

If I want to add a sound to a button I can't select a sound in the behaviour. And I made sure the sound is in GS.

Does anyone know how to fix this?

Comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    Did you import the sound as Music or Sound? What format is the sound file you imported? Are you able to play the sound in the Library? What happens when you drag the sound from the Library to an actor's rule list? Does it create a Play Music behavior or a Play Sound behavior? Can you hear it when you click play?

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • JelmerHPJelmerHP Member Posts: 37

    I tried different formats: mp4, ogg, wav, MP3. Every time it shows in the library as a m4a and yes I can play it in the library. If I drag it into an actor it shows a play music behavior but when I manually enter a play music behavior then I'm not able to select any music. And how do I import it as a sound?

  • JelmerHPJelmerHP Member Posts: 37

    Oh, I just noticed that I posted this in Mac accidentally :S I'm using windows

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    On a Mac, it asks you if the file is Music or Sound and then imports it accordingly. I'm not as familiar with the Windows version.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • JelmerHPJelmerHP Member Posts: 37
    edited March 2015

    I tried different formats: mp4, ogg, wav, MP3. Every time it shows in the library as a m4a and yes I can play it in the library. If I drag it into an actor it shows a play music behavior but when I manually enter a play music behavior then I'm not able to select any music.

  • MattButlerStudiosMattButlerStudios Member Posts: 486

    Did you say that your tried dragging the audio file into your actor. If not, try that and it should automatically generate the code with the sound file selected.

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    No need to re-post... I moved your original thread to the PC subforum.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • JelmerHPJelmerHP Member Posts: 37

    Ah thanks @tatiang didn't know that was possible lol.

    @MattButlerStudios yes, that's what I tried but then a play music behavior appeared. Or does it not matter whether it is a play music or a play sound behavior?

  • MattButlerStudiosMattButlerStudios Member Posts: 486

    A sound behavior is used for quick, repetitive sounds and the music behavior is used for longer (not so frequent) sounds. Really the only reason you would have to use one over the other is in case you were using the in game sound/music volume controls.

  • JelmerHPJelmerHP Member Posts: 37

    Aah thank you for your help!

  • JelmerHPJelmerHP Member Posts: 37
    edited March 2015

    Alright, I added a new rule to one of my buttons saying:

    When mouse position is over the actor play music. I got the play music behavior by dragging in the music file. But when I place my mouse over the actor I hear nothing :/

  • JelmerHPJelmerHP Member Posts: 37

    Lol I finally found out what was wrong... I put it into the prototype instead of the instance

  • JelmerHPJelmerHP Member Posts: 37

    Uhm another problem. For the sound button I used
    When touch is pressed
    Change game.Audio.Sound Volume to 1-game.Audio.Sound Volume
    And the same for music.

    But my sound stays on if I click it. Or should I make a separate rule every time I want to use this sound saying if game.Audio.Sound Volume is 1 play music [sound]?

Sign In or Register to comment.