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
Making a lever unlock a door?
FlawlessHappiness Offline
Posting Freak

Posts: 3,980
Threads: 145
Joined: Mar 2012
Reputation: 171
#3
RE: Making a lever unlock a door?

void OnStart()
{
SetEntityConnectionStateChangeCallback("LEVER", "LEVER_CALLBACK");
}

void LEVER_CALLBACK(string &in asEntity, int alState)

{
if(alState == 1)
{
SetGlobalVarInt("OPENDOORINT", 1);
}
}

In the other level:

void OnEnter()
{
if(GetGlobalVarInt("OPENDOORINT") == 1)
{
SetSwingDoorLocked("DOOR", false, true);
}
}

Trying is the first step to success.
(This post was last modified: 07-13-2012, 08:18 PM by FlawlessHappiness.)
07-13-2012, 08:18 PM
Find


Messages In This Thread
Making a lever unlock a door? - by Wyz - 07-13-2012, 05:14 PM
RE: Making a lever unlock a door? - by FlawlessHappiness - 07-13-2012, 08:18 PM
RE: Making a lever unlock a door? - by Wyz - 07-13-2012, 08:40 PM
RE: Making a lever unlock a door? - by Ongka - 07-13-2012, 08:42 PM
RE: Making a lever unlock a door? - by Ongka - 08-04-2012, 04:34 AM



Users browsing this thread: 1 Guest(s)