Exemple #1
0
 private void Press(object sender, MoveEventArgs e)
 {
     Pushed = true;
     OnPress?.Invoke(this, Color);
     GateBehavior.SendMessage(GateBehavior.GateMsg.Open, Color);
     pressingButton = sender;
 }
Exemple #2
0
    private void Unpress(object sender, MoveEventArgs e)
    {
        Pushed = false;

        OnUnpress?.Invoke(this, Color);
        GateBehavior.SendMessage(GateBehavior.GateMsg.Close, Color);
        pressingButton = null;
    }
Exemple #3
0
 private void OnDestroy()
 {
     TileMovingObjectScript.MoveableMoving -= Spongebob_PlayerPositionChanging;
     GateBehavior.SendMessage(GateBehavior.GateMsg.Close, Color);
 }