Facebook Twitter YouTube Frictional Games | Forum | Newsletter | Dev Blog | Dev Wiki | Support | Shelf | Store

Privacy Policy


Post Reply 
 
Thread Rating:
  • 2 Votes - 3 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[TUTORIAL] Custom Sounds Tutorial
Author Message
Stepper321 Offline
Senior Member

Posts: 265
Joined: Nov 2011
Reputation: 8
Post: #1
[TUTORIAL] Custom Sounds Tutorial
First off, you'll need an .ogg file. The way to create this is to have an audio file, does not matter wich one, open it in Audacity and Export it in your custom story's sound folder as .ogg extension.
Now right click and 'New->' and then .txt file.

Rename the .txt file to the name of your sound (example my name is lol.ogg, rename it to New Document.txt (or something) to lol.txt) open lol.txt and paste in:
<SOUNDENTITY>
<SOUNDS>      
<Main>          
<Sound File="lol.ogg" /> <!--here comes the name of your sound, mine is lol.ogg, keep the .ogg extension -->      </Main>  
</SOUNDS>  
<PROPERTIES Volume="5" MinDistance="1" MaxDistance="50" Random="0" Interval="0" FadeEnd="False" FadeStart="False" Stream="False" Loop="False" Use3D="false" Blockable="False" BlockVolumeMul="0.7" Priority="5" /> <!-- Keep this, only edit if you know what it means --></SOUNDENTITY>

now Press Save-As and save it as lol.snt (click 'text document (*.txt)' and select 'all files (*.*)')
Now you made a fully functional sound file for Amnesia: The Dark Descent.
I assume you know how to make a Script Area, (if not search the tutorial) and the callback func to do that

PlaySoundAtEntity("", "lol.snt", "Player", 0, false);


The first Variable is the Name of the sound, just the name, its not very usefull.
The second variable is the Name+Soundfile (.snt extension)
The tirth variable is the entity to be played at, Stereo speakers or 5.1 speakers are really cool for this. Player makes it do for all.
The rest you don't really need


Thanks for checking this Tutorial, goodbye Big Grin!
(This post was last modified: 02-13-2012 07:36 PM by Stepper321.)
02-12-2012 09:48 PM
Find all posts by this user Quote this message in a reply
JenniferOrange Offline
Senior Member

Posts: 428
Joined: Jun 2011
Reputation: 33
Post: #2
RE: [TUTORIAL] Custom Sounds Tutorial
Someone move this to the Articles section! D:
That first code box is a mess, omg. When you write the code, try switching to Source(It's the two sections above Font, one says Editor and the other says Source) because for whatever reason hitting the Enter key in Editor mode just doesn't work. Helpful though. Thanks. C:

[Image: button.png]
02-12-2012 09:52 PM
Find all posts by this user Quote this message in a reply
Your Computer Offline
SCAN ME!

Posts: 3,267
Joined: Jul 2011
Reputation: 223
Post: #3
RE: [TUTORIAL] Custom Sounds Tutorial
FYI: XML comments follow the syntax:
<!-- Comment goes here -->

Tutorials: From Noob to Pro
02-12-2012 09:54 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Bas Offline
Junior Member

Posts: 43
Joined: Feb 2012
Reputation: 0
Post: #4
RE: [TUTORIAL] Custom Sounds Tutorial
Thanks, this helped me out. c:
(This post was last modified: 02-12-2012 11:28 PM by Bas.)
02-12-2012 11:28 PM
Find all posts by this user Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)