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
quick question. script fatal error small script
Hartmann Offline
Member

Posts: 52
Threads: 18
Joined: Jun 2012
Reputation: 0
#1
quick question. script fatal error small script

I get a Fatal error when i load this script. anyone see the mistak


void OnStart()

{
AddEntityCollideCallback("Player", "PlayerCollide", "MonsterFunction", true, 1);
}

void MonsterFunction(string &in asParent, string &in asChild, int alState)

{
SetEntityActive("servant_grunt_1", true);
}

////////////////////////////
// Run when leaving map
void OnLeave()
06-21-2012, 06:50 PM
Find
Apjjm Offline
Is easy to say

Posts: 496
Threads: 18
Joined: Apr 2011
Reputation: 52
#2
RE: quick question. script fatal error small script

Your are missing braces after OnLeave:
void OnStart()
{
AddEntityCollideCallback("Player", "PlayerCollide", "MonsterFunction", true, 1);
}

void MonsterFunction(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_grunt_1", true);
}

////////////////////////////
// Run when leaving map
void OnLeave()
{
/* You Need brackets after a function definition */
}
(This post was last modified: 06-21-2012, 06:54 PM by Apjjm.)
06-21-2012, 06:53 PM
Find
Hartmann Offline
Member

Posts: 52
Threads: 18
Joined: Jun 2012
Reputation: 0
#3
RE: quick question. script fatal error small script

(06-21-2012, 06:53 PM)Apjjm Wrote: Your are missing braces after OnLeave:
void OnStart()
{
AddEntityCollideCallback("Player", "PlayerCollide", "MonsterFunction", true, 1);
}

void MonsterFunction(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_grunt_1", true);
}

////////////////////////////
// Run when leaving map
void OnLeave()
{
/* You Need brackets after a function definition */
}
ty Big Grin
06-21-2012, 06:56 PM
Find




Users browsing this thread: 1 Guest(s)