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
StrartMusic Work But not Stop
jessehmusic Offline
Senior Member

Posts: 423
Threads: 102
Joined: Dec 2011
Reputation: 8
#1
StrartMusic Work But not Stop

Hello all amnesia fans!
I got a problem with script and Lvl
I can't get stopmusic to work when you get back to the hallway Sad
Here is my hps:

(Cellarbase)


oid OnStart()
{
AddUseItemCallback("", "The Lost Key", "Lockeddoor_1", "KeyOnDoor", true);
AddUseItemCallback("", "Key", "ptest_cellar_wood01_4", "KeyOnDoor1", true);
AddEntityCollideCallback("Player", "MusicStart", "Music", true, 1);
AddEntityCollideCallback("Player", "DoorSlam", "DoorSlam", true, 1);
SetEntityPlayerInteractCallback("Note_Test1", "Sound", true);
}
void Sound(string &in asEntity)
{
PlaySoundAtEntity("", "15_prisoner_scream.snt", "Player", 0.0f, false);
}
void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Lockeddoor_1", false, true);
PlaySoundAtEntity("", "unlock_door", "Lockeddoor_1", 0, false);
RemoveItem("The Lost Key");
}
void KeyOnDoor1(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("ptest_cellar_wood01_4", false, true);
PlaySoundAtEntity("", "unlock_door", "ptest_cellar_wood01_4", 0, false);
RemoveItem("Key");
}

void DoorSlam(string &in asParent, string &in asChild, int alState)
{
CreateParticleSystemAtEntity("", "ps_break_wood_small.ps", "ps_hit", true);
PlaySoundAtEntity("", "break_wood.snt", "Player", 0.0f, false);
}
void Music(string &in asParent, string &in asChild, int alState)
{
PlayMusic("01_amb_darkness.ogg", true, 0.8f, 1, 0, true);
}

void OnEnter()

{

}

void OnLeave()

{

}



Hallway


void OnStart()
{
AddEntityCollideCallback("Player", "MusicStop", "StopMusic", true, 1);
}


void StopMusic(string &in asParent, string &in asChild, int alState)
{
StopMusic(1 , 1);
}


when i enter the StopMusic Area it dosnt work ;(

http://www.moddb.com/mods/jessehmusic - Hospital of horror , WIP
(This post was last modified: 02-28-2012, 12:27 AM by jessehmusic.)
02-27-2012, 06:59 PM
Website Find


Messages In This Thread
StrartMusic Work But not Stop - by jessehmusic - 02-27-2012, 06:59 PM
RE: StrartMusic Work But not Stop - by Mackiiboy - 02-28-2012, 06:44 AM



Users browsing this thread: 1 Guest(s)