Frictional Games Forum (read-only)
[CHAOS] Player respawns in the first playerstart position!! - 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: [CHAOS] Player respawns in the first playerstart position!! (/thread-26542.html)



Player respawns in the first playerstart position!! - Radical Batz - 10-04-2014

I've been having this stupid ass problem since my first cs and there is no way this can be solved cause it has been bugging me for ages.

What I made in this map is I made one room with an acid bath, if u fall in u die and then respawn in the first playerstart position which is near the acid bath, when u keep going further there will be a chase scene by a ghost, now if this ghost kills u it will load a second checkpoint but all of a sudden i respawn back at the first startpostion where the acid bath was not the 2nd one and yes I named the playerstart positions correctly and checked multiple times.

Now if I don't die from the acid bath it doesn't load the first checkpoint and if I die first by the ghost instead of the bath, the second checkpoint works and respawns me in the 2nd playerpostiton but whenever I die in the acid bath which loads the first checkpoint then it doesn't work and it keeps loading me back to the first one. which is pretty annoying, any fix for this pls??

If u wanna take a look at the script, then here she is.
PHP Code:
First checkpoint
void collideDIE
(string &in asParentstring &in asChildint alState
{
    
PlaySoundAtEntity("DIIIIIIIIE""fire_damage_custom""Player"0.5false);
    
AddTimer("" ,1,"damage");
    
GivePlayerDamage(20""truetrue);
    
CheckPoint ("""PlayerStartArea_2""Checkpoint01""Hints""death");
    
AddDebugMessage("SOMETHING SOMETHING"false);

Second Checkpoint
void BeginRun
(string &in asTimer)
{
    
PlayMusic("Psycho1.ogg"true,10.10false);
    
SetEntityActive("crude_man_chains_statue_ghost_2"true);
    
AddTimer("fuck"0.3"fuck");
    
CheckPoint ("""PlayerStartArea_4""respawn""Hints""death");
     
FadeImageTrailTo(1.31);
    
FadeRadialBlurTo(0.14);
    
SetEntityActive("Die"true);
    
AddEntityCollideCallback("Player""ScriptArea_4""Diecollide"false1);
    
StopPlayerLookAt();
    
PlaySoundAtEntity("boo""sanity_damage""Player"0.1false);
    
AddTimer("RUN2"0.4"RUN2");
    


What makes the player die in the ghost chase scene is script areas going active in a loop, now I heard that u put the checkpoint before u die but still doens't do the tirck?

Any tips guys would be appreciated. thnx Blush


RE: Player respawns in the first playerstart position!! - Neelke - 10-04-2014

The two CheckPoint scripts have been set to different start areas? Have you noticed that?