Ejemplo n.º 1
0
 void ContiuneButton()
 {
     if (!(Harness.GameCurrentLevel is Level00))
     {
         Harness.GameCurrentLevel.AsstesList.Remove(this);
         Harness.RefreshOutput();
     }
     else
     {
         Harness.LoadGame();
     }
 }
Ejemplo n.º 2
0
        public override void ClickedRight(Position mousePosition, Position relativeMousePosition)
        {
            foreach (var wire in ParentLine.WiresList)
            {
                Harness.GameCurrentLevel.AsstesList.Remove(wire);
            }
            Harness.RefreshOutput();

            ParentLine.PinA.isConnected = false;
            ParentLine.PinB.isConnected = false;

            ParentLine.WiresList.Clear();

            Harness.GameCurrentLevel.ConnectionsList.Remove(ParentLine);

            bool unlockA = true;
            bool unlockB = true;

            foreach (var pin in ParentLine.PinA.Element.PinsList)
            {
                if (pin.isConnected == true)
                {
                    unlockA = false;
                }
            }

            foreach (var pin in ParentLine.PinB.Element.PinsList)
            {
                if (pin.isConnected == true)
                {
                    unlockB = false;
                }
            }

            if ((unlockA) && (ParentLine.PinA.Element is Gate))
            {
                ParentLine.PinA.Element.IsMovable = true;
            }

            if ((unlockB) && (ParentLine.PinB.Element is Gate))
            {
                ParentLine.PinB.Element.IsMovable = true;
            }
        }
Ejemplo n.º 3
0
 void Back()
 {
     Harness.GameCurrentLevel.AsstesList.Remove(this);
     Harness.RefreshOutput();
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Changes Asset texture to first one
 /// </summary>
 public virtual void ChangeStateToLow()
 {
     CurrentTexture = 0;
     Harness.RefreshOutput();
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Changes Asset texture to another one
 /// </summary>
 public virtual void ChangeState()
 {
     CurrentTexture = (CurrentTexture + 1) % 2;
     Harness.RefreshOutput();
 }
Ejemplo n.º 6
0
 void Back()
 {
     Harness.GameCurrentLevel = new Level00();
     Harness.RefreshOutput();
 }