04-11-2014, 09:19 PM
Hello Everyone
I've just started using HPL2 editor for amnesia and have started to create my own custom story. The only problem I have come up to with my coding is that when I click on my locked door a message should appear saying "This door is locked". I have gone through many different youtube videos and forums I cannot seem to find out why it is not working, if someone would be as kind as to read my code and tell me why I would be very grateful as i've spent over 2 hours trying to just make text appear on a door lol Dodgy
anyway here is my .hps file
void OnStart()
{
SetEntityPlayerInteractCallback("Locked_Door", "DoorLockedPlayer", false);
}
void DoorLockedPlayer(string &in asEntity)
{
SetMessage("Messages", "msgname", 10);
}
void OnEnter()
{
}
void OnLeave()
{
}
and here is my .lang file
<LANGUAGE>
<CATEGORY Name="CustomStoryMain">
<Entry Name="Description">
hello how are you?
</Entry>
</CATEGORY>
<CATEGORY Name=“Messages”>
<Entry Name=“msgname”>The door is locked</Entry>
</CATEGORY>
</LANGUAGE>
I've just started using HPL2 editor for amnesia and have started to create my own custom story. The only problem I have come up to with my coding is that when I click on my locked door a message should appear saying "This door is locked". I have gone through many different youtube videos and forums I cannot seem to find out why it is not working, if someone would be as kind as to read my code and tell me why I would be very grateful as i've spent over 2 hours trying to just make text appear on a door lol Dodgy
anyway here is my .hps file
void OnStart()
{
SetEntityPlayerInteractCallback("Locked_Door", "DoorLockedPlayer", false);
}
void DoorLockedPlayer(string &in asEntity)
{
SetMessage("Messages", "msgname", 10);
}
void OnEnter()
{
}
void OnLeave()
{
}
and here is my .lang file
<LANGUAGE>
<CATEGORY Name="CustomStoryMain">
<Entry Name="Description">
hello how are you?
</Entry>
</CATEGORY>
<CATEGORY Name=“Messages”>
<Entry Name=“msgname”>The door is locked</Entry>
</CATEGORY>
</LANGUAGE>