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
Insanity sound
Lars Offline
Junior Member

Posts: 13
Threads: 2
Joined: Jan 2015
Reputation: 0
#1
Insanity sound

In the original Amnesia game, they have some sound (something like the sound when you are insane) when you enter an area that is with a lot of bodies or with organic stuff. I took a look at the map and I thought it was because of an script area. So I removed it but the "insanity sound" was still there. The map I looked at was 23_torture_transept and in the torture rooms you could hear the sound. My question is what makes the sound?

Sorry for bad english*
04-02-2015, 04:19 PM
Find
Darkfire Offline
Senior Member

Posts: 371
Threads: 22
Joined: May 2014
Reputation: 15
#2
RE: Insanity sound

Why would you want to remove that sound ?

You have to delete AreaTerror arreaS, because there are a few of them, one for each room. In case the game crashes after that, you'd have to remove some script. I still can't understand why you want to do it 0_o

How it works: There's an area. In the "On start" section of the map's script there's an AddEntityCollideCallback func. This means that now when you enter(alState = 1), leave (alState = -1) or both (alState = 0) a function is executed. This func (search for CollideTerrorArea to see this function) starts the sound if you enter (if alState = 1) or stops it when you leave (it's the part after "else").

Look all functions here

https://wiki.frictionalgames.com/doku.ph..._functions

04-02-2015, 05:55 PM
Find
Lars Offline
Junior Member

Posts: 13
Threads: 2
Joined: Jan 2015
Reputation: 0
#3
RE: Insanity sound

(04-02-2015, 05:55 PM)Darkfire Wrote: Why would you want to remove that sound ?

You have to delete AreaTerror arreaS, because there are a few of them, one for each room. In case the game crashes after that, you'd have to remove some script. I still can't understand why you want to do it 0_o

How it works: There's an area. In the "On start" section of the map's script there's an AddEntityCollideCallback func. This means that now when you enter(alState = 1), leave (alState = -1) or both (alState = 0) a function is executed. This func (search for CollideTerrorArea to see this function) starts the sound if you enter (if alState = 1) or stops it when you leave (it's the part after "else").

Look all functions here

https://wiki.frictionalgames.com/doku.ph..._functions

I don't want to remove it. I want it in my custom story but I don't know how to get the sound at an area.
(This post was last modified: 04-02-2015, 07:30 PM by Lars.)
04-02-2015, 07:28 PM
Find
Daemian Offline
Posting Freak

Posts: 1,129
Threads: 42
Joined: Dec 2012
Reputation: 49
#4
RE: Insanity sound

I think what you want is this function GiveSanityDamage(10, true);.
Take that line to your mod and you should get the effect+sound.
Careful, 100 of Sanity Damage makes the player faint.

04-02-2015, 08:14 PM
Find
Darkfire Offline
Senior Member

Posts: 371
Threads: 22
Joined: May 2014
Reputation: 15
#5
RE: Insanity sound

Depends what exact sound he means. I thought of ui_torture.ogg

04-02-2015, 10:28 PM
Find
Lars Offline
Junior Member

Posts: 13
Threads: 2
Joined: Jan 2015
Reputation: 0
#6
RE: Insanity sound

Thanks but I have one more thingBig Grin. Again about the original story. When you get killed by a monster in the original story and respawn, the monster will still be there. It doesn't go away or anything. But in my custom story whenever I get killed by a monster and respawn, the monster isn't there anymore. This will make it a lot less scary because the player can just kill himself and run without any dangers through the map. So how did the original story respawn the monsters too just like the player?
04-04-2015, 03:46 PM
Find
Slanderous Offline
Posting Freak

Posts: 1,606
Threads: 78
Joined: Dec 2012
Reputation: 63
#7
RE: Insanity sound

(04-04-2015, 03:46 PM)Lars Wrote: Thanks but I have one more thingBig Grin. Again about the original story. When you get killed by a monster in the original story and respawn, the monster will still be there. It doesn't go away or anything. But in my custom story whenever I get killed by a monster and respawn, the monster isn't there anymore. This will make it a lot less scary because the player can just kill himself and run without any dangers through the map. So how did the original story respawn the monsters too just like the player?

Use checkpoints
04-04-2015, 04:44 PM
Find
Darkfire Offline
Senior Member

Posts: 371
Threads: 22
Joined: May 2014
Reputation: 15
#8
RE: Insanity sound

That's true. And I think you have to kind of reset the script, for example if you have AddEntityCollideCallback that triggers the monster, you'll have to use that script again in the checkpoint script, because it disappears after first usage. Like this:

Spoiler below!

void OnStart
{
AddEntityCollideCallback("Player", "ScriptArea", "FreeMonster", true, 1);
}

void FreeMonster(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("Monster", true);
CheckPoint ("aa", "PlayerStart_1", "CheckP", "Hints", "RespawnHint1");
}
void CheckP(string &in asName, int alCount)
{
AddEntityCollideCallback("Player", "ScriptArea", "FreeMonster", true, 1);
}



Say if you don't understand smth.

04-04-2015, 05:29 PM
Find
Lars Offline
Junior Member

Posts: 13
Threads: 2
Joined: Jan 2015
Reputation: 0
#9
RE: Insanity sound

(04-04-2015, 05:29 PM)Darkfire Wrote: That's true. And I think you have to kind of reset the script, for example if you have AddEntityCollideCallback that triggers the monster, you'll have to use that script again in the checkpoint script, because it disappears after first usage. Like this:

Spoiler below!

void OnStart
{
AddEntityCollideCallback("Player", "ScriptArea", "FreeMonster", true, 1);
}

void FreeMonster(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("Monster", true);
CheckPoint ("aa", "PlayerStart_1", "CheckP", "Hints", "RespawnHint1");
}
void CheckP(string &in asName, int alCount)
{
AddEntityCollideCallback("Player", "ScriptArea", "FreeMonster", true, 1);
}



Say if you don't understand smth.
So what you actually do is set a checkpoint when the monster spawns or at another point and within that function you reset the command wich calls in the monster by just putting in in there again.
(This post was last modified: 04-05-2015, 02:36 PM by Lars.)
04-05-2015, 02:36 PM
Find
Darkfire Offline
Senior Member

Posts: 371
Threads: 22
Joined: May 2014
Reputation: 15
#10
RE: Insanity sound

Yes: The function that I called "CheckP" is called when you die. You see, when the monster entity is activated, the invisible/unactive one reappears after the active one vanishes. At least that is how I see it; it also may reappear when you die. Anyway, you get the point. If you want to see how FG made it in original, go to map 24_torture_choir_east.

04-05-2015, 03:31 PM
Find




Users browsing this thread: 1 Guest(s)