Frictional Games Forum (read-only)
HPS DOSNT WORK WITH MAP - Printable Version

+- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum)
+-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html)
+--- Forum: Custom Stories, TCs & Mods - Development (https://www.frictionalgames.com/forum/forum-38.html)
+---- Forum: Development Support (https://www.frictionalgames.com/forum/forum-39.html)
+---- Thread: HPS DOSNT WORK WITH MAP (/thread-14120.html)



HPS DOSNT WORK WITH MAP - jessehmusic - 03-20-2012

Hello i can't get why my hps dosnt work with my map

.LANG --->


<LANGUAGE>

<CATEGORY Name="CustomStoryMain">

<Entry Name="Description">You went out to take a walk but you gone lost , you found a house you knocked , no one open , but the door went open...you walk futher</Entry>

</CATEGORY>
<CATEGORY Name="Inventory">
<Entry Name="ItemName_Mansion Key">Mansion Key</Entry>
<Entry Name="ItemDesc_Mansion Key">The mansion door key</Entry>
</CATEGORY>

<CATEGORY Name="Journal">
<Entry Name="Note_Key1_Name">this is madness</Entry>
<Entry Name="Note_Key1_Text">[WRITTEN IN BLOOD][br][br]If you read this / if anyone read this , Please help me!!!, some one has broken in to my office and he took everything i had....and he took me as a slave... HELP ME !!!!! </Entry>
</CATEGORY>

</LANGUAGE>

HPS -->


void Onstart()
{
AddUseItemCallback("", "Mansion Key", "Locked_door", "KeyOnDoor", true);
}

void KeyOnDoor(string &in asItem, string &in asEntity)

{
SetSwingDoorLocked("Locked_door", false, true);
PlaySoundAtEntity("", "unlock_door", "Locked_door", 0, false);
RemoveItem("Mansion Key");
}


RE: HPS DOSNT WORK WITH MAP - DaAinGame - 03-20-2012

Two things I can think of.
1. Is your hps file named EXACTLY the same as your map? If your map name is Map1.map then the hps file needs to be Map1.hps
2. I'm not positive, but if you're getting a scripting error I'm guessing it'll be because you have a space in between Mansion and Key. I would rename it and try Mansion_Key. However, I don't know if you can have the space or not. Same goes to your .lang file. I would add a _ for the space so that its Mansion_Key.



RE: HPS DOSNT WORK WITH MAP - jessehmusic - 03-20-2012

(03-20-2012, 07:16 AM)DaAinGame Wrote: Two things I can think of.
1. Is your hps file named EXACTLY the same as your map? If your map name is Map1.map then the hps file needs to be Map1.hps
2. I'm not positive, but if you're getting a scripting error I'm guessing it'll be because you have a space in between Mansion and Key. I would rename it and try Mansion_Key. However, I don't know if you can have the space or not. Same goes to your .lang file. I would add a _ for the space so that its Mansion_Key.
My map is named 01.map and 01.hps dosnt work will try with "_"

__________________________________________________________
have tryed now dosnt work at all


RE: HPS DOSNT WORK WITH MAP - DaAinGame - 03-20-2012

Did you rename it both on your level editor and your .hps file? Or just one or the other?



RE: HPS DOSNT WORK WITH MAP - flamez3 - 03-20-2012

Maybe you should tell us what isn't working.


RE: HPS DOSNT WORK WITH MAP - jessehmusic - 03-20-2012

(03-20-2012, 07:34 AM)DaAinGame Wrote: Did you rename it both on your level editor and your .hps file? Or just one or the other?
Hps name--> 01.hps
Map Name --->01.map


RE: HPS DOSNT WORK WITH MAP - DaAinGame - 03-20-2012

I meant the mansion key lol. In the level editor its name should be Mansion_key and in your hps file it should be Mansion_key. They should both be the same. And yes what exactly is the issue? Are you getting a Fatal error when you load the map or is the key just not unlocking the door?



RE: HPS DOSNT WORK WITH MAP - jessehmusic - 03-20-2012

i have it still dosnt work :S
and donst get fetal error...

the hps dosnt load to The map :S


RE: HPS DOSNT WORK WITH MAP - DaAinGame - 03-20-2012

(03-20-2012, 07:44 AM)jessehmusic Wrote: i have it still dosnt work :S
and donst get fetal error...

the hps dosnt load to The map :S
Hmmm how odd. I'm guessing that both the .map file and the .hps file are in the same folder. If not go ahead and move them into the same folder, but I'm sure that they already are. Otherwise, maybe try renaming both your map and hps to something else like Map1 and see if that fixes the issue. If not then I have no clue what could be wrong.





RE: HPS DOSNT WORK WITH MAP - jessehmusic - 03-20-2012

(03-20-2012, 07:48 AM)DaAinGame Wrote:
(03-20-2012, 07:44 AM)jessehmusic Wrote: i have it still dosnt work :S
and donst get fetal error...

the hps dosnt load to The map :S
Hmmm how odd. I'm guessing that both the .map file and the .hps file are in the same folder. If not go ahead and move them into the same folder, but I'm sure that they already are. Otherwise, maybe try renaming both your map and hps to something else like Map1 and see if that fixes the issue. If not then I have no clue what could be wrong.
Going to test that !!
____________________
omg it work TY TY TY!!!!!