Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Sounds...
tklamka Offline
Junior Member

Posts: 11
Threads: 5
Joined: Dec 2010
Reputation: 0
#1
Sounds...

How do the sounds work ? Even though there is no mistake in the script, some sounds get played, and some do not.

Eg., the line

PlaySoundAtEntity("", "23_saw2.snt", "Player", 0, false); does not work, but

PlaySoundAtEntity("", "pickaxe_hit.snt", "Player", 0, false); does work.


is there any rule in using sounds ? maybe som can not be played on " Player " ?

Any ideas ?
01-11-2012, 08:17 PM
Find
Tanshaydar Offline
From Beyond

Posts: 3,085
Threads: 17
Joined: Mar 2009
Reputation: 67
#2
RE: Sounds...

Moved to correct forum.
Sounds can be played on Player, that's not a problem. However, some sound files have different configurations. You can open up .snt files in any text editor to see them.

01-11-2012, 09:25 PM
Website Find
Statyk Offline
Schrödinger's Mod

Posts: 4,390
Threads: 72
Joined: Sep 2011
Reputation: 241
#3
RE: Sounds...

Are they in different functions? Because if so, it could be the whole function causing the issue... Post the functions (whole .hps) here?
01-11-2012, 09:35 PM
Find
tklamka Offline
Junior Member

Posts: 11
Threads: 5
Joined: Dec 2010
Reputation: 0
#4
RE: Sounds...


void UseSaw(string &in asItem, string &in asEntity)
{

SetEntityActive("Saw4", true);
PlaySoundAtEntity("", "23_saw2.snt", "Player", 0, false);
AddTimer("Timer1", 0.5, "Saw1");
AddTimer("Timer2", 1, "Saw2");
AddTimer("Timer3", 1.5, "Saw3");
AddTimer("Timer4", 2, "Saw4");



}

It definitely works, other commands work as they should
01-11-2012, 10:21 PM
Find
flamez3 Offline
Posting Freak

Posts: 1,281
Threads: 48
Joined: Apr 2011
Reputation: 57
#5
RE: Sounds...

(01-11-2012, 10:21 PM)tklamka Wrote: void UseSaw(string &in asItem, string &in asEntity)
{

SetEntityActive("Saw4", true);
PlaySoundAtEntity("", "23_saw2.snt", "Player", 0, false);
AddTimer("Timer1", 0.5, "Saw1");
AddTimer("Timer2", 1, "Saw2");
AddTimer("Timer3", 1.5, "Saw3");
AddTimer("Timer4", 2, "Saw4");



}

It definitely works, other commands work as they should
Did you restart Amnesia before trying it again?


01-12-2012, 02:20 AM
Find
tklamka Offline
Junior Member

Posts: 11
Threads: 5
Joined: Dec 2010
Reputation: 0
#6
RE: Sounds...

3 times Smile
01-12-2012, 03:45 PM
Find
Inurias Offline
Junior Member

Posts: 20
Threads: 0
Joined: Jan 2012
Reputation: 2
#7
RE: Sounds...

Like Tanshaydar already said, these sounds are using different configurations.

pickaxe_hit:
<PROPERTIES Volume="1" MinDistance="1" MaxDistance="10" Random="1" Interval="0" FadeEnd="False" FadeStart="False" Stream="false" Loop="false" Use3D="False" Blockable="False" BlockVolumeMul="0.5" Priority="0" />

23_saw2:
<PROPERTIES Volume="0.8" MinDistance="5" MaxDistance="40" Random="1" Interval="0" FadeEnd="False" FadeStart="False" Stream="false" Loop="True" Use3D="True" Blockable="False" BlockVolumeMul="0.5" Priority="0" />

I would try changing the distance and 3D properties or just using the same configuration for both. However, there may be another way to avoid doing that.

-Inurias
01-12-2012, 04:04 PM
Find




Users browsing this thread: 1 Guest(s)