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
is it possible to...
Mudbill Offline
Muderator

Posts: 3,881
Threads: 59
Joined: Apr 2013
Reputation: 179
#2
RE: is it possible to...

Mainbreaker?

This seems very much possible to do, but your explanation seems a little lacking. Nevertheless I think I know what you mean.

What I suggest you do is add a script area over your middle button. Add an interaction to that area that displays the message with SetMessage, and use variables on the other buttons to check when both have been pressed.

PHP Code: (Select All)
void PressButton(string &in asEntity)
{
    if(
GetLocalVarInt("Button1") == && GetLocalVarInt("Button2") == 1) {
        
SetEntityActive("Area"false);
        return;
    }
    else 
SetLocalVarInt(asEntity1);


This script should be ran on both the buttons on the sides. It will add a variable when you press them, and, when both have been pressed, disables the area covering your main button. When that area is gone, you can now interact with it instead of the area.

PS: This script assumes that your buttons are named Button1 and Button2 exactly. If you use different names, put those in the variable names.

If you want the player to have to pull the lever as well before interacting with the main button, then instead of having SetEntityActive in the script above, move it to the script for that lever's ConnectionStateChangeCallback.

PHP Code: (Select All)
void PullLever(string &in asEntityint alState)
{
    if(
GetLocalVarInt("Button1") == && GetLocalVarInt("Button2") == 1) {
        
SetEntityActive("Area"false);
    }


(This post was last modified: 08-21-2014, 08:46 PM by Mudbill.)
08-21-2014, 08:41 PM
Find


Messages In This Thread
is it possible to... - by Amnesiaplayer - 08-21-2014, 07:43 PM
RE: is it possible to... - by Mudbill - 08-21-2014, 08:41 PM
RE: is it possible to... - by Amnesiaplayer - 08-21-2014, 08:47 PM
RE: is it possible to... - by Mudbill - 08-21-2014, 08:52 PM
RE: is it possible to... - by Amnesiaplayer - 08-21-2014, 08:54 PM
RE: is it possible to... - by Mudbill - 08-21-2014, 09:01 PM
RE: is it possible to... - by Amnesiaplayer - 08-21-2014, 09:04 PM
RE: is it possible to... - by FlawlessHappiness - 08-21-2014, 09:14 PM
RE: is it possible to... - by Amnesiaplayer - 08-21-2014, 09:17 PM
RE: is it possible to... - by Mudbill - 08-21-2014, 09:17 PM
RE: is it possible to... - by Mudbill - 08-21-2014, 09:18 PM
RE: is it possible to... - by Amnesiaplayer - 08-22-2014, 05:29 AM
RE: is it possible to... - by FlawlessHappiness - 08-22-2014, 07:17 AM
RE: is it possible to... - by Amnesiaplayer - 08-22-2014, 01:04 PM



Users browsing this thread: 1 Guest(s)