![]() |
Need help with a script - 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: Need help with a script (/thread-21514.html) |
Need help with a script - Neelke - 05-16-2013 Theres something im missing or needs to be deleted. But since I cannot see it I would need some help. Here is the script: //------------------------------------------------------- /////////////////////////////////////////////// // HOLE OF NOWHERE /////////////////////////////////////////////// //------------------------------------------------------- void CollideHoleOfNowhere(string &in asParent, string &in asChild, int alState) { CheckPoint("", "PlayerStartArea_2", "CheckPoint2", "Hints", "DeathFallDownStudy"); PlaySoundAtEntity("fallaaaaaah", "11_fall", "Player", 0, false); PlaySoundAtEntity("fallaaaaaah2", "scare_male_terrified5", "Player", 0, false); FadeOut(0.5); AddTimer("death", 0.7f, "TimerFallDeath"); } void TimerFallDeath(string &in asTimer) { if(asTimer == "death"){ PlaySoundAtEntity("bump1", "player_bodyfall", "Player", 0, false); } void CheckPointFallWell(string &in asName, int alCount) { //Nothing special is supposed to happen } //------------------------------------------------------- /////////////////////////////////////////////// // FLOOD /////////////////////////////////////////////// //------------------------------------------------------- void GetFloodMessageQuest(string &in asParent, string &in asChild, int alState) { AddQuest("FloodSewerEntrace", "FloodSewerEntrace"); SetMessage("Messages", "FloodIsToDeep", 0); } //------------------------------------------------------- /////////////////////////////////////////////// // UNLOCKING THE CISTERN DOORS /////////////////////////////////////////////// //------------------------------------------------------- void InteractCisternA(string &in asEntity) { SetLevelDoorLockedText("", "Messages", "LockedCellDoorCells"); AddQuest("CisternLocked", "CisternLocked"); } void UnlockCisternA(string &in asItem, string &in asEntity) { PlaySoundAtEntity("", "unlock_door", "CisternA", 0, false); RemoveItem("CisternKeyA"); } //------------------------------------------------------- //////////////////////////// // Run first time starting map void OnStart() { //Loading screen SetupLoadScreen("LoadingText", "SewerEntrance_", 3, "loading_screen_sewerentrance.jpg"); PlayMusic("08_amb_success", false, 1, 1, 10, false); } //////////////////////////// // Run when entering map void OnEnter() { PlayMusic("16_amb", true, 1, 5, 0, true); ////////////////////////// //Use item AddUseItemCallback("","CisternKeyA", "CisternA", "UnlockCisternA", true); ////////////////////////// //Collide Callbacks AddEntityCollideCallback("Player", "AreaFloodMessageQuest", "GetFloodMessageQuest", true, 1); ////////////////////////// //In case the water flood has been drained if(GetGlobalVarInt("WaterHasBeenDrained")==1) { SetEntityActive("water_flood", false); SetEntityActive("block_box_1", false); SetEntityActive("AreaFloodMessageQuest", false); SetEntityActive("FloodSounds", false); } AutoSave(); } //////////////////////////// // Run when leaving map void OnLeave() { } RE: Need help with a script - Traggey - 05-16-2013 Wrong forum, moved. RE: Need help with a script - OriginalUsername - 05-16-2013 Could you give us the error message? RE: Need help with a script - Neelke - 05-16-2013 main (103, 2): ERR : Unexpected end of file RE: Need help with a script - Tomato Cat - 05-16-2013 PHP Code: void TimerFallDeath(string &in asTimer) You have a missing curly brace. |