コード例 #1
0
ファイル: BoardBase.cs プロジェクト: vermeeca/Combat
 protected Block NewRectangleBlock(Vector2 position, int width, int height)
 {
     var block = new Block(game, null, position, width, height);
     return block;
 }
コード例 #2
0
ファイル: Bullet.cs プロジェクト: vermeeca/Combat
        private bool ObstacleHit(Block obstacle)
        {
            if (this.Intersects(obstacle))
            {
                this.Velocity *= this.DetermineVelocityAndSetPositionFrom(obstacle);

                return true;
            }

            return false;
        }