Frictional Games Forum (read-only)
FATAL ERROR ;___; - 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: FATAL ERROR ;___; (/thread-15755.html)



FATAL ERROR ;___; - tatthi - 06-01-2012

This is embarrassing but I'm getting a fatal error when launching my map and I don't know what's wrong. I've looked through my script (and the forums) a million times but can't find any solutions. It worked fine but then I added something that gave me an error so I deleted it and now my map won't load at all.

Code:
FATAL ERROR: Could not load script file 'custom_stories/tatthi/maps/terrorica.hps'! main (36, 1) : ERR : Expected ';'

My script:


void OnStart()
{
AddUseItemCallback("", "basement_key_1", "lockeddoor_1", "KeyOnDoor", true);
SetEntityCallbackFunc("basement_key_1", "OnPickup");
AddEntityCollideCallback("Player", "ScriptArea_1", "scare_2", true, 1);
AddEntityCollideCallback("Player", "ScriptArea_2", "FlyingBody", true, 1);
}

void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("lockeddoor_1", false, true);
PlaySoundAtEntity("", "unlock_door", "lockeddoor_1", 0, false);
RemoveItem("basement_key_1");
}

void OnPickup(string &in asEntity, string &in type)
{
SetEntityActive("corpse_1", true);
AddTimer("Scare", 0.25f, "Scare1");
PlaySoundAtEntity("", "21_screams.snt", "corpse_1", 0, false);
PlaySoundAtEntity("", "react_pant.snt", "Player", 0, false);
}

void Scare1(string &in asTimer)
{
GiveSanityDamage(10, true);
}

void scare_2(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("lockeddoor_1", true, true);
PlaySoundAtEntity("", "21_bang_door", "lockeddoor_1", 0, false);
AddTimer("timer2", 0.25f, "Scare2");
SetEntityActive("hanging_prisoner_1", true);
PlaySound
}

void Scare2(string &in asTimer)
{
GiveSanityDamage(5, true);
PlaySoundAtEntity("", "react_pant.snt", "Player", 0, false);
}

void FlyingBody(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("corpse_male_1", true);
PlaySoundAtEntity("", "21_screams.snt", "corpse_male_1", 0, false);
AddPropForce("corpse_male_1", 5000, 0, 0, "");
AddTimer("timer3", 0.25f, "scare3");
}

void scare3(string &in asTimer)
{
PlaySoundAtEntity("", "react_pant.snt", "Player", 0, false);
GiveSanityDamage(10, true);
}


RE: FATAL ERROR ;___; - Datguy5 - 06-01-2012

(06-01-2012, 12:33 PM)tatthi Wrote: void scare_2(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("lockeddoor_1", true, true);
PlaySoundAtEntity("", "21_bang_door", "lockeddoor_1", 0, false);
AddTimer("timer2", 0.25f, "Scare2");
SetEntityActive("hanging_prisoner_1", true);
PlaySound
}
What is that playsound?


RE: FATAL ERROR ;___; - tatthi - 06-01-2012

(06-01-2012, 12:58 PM)Datguy5 Wrote:
(06-01-2012, 12:33 PM)tatthi Wrote: void scare_2(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("lockeddoor_1", true, true);
PlaySoundAtEntity("", "21_bang_door", "lockeddoor_1", 0, false);
AddTimer("timer2", 0.25f, "Scare2");
SetEntityActive("hanging_prisoner_1", true);
PlaySound
}
What is that playsound?

I feel so stupid right now.. thanks for your trouble


RE: FATAL ERROR ;___; - Datguy5 - 06-01-2012

(06-01-2012, 01:06 PM)tatthi Wrote:
(06-01-2012, 12:58 PM)Datguy5 Wrote:
(06-01-2012, 12:33 PM)tatthi Wrote: void scare_2(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("lockeddoor_1", true, true);
PlaySoundAtEntity("", "21_bang_door", "lockeddoor_1", 0, false);
AddTimer("timer2", 0.25f, "Scare2");
SetEntityActive("hanging_prisoner_1", true);
PlaySound
}
What is that playsound?

I feel so stupid right now.. thanks for your trouble
Np dude Big Grin