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
I Need A Help Regarding The Lock Doors
Kyle Offline
Posting Freak

Posts: 911
Threads: 36
Joined: Sep 2010
Reputation: 7
#7
RE: I Need A Help Regarding The Lock Doors

Still got problems with that script?

Try this:

void OnStart()
{
     AddUseItemCallback("", "Door_1_Key", "Door_1", "UsedKeyOnDoor", true);
     AddUseItemCallback("", "Door_3_Key", "Door_3", "UsedKeyOnDoor", true);
     AddUseItemCallback("", "Door_4_Key", "Door_4", "UsedKeyOnDoor", true);
     AddUseItemCallback("", "Crowbar_1", "Door_5", "UsedKeyOnDoor", true);
     AddUseItemCallback("", "Door_6_Key", "Door_6", "UsedKeyOnDoor", true);
}
void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
     SetSwingDoorLocked(asEntity, false, true);
     PlaySoundAtEntity("", "unlock_door", asEntity, 0, false);
     RemoveItem(asItem);
}

It makes it much more simplified and easier to read. Smile

05-30-2011, 02:24 PM
Find


Messages In This Thread
RE: I Need A Help Regarding The Lock Doors - by Kyle - 05-30-2011, 02:24 PM



Users browsing this thread: 1 Guest(s)