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
error after loading the custom story
Mudbill Offline
Muderator

Posts: 3,829
Threads: 59
Joined: Apr 2013
Reputation: 177
#2
RE: error after loading the custom story

Your syntax is wrong. This part is causing the script to fail:

PHP Code: (Select All)
{  
        
AddUseItemCallback("""Crowbar""Door""UseCrowbarOnDoor"true);
        
AddEntityCollideCallback("Joint""AreaBreak""BreakDoor"true1);


The reason is because you open this code block without a function declaration. This is required in the top level of the file.

It looks like you want these two callbacks to be created in OnStart, so I suggest you move them into your OnStart function and then remove the empty block left over, so that your OnStart looks like this:

PHP Code: (Select All)
void OnStart()
{
    
AddUseItemCallback("""key_tomb_rusty_1""level_hub_1""KeyOnLevelDoor"true);
    
AddUseItemCallback("""Crowbar""Door""UseCrowbarOnDoor"true);
    
AddEntityCollideCallback("Joint""AreaBreak""BreakDoor"true1);


(This post was last modified: 06-12-2019, 12:11 AM by Mudbill.)
06-12-2019, 12:10 AM
Find Reply


Messages In This Thread
RE: error after loading the custom story - by Mudbill - 06-12-2019, 12:10 AM



Users browsing this thread: 1 Guest(s)