Esempio n. 1
0
 public static bool TogCollides(RoomScene room, bool toggleBR, bool isOn)
 {
     if (ToggleBlock.Toggled(room, toggleBR))
     {
         return(isOn);
     }
     return(!isOn);
 }
Esempio n. 2
0
        public override void Draw(RoomScene room, byte subType, int posX, int posY)
        {
            bool toggled = ToggleBlock.Toggled(room, this.toggleBR);

            if (toggled == isOn)
            {
                this.atlas.DrawFaceDown((ToggleBlock.Toggled(room, this.toggleBR) ? "ToggleOn" : "ToggleOff") + this.Texture, posX, posY);
            }
            else
            {
                this.atlas.DrawFaceDown((ToggleBlock.Toggled(room, this.toggleBR) ? "ToggleOn" : "ToggleOff") + this.Texture, posX - 2, posY - 2);
            }
        }
Esempio n. 3
0
 public override void Draw(RoomScene room, byte subType, int posX, int posY)
 {
     this.atlas.Draw((ToggleBlock.Toggled(room, this.toggleBR) ? "ToggleOn" : "ToggleOff") + this.Texture, posX, posY);
 }
Esempio n. 4
0
 public override void Draw(RoomScene room, byte subType, int posX, int posY)
 {
     this.atlas.Draw(this.Texture + (ToggleBlock.Toggled(room, this.toggleBR) ? "" : "Off") + (this.isDown ? "Down" : ""), posX, posY);
 }
Esempio n. 5
0
 public override void Draw(RoomScene room, byte subType, int posX, int posY)
 {
     // If Global Toggle is ON for Blue/Red, draw accordingly:
     this.atlas.Draw((ToggleBlock.Toggled(room, this.toggleBR) ? "ToggleOn" : "ToggleOff") + this.Texture, posX, posY);
 }