Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Can't get door to lock using SetSwingDoorLocked("mansion_1", false, true)
house Offline
Member

Posts: 195
Threads: 11
Joined: Oct 2010
Reputation: 1
#7
RE: Can't get door to lock using SetSwingDoorLocked("mansion_1", false, true)

You should Add: AddDebugMessage("Type anything you want here", false);

What this does, it says something at the very bottom very left. It says the thing you typed in the AddDebugMessage. Its useful to see if its even doing anything. You need to have the Debug Messages activated. Activate it here: C:\Documents and Settings\"YOUR COMPUTER USER NAME\My Documents\Amnesia\Main\"YOUR AMNESIA PROFILE NAME"\user_settings.cfg
Open it with your favorite text editing program. I recommend Notepad++. But you can still use the Notepad thing. If you don't want to get Notepad++ or don't have it, right click the file, Click Open With, select Notepad, Uncheck 'Always use the selected program to open this kind of file' If you don't uncheck it. It will mess up .cfg's FOREVER! So uncheck it. Press OK. It will open the file. Find:
ShowDebugMessages="false" Make: "false" to "true". It will show the debug messages. There are other useful and useless stuff to set true and false in the file if you want. You can always go back in the file and change it.

Add the Debug Message Code like this in the void UsedKeyOnDoor:

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("mansion_1", false, true);
PlaySoundAtEntity("", "unlock_door", "mansion_1", 0, false);
RemoveItem("awesomekey_1");
AddDebugMessage("Type anything you want here", false);
}

This won't solve fixing the key not opening the door. This is just something to see if its even doing anything.
10-22-2010, 04:56 AM
Find


Messages In This Thread
RE: Can't get door to lock using SetSwingDoorLocked("mansion_1", false, true) - by house - 10-22-2010, 04:56 AM



Users browsing this thread: 1 Guest(s)