示例#1
0
文件: Tourch.cs 项目: JonECG/Brogue
 public Tourch(Direction setDirection, Microsoft.Xna.Framework.Color setColor, int filck, float strength)
 {
     directionFacing = setDirection;
     flickerWait = filck;
     intensity = strength;
     color = setColor;
 }
示例#2
0
文件: Tourch.cs 项目: JonECG/Brogue
 public Tourch(Direction setDirection, Microsoft.Xna.Framework.Color setColor)
 {
     directionFacing = setDirection;
     flickerWait = 8;
     intensity = 1;
     color = setColor;
 }
示例#3
0
文件: Chair.cs 项目: JonECG/Brogue
 public Chair(Direction whereToFace)
 {
     isSolid = false;
     directionFacing = whereToFace;
     directionFacing = directionFacing.Rotate(true);
     directionFacing = directionFacing.Rotate(true);
 }
示例#4
0
 public HiddenPassage(HiddenPassage exitPosition, Direction directionToFace)
 {
     isSolid = true;
     isVisiable = false;
     other = exitPosition;
     other.other = this;
     directionFacing = directionToFace;
 }
示例#5
0
文件: Enemy.cs 项目: JonECG/Brogue
        /// <summary>
        /// Attacks the current target based on its attack
        /// </summary>
        protected void Attack(Direction d, bool turnable = true)
        {
            if (IsAggro)
            {
                target.TakeDamage(attack, this);
                if (element != null)
                {
                    target.DealElementalDamage(element, (1 + Engine.Engine.currentLevel.DungeonLevel / 3));
                }
            }

            if (turnable)
            {
                eSprite.Direction = d;
            }
        }
示例#6
0
文件: Enemy.cs 项目: JonECG/Brogue
        /// <summary>
        /// Moves a single square based on a Direction
        /// </summary>
        /// <param name="d">Direction</param>
        /// <param name="level">The current level</param>
        public void Move(Direction d, Level level)
        {
            if (IsAggro)
            {
                level.Move(this, d);
            }

            d = GetCorrectDirection(d);

            eSprite.Direction = d;
        }
示例#7
0
文件: Enemy.cs 项目: JonECG/Brogue
        public Direction GetCorrectDirection(Direction d)
        {
            if (d == Direction.DOWN)
            {
                d = Direction.LEFT;
            }
            else if (d == Direction.UP)
            {
                d = Direction.RIGHT;
            }
            else if (d == Direction.LEFT)
            {
                d = Direction.UP;
            }
            else if (d == Direction.RIGHT)
            {
                d = Direction.DOWN;
            }

            return d;
        }
示例#8
0
文件: Door.cs 项目: JonECG/Brogue
 public Door(Direction setDirection)
 {
     isSolid = true;
        isOpen = false;
        directionFacing = setDirection;
 }
示例#9
0
 public HiddenPassage(Direction directionToFace)
 {
     isSolid = true;
     isVisiable = false;
     directionFacing = directionToFace;
 }
示例#10
0
文件: Swiches.cs 项目: JonECG/Brogue
 public Switch(List<IInteractable> actingOnTargets, Direction directionToFace)
 {
     active = false;
     isSolid = false;
     isPassable = false;
     directionFacing = directionToFace;
     targets = actingOnTargets;
 }
示例#11
0
文件: Swiches.cs 项目: JonECG/Brogue
 public Switch(IInteractable actingOn, Direction directionToFace)
 {
     active = false;
     isSolid = false;
     isPassable = false;
     directionFacing = directionToFace;
     targets = new List<IInteractable>();
     targets.Add(actingOn);
 }