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
Script Help Global Varint With Lever
Adrianis Offline
Senior Member

Posts: 620
Threads: 6
Joined: Feb 2012
Reputation: 27
#2
RE: Global Varint With Lever

In the first map, you'll want a line in OnStart like ...
SetGlobalVarInt("OtherMapDoorUnlocked", 0);

Then, when the player uses the lever to unlock, you'll want
SetGlobalVarInt("OtherMapDoorUnlocked", 1);
(assuming 0 is locked and 1 is unlocked)

Now when the player goes over to the other map, in OnEnter, you have a line like

if (GetGlobalVarInt("OtherMapDoorUnlocked")==1) // if the door has been unlocked
{
      SetSwingDoorLocked("DoorName", false, true);
}

Change names where appropriate

01-25-2013, 02:01 PM
Find


Messages In This Thread
Global Varint With Lever - by No Author - 01-25-2013, 01:51 PM
RE: Global Varint With Lever - by Adrianis - 01-25-2013, 02:01 PM
RE: Global Varint With Lever - by The chaser - 01-25-2013, 02:02 PM
RE: Global Varint With Lever - by jens - 01-25-2013, 02:06 PM
RE: Global Varint With Lever - by No Author - 01-26-2013, 07:43 AM



Users browsing this thread: 1 Guest(s)