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
Level Door error!
Radical Batz Offline
Posting Freak

Posts: 953
Threads: 145
Joined: Dec 2013
Reputation: 25
#1
Shocked  Level Door error!

I made the level door teleport me to another map, but whenever I click on the level door and loads the map it just gets me this error
and it's not the level door that does this error, even when i spawn in the map that the level door takes me too

"FATAL ERROR: Could not load script file 'custom stories/Lifeless_The Abandon/maps/C:/Program Files/Amnesia - Thew Dark Descent/ redist/ custom stories/Lifeless_ The Abandon/maps/ Lieless_The Abandon3.hps'! ExecuteString (1, 1):ERR :No matching signatures to 'onLeave()' main (1,2) :ERR :Expected identifier"

and here is the hps of the level door is supposed to teleport me to

voidOnStart()

{AddUseItemCallback("OpenDoor", "key_tomb_1", "level_celler_1", "UnlockLevelDoor",true);

}

voidOnEnter()
{

}


void UnlockLevelDoor(string &in item, &in entity)
{
SetLevelDoorLocked(Entity, false);
//RemoveItem(item);
}

////////////////////////////
// Run when entering map
void OnEnter()
{

}

////////////////////////////
// Run when leaving map
void OnLeave()
{

}
(This post was last modified: 01-05-2014, 09:38 AM by Radical Batz.)
01-04-2014, 12:11 PM
Find
Daemian Offline
Posting Freak

Posts: 1,129
Threads: 42
Joined: Dec 2012
Reputation: 49
#2
RE: HPS file won't work after using the lang file!? need help!!! QUICK!

Maybe the sanity boost is not doing anything because your sanity is full ?
I don't see any problem, try without your "check" variable.

And the level door may be locked?

(This post was last modified: 01-04-2014, 05:07 PM by Daemian.)
01-04-2014, 05:04 PM
Find
Radical Batz Offline
Posting Freak

Posts: 953
Threads: 145
Joined: Dec 2013
Reputation: 25
#3
RE: HPS file won't work after using the lang file!? need help!!! QUICK!

(01-04-2014, 05:04 PM)Amn Wrote: Maybe the sanity boost is not doing anything because your sanity is full ?
I don't see any problem, try without your "check" variable.

And the level door may be locked?

ok the sanity i got it working, but the level door is not locked, I made it to teleport to another map, but it gets me this message when ever it loads the other map! "FATAL ERROR: Could not load script file 'custom stories/Lifeless_The Abandon/maps/C:/Program Files/Amnesia - Thew Dark Descent/ redist/ custom stories/Lifeless_ The Abandon/maps/ Lifeless_The Abandon3.hps'! ExecuteString (1, 1):ERR :No matching signatures to 'onLeave()' main (1,2) :ERR :Expected identifier"
01-04-2014, 05:34 PM
Find
daortir Offline
Senior Member

Posts: 422
Threads: 9
Joined: Sep 2013
Reputation: 18
#4
RE: HPS file won't work after using the lang file!? need help!!! QUICK!

Well looks like you did something wrong with your onLeave function ^^. Could you give us the code lines around onLeave ?

01-04-2014, 05:35 PM
Find
Radical Batz Offline
Posting Freak

Posts: 953
Threads: 145
Joined: Dec 2013
Reputation: 25
#5
RE: Level Door error!

(01-04-2014, 05:35 PM)daortir Wrote: Well looks like you did something wrong with your onLeave function ^^. Could you give us the code lines around onLeave ?

I updated the post!
01-04-2014, 05:37 PM
Find
RaideX Offline
Member

Posts: 212
Threads: 33
Joined: May 2013
Reputation: 7
#6
RE: Level Door error!

not sure if that is correct but in the first line it should be

PHP Code: (Select All)
void OnStart () {

//code 



you forgot a 'space' Wink

If you don't draw first, you don't get to draw at all... -The False Shepherd
01-05-2014, 01:40 AM
Find
Romulator Offline
Not Tech Support ;-)

Posts: 3,628
Threads: 63
Joined: Jan 2013
Reputation: 195
#7
RE: Level Door error!

^ And In the OnEnter, you have voidOnEnter. Forgot a space there too Smile Refer to that same code above to fix that :3

Edit: Put all the stuff you'll need in a post below Tongue

Discord: Romulator#0001
[Image: 3f6f01a904.png]
(This post was last modified: 01-05-2014, 02:24 AM by Romulator.)
01-05-2014, 02:07 AM
Find
daortir Offline
Senior Member

Posts: 422
Threads: 9
Joined: Sep 2013
Reputation: 18
#8
RE: Level Door error!

No space between "OnStart" and "()" is needed though : ).

(This post was last modified: 01-05-2014, 02:10 AM by daortir.)
01-05-2014, 02:10 AM
Find
Romulator Offline
Not Tech Support ;-)

Posts: 3,628
Threads: 63
Joined: Jan 2013
Reputation: 195
#9
RE: Level Door error!

Try this. Should fix everything Smile
PHP Code: (Select All)
void OnStart()  //As pointed out by RaideX and daortir
{
AddUseItemCallback("OpenDoor""key_tomb_1""level_celler_1""UnlockLevelDoor"true);
}

//Removed the OnEnter() here, because there is one below :P

void UnlockLevelDoor(string &in asItemstring &in asEntity)  //Fixed referenced items
{
SetLevelDoorLocked(asEntityfalse);  //Changed Entity to asEntity
//RemoveItem(asitem);          //Changed to asItem. If you want it removed, remove the //.
}

////////////////////////////
// Run when entering map
void OnEnter()
{

}

////////////////////////////
// Run when leaving map
void OnLeave()
{



Discord: Romulator#0001
[Image: 3f6f01a904.png]
01-05-2014, 02:31 AM
Find
Radical Batz Offline
Posting Freak

Posts: 953
Threads: 145
Joined: Dec 2013
Reputation: 25
#10
RE: Level Door error!

I already fixed it before these comments, but your answers are still correct to make it get fixed! thanks anyway guys Smile
01-05-2014, 09:38 AM
Find




Users browsing this thread: 1 Guest(s)