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
Question about scripting
w 1 z Offline
Junior Member

Posts: 4
Threads: 1
Joined: Sep 2010
Reputation: 0
#3
RE: Question about scripting

Well it fixed that issue but now for some reason the script is somehow disabled ie: it's not giving the lantern and tinderboxes now when I'm in Script debug mode and the encounter won't trigger with opening the door. The script compiles with no errors displaying on screen and in the debug messages the function isn't being called so there's something up

Here's how it is now

void OnStart()
{
SetEntityPlayerInteractCallback("castle_2", "FunctionToCall", true);
}
void FunctionToCall(string &in entity)
{
PlaySoundAtEntity("grunt_encounter", "/sounds/enemy/grunt/enabled02.ogg", "castle", 0, false);
SetEntityActive("servant_grunt", true);

    if(ScriptDebugOn())
    {
        GiveItemFromFile("lantern", "lantern.ent");

        for(int i=0;i<10;i++) GiveItemFromFile("tinderbox_"+i, "tinderbox.ent");
    }
}


void OnEnter()
{

}


void OnLeave()
{

}

Ok, the debug command for adding the lantern and tinderboxes is working now but there's still a problem. It's a little bit delayed for something which I'm not really worried about but the part I'm worried about is that the encounter still isn't triggering. I've looked over what I linked it to and it looks like everything should be in order. I might be missing a function or something somewhere.
09-17-2010, 03:57 AM
Find


Messages In This Thread
Question about scripting - by w 1 z - 09-17-2010, 03:08 AM
RE: Question about scripting - by MulleDK19 - 09-17-2010, 03:21 AM
RE: Question about scripting - by w 1 z - 09-17-2010, 03:57 AM
RE: Question about scripting - by Armored Cow - 09-17-2010, 04:36 AM
RE: Question about scripting - by w 1 z - 09-17-2010, 04:50 AM
RE: Question about scripting - by jens - 09-17-2010, 07:11 AM
RE: Question about scripting - by w 1 z - 09-17-2010, 07:39 AM
RE: Question about scripting - by Armored Cow - 09-17-2010, 03:40 PM
RE: Question about scripting - by jens - 09-17-2010, 04:21 PM
RE: Question about scripting - by Armored Cow - 09-17-2010, 04:40 PM
RE: Question about scripting - by jens - 09-17-2010, 05:45 PM
RE: Question about scripting - by MulleDK19 - 09-17-2010, 05:55 PM
RE: Question about scripting - by Armored Cow - 09-17-2010, 07:02 PM



Users browsing this thread: 1 Guest(s)