[SCRIPT] The Capture Scene - Amnesia - 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 - Development (https://www.frictionalgames.com/forum/forum-38.html) +---- Forum: Development Support (https://www.frictionalgames.com/forum/forum-39.html) +---- Thread: [SCRIPT] The Capture Scene - Amnesia (/thread-18025.html) |
The Capture Scene - Amnesia - Melvin - 08-29-2012 I want a brute to slash the player, then a death text will show, then you wake up in another map. I searched over the internet for a long time. Could be that I wasn't searching for the right stuff, but I want to know how I do this. I've been looking into the original game script and map, but they weren't eye opening for me. thanks in advance, SmokeMelvin RE: The capture scene - Robby - 08-29-2012 (08-29-2012, 05:20 PM)SmokeMelvin Wrote: I want a brute to slash the player, then a death text will show, then you wake up in another map.You need to use a checkpoint here. Code: CheckPoint (string& asName, string& asStartPos, string& asCallback, string& asDeathHintCat, string& asDeathHintEntry); Call this with the same event that triggers the monster. Additional info: Code: asName - the internal name At the Callback section, add a "ChangeMap" script. Code is below. Code: ChangeMap(string& asMapName, string& asStartPos, string& asStartSound, string& asEndSound); If that helped, help me back with a +1. It's a fair trade. RE: The Capture Scene - Amnesia - Adny - 08-30-2012 Basic entity collide callback that adds the checkpoint based off what senor Nemet said: void OnStart() { AddEntityCollideCallback("Player", "Name_of_Area", "checkpoint", true, 1); } void checkpoint(string &in asParent, string &in asChild, int alState) { CheckPoint("", "Name_of_Start_Pos", "PlayerDeath", "", ""); } void PlayerDeath(string &in asName, int alCount) { ChangeMap("Name_of_Map.map", "Name_of_Start_Pos", "", ""); } You can change the type of callback, but be sure to change the callback syntax for "checkpoint" as well. Hope that helped. RE: The Capture Scene - Amnesia - Robby - 08-30-2012 (08-30-2012, 07:07 AM)andyrockin123 Wrote: Basic entity collide callback that adds the checkpoint based off what senor Nemet said:This should work. But I thought I'd let the lad figure it out. Since that's the way you learn how to script. |