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
Script Help Make a sound play when you pick up a note
Ongka Offline
Member

Posts: 225
Threads: 3
Joined: Nov 2010
Reputation: 20
#2
RE: Make a sound play when you pick up a note

void OnStart()
{
SetEntityCallbackFunc("NOTE_NAME", "FUNCTION_NAME", true);
}

void FUNCTION_NAME(string &in asEntity, string &in type)
{
PlaySoundAtEntity("", "soundfile.snt", "Player", 0, false);
//or for example
//PlayMusic("17_paper_herbert01.ogg", false, 0.6f, 0.5f, 10, false);
}
This should do the job.

[Image: 18694.png]
(This post was last modified: 07-21-2012, 11:23 AM by Ongka.)
07-21-2012, 11:23 AM
Find


Messages In This Thread
RE: Make a sound play when you pick up a note - by Ongka - 07-21-2012, 11:23 AM



Users browsing this thread: 1 Guest(s)