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
I can't get my script to work D:
Datguy5 Offline
Senior Member

Posts: 629
Threads: 25
Joined: Dec 2011
Reputation: 12
#4
RE: I can't get my script to work D:

(06-28-2012, 11:30 PM)Wrathborn771 Wrote:
(06-28-2012, 10:36 PM)Datguy5 Wrote: You dont seem to have any callback there.
Can you add what's missing then? :o
I accually have another function in that script, lemme post the full one for you to see:

void OnStart()
{
void Jump1(string& asName, string& asCallback);
}
Jump1("Player", "Thanks", "OnPickup");
{
SetEntityActive("bro_1", true);
AddTimer("", 200.4, "scared");
}
void scared(string &in asTimer)
{
SetEntityActive("bro_1", false);
AddEntityCollideCallback("Player", "bro_1", "collidemonster", true, 1);
}
void collidemonster(string &in asParent, string &in asChild, int alState)
{
StartCredits("29_amb_end_intense.ogg", true, "Ending", "MainCredits", 7);
}

Thanks for the reply Smile

P.S: I've played your CS Death Can Await. I must say, it was a masterpiece Wink I accually think it's one of my favorites. Big Grin
void OnStart()
{
SetEntityCallbackFunc("NAME OF THE ITEM", "Jump1");
AddEntityCollideCallback("Player", "NAME OF THE SCRIPT AREA", "collidemonster", true, 1);
}
void Jump1(string& asName, string& asCallback);
{
AddTimer("scared", 2.4, "Timer_1");
}
void Timer_1(string &in asTimer)
{
SetEntityActive("bro_1", false);
}
void collidemonster(string &in asParent, string &in asChild, int alState)
{
StartCredits("29_amb_end_intense.ogg", true, "Ending", "MainCredits", 7);
}
void OnEnter()
{
}
void OnLeave()
{
}
Try that.Im not sure it will work(i doubt)but test it and say what happened(including a error report if you get one).Also what are you trying to do here?I had no idea Big Grin And i presume that Jump1("Player", "Thanks", "OnPickup"); you tried that when player picks up something,something will happen.Replace the NAME OF THE ITEM with the name of your item(obviously),and the NAME OF THE SCRIPT AREA replace with the name of the script area the player collides with.And thanks for liking my FIRST custom story :3 Have you seen the second one im currently making?

06-29-2012, 12:01 AM
Find


Messages In This Thread
RE: I can't get my script to work D: - by Datguy5 - 06-28-2012, 10:36 PM
RE: I can't get my script to work D: - by Datguy5 - 06-29-2012, 12:01 AM
RE: I can't get my script to work D: - by Datguy5 - 06-30-2012, 03:39 PM
RE: I can't get my script to work D: - by EXAWOLT - 06-30-2012, 03:48 PM
RE: I can't get my script to work D: - by EXAWOLT - 06-30-2012, 04:49 PM
RE: I can't get my script to work D: - by Cruzore - 06-30-2012, 04:51 PM
RE: I can't get my script to work D: - by Cruzore - 07-01-2012, 12:25 AM
RE: I can't get my script to work D: - by Cruzore - 07-01-2012, 11:59 AM



Users browsing this thread: 2 Guest(s)