Frictional Games Forum (read-only)
How do i make a monster appear with a trigger (solution) - Printable Version

+- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum)
+-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html)
+--- Forum: Custom Stories, TCs & Mods (https://www.frictionalgames.com/forum/forum-35.html)
+--- Thread: How do i make a monster appear with a trigger (solution) (/thread-5103.html)

Pages: 1 2


RE: How do i make a monster appear with a trigger - TEJR - 02-10-2011

(10-18-2010, 08:06 PM)Kyle Wrote: Here ya go. "ScriptArea_1" is the name of the script area where you collide which causes the monster to spawn. "MonsterFunc1" is the name of the function used later on when you want to add to the script instead of it doing nothing. "servant_grunt" is the name of the monster that spawns. If you don't know how to actually place a scriptarea or to place and setup a monster, then ask me. Smile

void OnStart()
{
AddEntityCollideCallback("Player" , "ScriptArea_1" , "MonsterFunc1" , true , 1);
}
void MonsterFunc1(string &in asParent , string &in asChild , int alState)
{
SetEntityActive("servant_grunt" , true);
}

Ok thanke you but where i must put this text? (i mean this script)


RE: How do i make a monster appear with a trigger (solution) - Ongka - 02-10-2011

In the same folder as your map.
If your map is called "castle.map" the script file has to be "castle.hps".
You can edit those files with a texteditor.