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 are not playing
lolopon Offline
Junior Member

Posts: 10
Threads: 5
Joined: Oct 2011
Reputation: 0
#1
Sounds are not playing

Hi, me again Blush

Ok, now i have tried to make a sound play, and make the character react scared when entering an area, i have setup the script area and i have to assume i have messed up the scripting part somwhere.

Quote: ////////////////////////////
// Run first time starting map
void OnStart()
{
AddEntityCollideCallback("Player", "script_1", "Collidescript_1", true, 1);
}

void Collidescript_1(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "react_scare", "Player", 0, false);
PlaySoundAtEntity("", "insanity_baby_cry.snt", "Player", 0, false);
GiveSanityDamage(5.0f, true);
}
As the beginner i am, i can't really figure out wheter there is something wrong in the script here.
Care to help out? Angel

10-09-2011, 12:11 PM
Find
Khyrpa Offline
Senior Member

Posts: 638
Threads: 10
Joined: Apr 2011
Reputation: 24
#2
RE: Sounds are not playing

I can't see anything wrong in your script, perhaps the sound file names arent right... Does the sanity damage effect happen when you enter the area? If not then your script area is not named right and the Collidescript_1 doesn't trigger at all.

10-09-2011, 01:19 PM
Find




Users browsing this thread: 1 Guest(s)