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
Fatal error!
HumiliatioN Offline
Posting Freak

Posts: 1,179
Threads: 64
Joined: Dec 2010
Reputation: 18
#3
RE: Fatal error!

(07-12-2011, 02:37 PM)Dizturbed Wrote: i keep getting:

main (60,2) : ERR : Unexpected end of file


heres my code..


PHP Code: (Select All)
///////////////////////////
// Run first time starting map
void OnStart()
{
PlayMusic("amb_extra02.ogg"true54.0f0false); //Plays music.
AddEntityCollideCallback("Player""ScriptArea_1""monstuh"true0); //Calls a function when two entites collide.
AddEntityCollideCallback("crowbar_joint_1""BreakDoor""CollideAreaBreakDoor"true1);
SetEntityPlayerInteractCallback("key_study_1""monsterspawn"false); //Calls a function when the player interacts with a certain entity.
AddUseItemCallback("""crowbar_1""AreaUseCrowbar""UseCrowbar"true); //Allows the player to use items on the world.
}

// INTERACTKEY \\
void monsterspawn(string &in entity)
{
GiveSanityBoostSmall();
SetEntityActive("ScriptArea_1"true);
PlayGuiSound("enabled.snt"9.0f);
PlaySoundAtEntity("12_girl_scream""12_girl_scream.snt""Player"0false);
SetSwingDoorClosed("mansion_1"truetrue);
FadeOut(0.3);'
PlayGuiSound("scare_wall_stomp1.ogg", 5.0f);
PlayGuiSound("react_pant1.ogg", 7.0f);
}
void monstuh(string &in asParent, string &in asChild, int alState) 
{
SetEntityActive("enemy_1", true);
AddEnemyPatrolNode("enemy_1", "PathNodeArea_1", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_2", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_3", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_4", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_5", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_6", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_7", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_8", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_9", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_10", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_11", 0, "");
}

// CROWBAR EVENT \\
void UseCrowbar(string &in asItem, string &in asEntity)
{
SetEntityActive("crowbar_joint_1", true);
PlaySoundAtEntity("pickupcrow","player_crouch.snt", "Player", 0.05, false);
RemoveItem("crowbar_1");
SetEntityPlayerInteractCallback("AreaUseCrowbar", "", true);
}
void TimerSwitchShovel(string &in asTimer)
{
    PlaySoundAtEntity("","puzzle_place_jar.snt", asTimer, 0, false);
}
void CollideAreaBreakDoor(string &in asParent, string &in asChild, int alState)
{
    PlaySoundAtEntity("","joint_oven_open", "AreaBreakEffect", 0, false);
    CreateParticleSystemAtEntity("", "ps_hit_wood", "AreaBreakEffect", false);
    SetEntityActive("crowbar_joint_1", false);
    SetEntityActive("crowbar_dyn_1", true);
    SetEntityActive("AreaUseCrowbar", false);
    SetEntityActive("mansion_5", true);
}





Help meeee :( 


// Run first time starting map
void OnStart()
{
PlayMusic("amb_extra02.ogg", true, 5, 4.0f, 0, false); //Plays music.
AddEntityCollideCallback("Player", "ScriptArea_1", "monstuh", true, 0);
AddEntityCollideCallback("crowbar_joint_1", "BreakDoor", "CollideAreaBreakDoor", true, 1);
SetEntityPlayerInteractCallback("key_study_1", "monsterspawn", false);
AddUseItemCallback("", "crowbar_1", "AreaUseCrowbar", "UseCrowbar", true);
}

// INTERACTKEY \\
void monsterspawn(string &in entity)
{
GiveSanityBoostSmall();
SetEntityActive("ScriptArea_1", true);
PlayGuiSound("enabled.snt", 9.0f);
PlaySoundAtEntity("12_girl_scream", "12_girl_scream.snt", "Player", 0, false);
SetSwingDoorClosed("mansion_1", true, true);
FadeOut(0.3);'
PlayGuiSound("scare_wall_stomp1.ogg", 5.0f);
PlayGuiSound("react_pant1.ogg", 7.0f);
}

void monstuh(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("enemy_1", true);
AddEnemyPatrolNode("enemy_1", "PathNodeArea_1", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_2", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_3", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_4", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_5", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_6", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_7", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_8", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_9", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_10", 0, "");
AddEnemyPatrolNode("enemy_1", "PathNodeArea_11", 0, "");
}

// CROWBAR EVENT \\
void UseCrowbar(string &in asItem, string &in asEntity)
{
SetEntityActive("crowbar_joint_1", true);
PlaySoundAtEntity("pickupcrow","player_crouch.snt", "Player", 0.05, false);
RemoveItem("crowbar_1");
SetEntityPlayerInteractCallback("AreaUseCrowbar", "", true);
}

void TimerSwitchShovel(string &in asTimer)
{
PlaySoundAtEntity("","puzzle_place_jar.snt", asTimer, 0, false);
}

void CollideAreaBreakDoor(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("","joint_oven_open", "AreaBreakEffect", 0, false);
CreateParticleSystemAtEntity("", "ps_hit_wood", "AreaBreakEffect", false);
SetEntityActive("crowbar_joint_1", false);
SetEntityActive("crowbar_dyn_1", true);
SetEntityActive("AreaUseCrowbar", false);
SetEntityActive("mansion_5", true);
}

Couple errors, "No spaces on void "code parts" Try it now.



“Life is a game, play it”
07-12-2011, 09:48 PM
Find


Messages In This Thread
Fatal error! - by Dizturbed - 07-12-2011, 02:37 PM
RE: Fatal error! - by Luis - 07-12-2011, 09:40 PM
RE: Fatal error! - by HumiliatioN - 07-12-2011, 09:48 PM
RE: Fatal error! - by Roenlond - 07-12-2011, 09:54 PM
RE: Fatal error! - by Luis - 07-12-2011, 10:40 PM
RE: Fatal error! - by Roenlond - 07-12-2011, 10:50 PM
RE: Fatal error! - by Dizturbed - 07-12-2011, 11:08 PM
RE: Fatal error! - by Roenlond - 07-12-2011, 11:12 PM



Users browsing this thread: 2 Guest(s)