Storfigge
Member
Posts: 101
Threads: 31
Joined: Sep 2012
Reputation:
0
|
Help with sound
Why wont this work? I've checked the forums and sat for a freaking hour trying to fix it -.- nothing seems to work? I've made an .snt file according to the wiki but again it wont work.
Heres the code
void OnStart()
{
AddEntityCollideCallback("Player", "Scream1", "sound", true, 1);
}
void sound(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "scream.ogg", "Player", 0, true);
}
void OnEnter()
{
}
void OnLeave()
{
}
|
|
12-18-2012, 02:04 PM |
|
The chaser
Posting Freak
Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation:
113
|
RE: Help with sound
(12-18-2012, 02:04 PM)Storfigge Wrote: Why wont this work? I've checked the forums and sat for a freaking hour trying to fix it -.- nothing seems to work? I've made an .snt file according to the wiki but again it wont work.
Heres the code
void OnStart()
{
AddEntityCollideCallback("Player", "Scream1", "sound", true, 1);
}
void sound(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "scream.snt", "Player", 0, true);
}
void OnEnter()
{
}
void OnLeave()
{
} Sounds extension is .snt, not .ogg. That one is for music. The .snt format is a text format with a sound file (an .ogg) and it gives it some certain properties (loop, volume, etc)
THE OTHERWORLD (WIP)
Aculy iz dolan.
|
|
12-18-2012, 02:11 PM |
|
Storfigge
Member
Posts: 101
Threads: 31
Joined: Sep 2012
Reputation:
0
|
RE: Help with sound
(12-18-2012, 02:11 PM)The chaser Wrote: (12-18-2012, 02:04 PM)Storfigge Wrote: Why wont this work? I've checked the forums and sat for a freaking hour trying to fix it -.- nothing seems to work? I've made an .snt file according to the wiki but again it wont work.
Heres the code
void OnStart()
{
AddEntityCollideCallback("Player", "Scream1", "sound", true, 1);
}
void sound(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "scream.snt", "Player", 0, true);
}
void OnEnter()
{
}
void OnLeave()
{
} Sounds extension is .snt, not .ogg. That one is for music. The .snt format is a text format with a sound file (an .ogg) and it gives it some certain properties (loop, volume, etc) Lol I thought I tried .snt earlier but apparently I hadn't thanks!
|
|
12-18-2012, 02:35 PM |
|
|