Frictional Games Forum (read-only)

Full Version: I need quick help on custom story creating!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
So i started to do custom story yesterday. But i never done a map before so i dont know what to do. I got some few questions for you. Please give detail with your answer.
1) How do i make a key open a door or cabinet i want?
2) How do i test my custom map in-game?
3) How do i create notes and write things in it?

Also, can you show me a basic, easy tutorial about creating a map?
I want to do something that there are lots of enemies and you need to close doors, jump over barricades, (creature jumps on you when you open a door, cabinet)
Thanks!
You know, the reason i posted it on a forum is because i dont want to read everything they write. I just want the answers of my questions and someone to tell me. Not copying a link
They write everything you need, and if you are that lazy to read the actual answers which are written by the developers themselves, how are you going to make a good mod which needs a lot of hard work?
(02-21-2011, 08:31 PM)Tanshaydar Wrote: [ -> ]They write everything you need, and if you are that lazy to read the actual answers which are written by the developers themselves, how are you going to make a good mod which needs a lot of hard work?
This.

Because your too lazy to read the tutorials, we have to spend our time to explain you the basics?
Try to understand how the scripts work and you'll soon be able to do more complex things than just opening a door with a key.
Someone hold me, or I'm going to slap him.

Somehow, I link his behaviour to his excessive amount of CoD 4 playing hours. Is that just me?
Ten years old headshooter?
Ok, first of all, all the things you want to do, aren't done in the leveleditor but need scripting to work.

1) How do i make a key open a door or cabinet i want?

First, place a key somewhere on your map in the leveleditor and name it. (NAMEOFYOURKEY)
then open your .lang file and add:

Code:
<CATEGORY Name="Inventory">
      <Entry Name="ItemName_NAMEOFYOURKEY">KEYNAME</Entry>
      <Entry Name="ItemDesc_NAMEOFYOURKEY">KEYDESCRIPTION</Entry>
</CATEGORY>

Now open your .hps file and add:

Code:
void OnStart()
{
    AddUseItemCallback("", "NAMEOFYOURKEY", "NAMEOFYOURDOOR", "KeyOnDoor", true);
}

void KeyOnDoor(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("NAMEOFYOURDOOR", false, true);
    PlaySoundAtEntity("", "unlock_door.snt", "NAMEOFYOURDOOR", 0.0f, true);
}


2) How do i test my custom map in-game?

Create a folder in the custom_stories folder in your installed game folder.
Give it the name of your customstory. (MYCUSTOMSTORY)
inside that folder create:
- an extra_english.lang file
- an customstories.cfg file
- another folder with the name: maps
- inside the maps folder create a MYCUSTOMSTORY.hps file
- save your own created map in the 'maps' folder and name it MYCUSTOMSTORY.map
(make sure your .map and .hps files have the same name)

you can follow these tutorial videos to see what needs to be put into the specified files:
http://amnesia.treesoft.dk/tutorials/Cus...Setup1.wmv
http://amnesia.treesoft.dk/tutorials/Cus...Setup2.wmv
http://amnesia.treesoft.dk/tutorials/Cus...Setup3.wmv

Then fire up Amnesia.exe and select your custom story in the Custom Story menu.

3) How do i create notes and write things in it?

First put this in your .lang file:
Code:
<CATEGORY Name="Journal">
<Entry Name="Note_NAMEOFYOURNOTE_Name">NOTETITLE</Entry>
<Entry Name="Note_NAMEOFYOURNOTE_Text">NOTETEXT</Entry>
</CATEGORY

Now place a note somewhere on your map in the leveleditor and on the entity tab in the NoteText field, put: NAMEOFYOURNOTE.


that should be the most direct possible answers to your three questions.
the best thing is, is that you probably still don't have a clue on what to do. Tongue