Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Need help with a script
Neelke Offline
Senior Member

Posts: 668
Threads: 82
Joined: Apr 2013
Reputation: 26
#1
Need help with a script

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()
{

}
05-16-2013, 05:41 PM
Find
Traggey Offline
is mildly amused

Posts: 3,257
Threads: 74
Joined: Feb 2012
Reputation: 185
#2
RE: Need help with a script

Wrong forum, moved.
05-16-2013, 06:51 PM
Find
OriginalUsername Offline
Posting Freak

Posts: 896
Threads: 42
Joined: Feb 2013
Reputation: 34
#3
RE: Need help with a script

Could you give us the error message?
05-16-2013, 06:57 PM
Find
Neelke Offline
Senior Member

Posts: 668
Threads: 82
Joined: Apr 2013
Reputation: 26
#4
RE: Need help with a script

main (103, 2): ERR : Unexpected end of file
05-16-2013, 08:00 PM
Find
Tomato Cat Offline
Senior Member

Posts: 287
Threads: 2
Joined: Sep 2012
Reputation: 20
#5
RE: Need help with a script

PHP Code: (Select All)
void TimerFallDeath(string &in asTimer)
{    
if(
asTimer == "death"){
PlaySoundAtEntity("bump1""player_bodyfall""Player"0false);


You have a missing curly brace.
05-16-2013, 09:15 PM
Find




Users browsing this thread: 1 Guest(s)