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


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[HELP] Padlocks
himynamebob1 Offline
Member

Posts: 57
Threads: 12
Joined: Jun 2012
Reputation: 0
#1
[HELP] Padlocks

I've got a padlock ready to operate on a door, but I don't know where to start!
07-08-2012, 05:53 AM
Find
heyitsrobert97 Offline
Member

Posts: 68
Threads: 29
Joined: Jan 2012
Reputation: 0
#2
RE: [HELP] Padlocks

(07-08-2012, 05:53 AM)himynamebob1 Wrote: I've got a padlock ready to operate on a door, but I don't know where to start!
Is it on the gate like in prisonbase or something like that with the space for the lock?
You can just carefully position it by turning snapgrid off in editor and slowly putting it into place.
Then duplicate the padlock and pull it forward so its out of the lock and set it inactive. then lock the door and when you need to open it (like with a key)

{
AddUseItemCallback("", "key", "door", "unlockdoor", true);
AddUseItemCallback("", "key", "padlock", "unlockdoor", true);

}

void unlockdoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("door", false, true);
PlaySoundAtEntity("", "unlock_door.snt", "door", 0.0f, false);
SetEntityActive("padlock", false);
SetEntityActive("padlock_1", true);
GiveSanityBoost();
}

This Darn House! , Four Doors, Youtube
07-08-2012, 08:47 AM
Find
himynamebob1 Offline
Member

Posts: 57
Threads: 12
Joined: Jun 2012
Reputation: 0
#3
RE: [HELP] Padlocks

Ahhh, okay thank you.
07-08-2012, 05:49 PM
Find




Users browsing this thread: 1 Guest(s)