The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



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 Sound when picking up an item
Darkaroth Offline
Junior Member

Posts: 11
Threads: 2
Joined: Feb 2012
Reputation: 0
#1
Sound when picking up an item

Hey all, i would like to know how you play the soundfile of the screaming man already got the sound file for it. ( already got the corpse male to appear when picking up the note too ). This is what i got so far:

////////////////////////////
// Run when entering map
void OnStart()
{
    AddUseItemCallback("", "key1", "mansiondoor1", "open", true);
    SetEntityCallbackFunc("offensiveletter", "OnPickup");
}

void open(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("mansiondoor1", false, true);
    PlaySoundAtEntity("", "unlock_door", "mansiondoor1", 0, false);
    RemoveItem("key1");
}

void OnPickup(string &in asEntity, string &in type)
{
    SetEntityActive("man1", true);
    PlaySoundAtEntity("", "15_the_big_scream1", "Player", 0, false);
}
(This post was last modified: 02-08-2012, 07:45 PM by Darkaroth.)
02-08-2012, 05:29 PM
Find


Messages In This Thread
Sound when picking up an item - by Darkaroth - 02-08-2012, 05:29 PM
RE: Sound when picking up an item - by Ermu - 02-08-2012, 07:47 PM
RE: Sound when picking up an item - by Darkaroth - 02-08-2012, 08:22 PM
RE: Sound when picking up an item - by Darkaroth - 02-08-2012, 08:57 PM



Users browsing this thread: 1 Guest(s)