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


Thread Rating:
  • 1 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Variable help needed PLEASE :'(
X4anco Offline
Member

Posts: 157
Threads: 66
Joined: Apr 2011
Reputation: 0
#5
RE: Variable help needed PLEASE :'(

(05-21-2011, 10:07 PM)Kyle Wrote: Do you really need a global variable in this case?

In your "void OnStart()", you could add this: SetLocalVarInt("door1", 0);

Then the place where you set it to 1, put this: SetLocalVarInt("door1", 1); or AddLocalVarInt("door1", 1);

This is what the used1 function should look like.

void used1(string &in asParent, string &in asChild, int alState)
{
     if (GetLocalVarInt("door1") == 1)
     {
          SetSwingDoorLocked("metal_1", false, true);
          PlaySoundAtEntity("", "unlcok_door", "metal_1", 0, false);
          return;
     }
     else
     {
          PlayGuiSound("21/21_lever_fail.ogg", 1);
          SetMessage("Message", "mem8", 3);
          return;
     }
}
}


Still nothing happens SD@Angry:R{AP!!!!!!
*feels like screaming!

...
05-21-2011, 10:19 PM
Find


Messages In This Thread
Variable help needed PLEASE :'( - by X4anco - 05-21-2011, 08:58 PM
RE: Variable help needed PLEASE :'( - by X4anco - 05-21-2011, 10:03 PM
RE: Variable help needed PLEASE :'( - by Kyle - 05-21-2011, 10:07 PM
RE: Variable help needed PLEASE :'( - by X4anco - 05-21-2011, 10:19 PM
RE: Variable help needed PLEASE :'( - by Kyle - 05-22-2011, 12:31 AM



Users browsing this thread: 1 Guest(s)