How to Restart a Level? - 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: How to Restart a Level? (/thread-30094.html) |
How to Restart a Level? - Soon - 06-05-2015 Hello, I am creating a scene in which I want the player to learn through trial and error as they die. I want to make it so when the player dies, the entire level gets reloaded from the beginning. I am trying to avoid checkpoints because it ruins the scene I am trying to create, because if I use a checkpoint, it gives the player the feeling of being immortal, and not really scared of dying. However, I don't want to make death permanent like in Justine, as it would be infuriating for the player, given the length of my FC. I don't really see any way for this to be possible in the functions list. Anyone have any ideas? Thank you for your time. RE: How to Restart a Level? - FlawlessHappiness - 06-05-2015 So... You don't want the player to die. But you do want the level to reset when the player fails. So use a function when the player fails and then reset the level manually. ResetProp(string asName); can help you there. RE: How to Restart a Level? - Soon - 06-06-2015 (06-05-2015, 09:23 PM)FlawlessHappiness Wrote: So... You don't want the player to die. But you do want the level to reset when the player fails. Oh wow. I didn't even know resetting props was possible. Thanks! RE: How to Restart a Level? - Soon - 06-06-2015 fixed RE: How to Restart a Level? - FlawlessHappiness - 06-06-2015 Sometimes it's worth going to the The engine script's page and Ctrl+F searching something random. Like "reset". You may find something. RE: How to Restart a Level? - Mudbill - 06-07-2015 I would also recommend just skimming through the different functions on the page to see what is available. Lots of fun stuff there. RE: How to Restart a Level? - Darkfire - 06-07-2015 Use this (check engine scripts to know what it does) CheckPoint (string& asName, string& asStartPos, string& asCallback, string& asDeathHintCat, string& asDeathHintEntry); And then in the func that is called use this ChangeMap(string& asMapName, string& asStartPos, string& asStartSound, string& asEndSound); And use the same map. It might work. RE: How to Restart a Level? - FlawlessHappiness - 06-07-2015 (06-07-2015, 03:13 PM)Darkfire Wrote: Use this (check engine scripts to know what it does) Firstly (06-05-2015, 07:20 PM)Soon Wrote: I am trying to avoid checkpoints But I also think changing the map might not always be the solution, as some entities might have FullGameSave checked for later or earlier use. |