[LVL ED] Door set to locked, still unlocked. - 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: [LVL ED] Door set to locked, still unlocked. (/thread-14008.html) |
Door set to locked, still unlocked. - Asaratha - 03-15-2012 Hello again. I have a door in my level called "sewer_arched_2", it is set to "Locked" in the Entity tab. I also have a script for a hollow needle on the door: void OnStart() { AddUseItemCallback("", "hollow_needle_1", "sewer_arched_2", "KeyOnDoor", true); } void KeyOnDoor(string &in asItem, string &in asEntity) { SetSwingDoorLocked("sewer_arched_2", false, true); PlaySoundAtEntity("", "unlock_door", "sewer_arched_2", 0, false); RemoveItem("hollow_needle_1"); } Any other script I have currently is working, as well as another key I have put in the "KeyOnDoor" function. If you would like to see my entire .hps file, I'll PM it to you. RE: Door set to locked, still unlocked. - ClayPigeon - 03-15-2012 What is the problem? I don't get it... If the problem is that the door is not unlocked, try this: void KeyOnDoor(string &in item, string &in door) { SetSwingDoorLocked(door, false, true); PlaySoundAtEntity("", "unlock_door", door, 0, false); RemoveItem(item); } Copy it as it is and don't change anything, tell me if it's unlocking now. RE: Door set to locked, still unlocked. - Asaratha - 03-15-2012 (03-15-2012, 02:34 PM)ClayPigeon Wrote: What is the problem? I don't get it... If the problem is that the door is not unlocked, try this:Oops, it seems I have forget to say the problem. Without unlocking the door, it's already unlocked. So, regardless of the fact I have it set to "Locked", it's always unlocked. RE: Door set to locked, still unlocked. - Stepper321 - 03-15-2012 (03-15-2012, 04:25 PM)Asaratha Wrote:try(03-15-2012, 02:34 PM)ClayPigeon Wrote: What is the problem? I don't get it... If the problem is that the door is not unlocked, try this:Oops, it seems I have forget to say the problem. Without unlocking the door, it's already unlocked. So, regardless of the fact I have it set to "Locked", it's always unlocked. for a swing door. Spoiler below!
or For level door Spoiler below!
RE: Door set to locked, still unlocked. - Asaratha - 03-15-2012 (03-15-2012, 04:33 PM)Stepper321 Wrote:The door is now locked, although, even if I use the hollow needle, the door is still locked.(03-15-2012, 04:25 PM)Asaratha Wrote:try(03-15-2012, 02:34 PM)ClayPigeon Wrote: What is the problem? I don't get it... If the problem is that the door is not unlocked, try this:Oops, it seems I have forget to say the problem. Without unlocking the door, it's already unlocked. So, regardless of the fact I have it set to "Locked", it's always unlocked. |