Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

I haven't documented the music / sound functions of Adventuron much yet, but here is a simple example. Note that you can use a relative path of the mp3 file when it comes to the final build, but in testing, you either need to save off the game to the folder containing the mp3s (in order for sound to play), or you upload files to a server you own and point to that server in the testing phase.

'll try to document this better later ...


start_at = start_location
game_information {
   notes = Bell sound effect is Copyright of Author of Bell Sound + License Text.
} locations {
   start_location : location "Type \"BELL\" to play a bell sound." ;
} ######################################
#  On Startup                        #
###################################### on_startup {
   : play_music sound = "song_intro" ; // Starts playing music (no preload here)
   : print "Introduction text here !!!" ;
   : preload "incidental_bell"; // Will preload (in the background) an audio asset you may wish to use soon
   : press_any_key ;
   : stop_music ;
} on_command {
   : match "bell _"  {
      : play_sound sound="incidental_bell" ;
   }
} assets {
   sounds {
      ## Please attribute your sound effects in game_information / notes section.
      
      ## NOTE: You can also use relative paths here, and place the files in the zipfile you 
      //       upload to itch.
      
      ## Sound effects should start with incidental_
      incidental_bell : sound_sample "https://your.domain.here/bell.mp3" ;
      
      ## Music should start with song_
      song_intro      : sound_sample "https://your.domain.here/your_tune.mp3" ;
      
   }
}

Amazing, thanks a lot