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
Multiple Issues Help How to use key to unlock level door?
MissMarilynn Offline
Member

Posts: 77
Threads: 23
Joined: Oct 2011
Reputation: 1
#7
RE: How to use key to unlock level door?

(10-28-2011, 12:19 AM)Obliviator27 Wrote:
void OnStart()
{
         AddUseItemCallback("", "masterkey", "girlsdormfirstfloor", "UnlockDoor", true);
         SetEntityPlayerInteractCallback("masterkey", "SpawnMonster", true);
}
void UnlockDoor(string &in asItem, string &in asEntity)
{
        SetLevelDoorLocked("girlsdormfirstfloor", false);
        PlaySoundAtEntity("", "unlock_door.snt", "girlsdormfirstfloor", 0, false);
        RemoveItem("masterkey");
}
void SpawnMonster(string &in asEntity)
{
       SetEntityActive("servant_grunt_1", true);
       (Add Various Pathnodes here, if you like)
}
Is an example.
Ooh yay! I was close haha! How do I set it so that he notices you right away? ShowPlayerPosition?
10-28-2011, 12:34 AM
Find


Messages In This Thread
RE: How to use key to unlock level door? - by MissMarilynn - 10-28-2011, 12:34 AM



Users browsing this thread: 2 Guest(s)