Frictional Games Forum (read-only)
game crash - 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: game crash (/thread-11789.html)



game crash - aqfitz622 - 12-11-2011


FATAL ERROR: Could not load script file 'custom_stories/Hotel/maps/Hotel.hps'!
main (9, 48) : ERR : Expected ')' or ','

heres my hotel.hps so far

void OnStart()

{
AddUseItemCallback("", "floortwokey", "mansion_9", "UsedKeyOnDoor", true);
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("mansion_9", false, true;
PlaySoundAtEntity("", "unlock_door", "mansion_9", 0, false);
RemoveItem("floortwokey");
}

void OnEnter()
{

}

void OnLeave()
{

}


RE: game crash - Dyloo - 12-11-2011

Quote:void OnStart()

{
AddUseItemCallback("", "floortwokey", "mansion_9", "UsedKeyOnDoor", true);
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("mansion_9", false, true);
PlaySoundAtEntity("", "unlock_door", "mansion_9", 0, false);
RemoveItem("floortwokey");
}

void OnEnter()
{

}

void OnLeave()
{

}
Here you are! Always check the ending of each line Smile ( Corrected part is red )