Zaffre
Posting Freak
Posts: 867
Threads: 50
Joined: Jul 2012
Reputation:
30
|
RE: Problem with "extra_english.lang"
Hm... your file seems to be lacking in some parts. Here's how it should be written.
<LANGUAGE>
<CATEGORY Name="Messages">
<Entry Name="lockeddoor1">This door is locked.
</CATEGORY>
</LANGUAGE>
You also need the appropriate coding. For instance, let's presume that the name of a door is "mansion_1", and you want it to display the callback. You'll need to type this.
void OnStart()
{
SetEntityPlayerInteractCallback("mansion_1", "DoorLockedMsg", true);
}
void DoorLockedMsg(string &in entity)
{
SetMessage("Messages", "lockeddoor1", 0);
}
It helps if you can explain the coding like it would be in a conversation. What this code says is that when the map starts, it will add a callback for interacting with the door named "mansion_1". That callback asks the category "Messages" in the file "extra_english.lang", to display the entry "lockeddoor1" for a predetermined amount of time.
This should work. Also, if the coding is correct, check for typos in your extra_english.lang file. I often forget to put quotes or the </Entry> after I finish an entry.
Hope this helps.
As of September 2nd, 2014, I've left the Frictional forums. Check my profile for more details.
|
|
09-03-2012, 01:58 AM |
|