示例#1
0
文件: Bit.cs 项目: himeiyuna/Raysist
        /// <summary>
        /// @brief コンストラクタ
        /// </summary>
        /// <param name="container">自身を組み込むコンテナ</param>
        /// <param name="player">親</param>
        /// <param name="position">初期位置</param>
        public Bit(GameContainer container, Player player, BitIndex index, GameContainer lazer)
            : base(container)
        {
            Energy = MaxEnergy;      // 2秒分
            Player = player;
            Index = index;
            ShotCounter = 0;
            Speed = 5.0f;

            Rot = 90;
            Angle = Rot * -(float)Math.PI / 180;
            Lazer = lazer;

            IsDock = true;

            if (index == BitIndex.BIT_LEFT)
            {
                Position.LocalPosition = new Vector3 { x = -10.0f, y = -5.0f, z = 0.0f };
                container.Name = "BitLeft";
            }
            else
            {
                Position.LocalPosition = new Vector3 { x = 10.0f, y = -5.0f, z = 0.0f };
                container.Name = "BitRight";
            }
        }
示例#2
0
        /// <summary>
        /// @brief コンストラクタ
        /// </summary>
        public FanShot(GameContainer container, float angle, Vector3 pos, Player p)
            : base(container, angle, pos, p)
        {
            Angle = angle;

            Magazine = 9;
            Theta = Angle / Magazine;
        }
示例#3
0
 /// <summary>
 /// @brief コンストラクタ
 /// </summary>
 public Barrage(GameContainer container, float angle, Vector3 pos, Player p)
     : base(container)
 {
     Position.LocalPosition = pos;
     Angle = angle;
     Speed = 5.0f;
     Magazine = 36;
     Count = 10;
     SpaceanInterval = Count;//360/Magazine 弾の間隔;
     AimFlag = false;
     PlayerPosition = p;
 }
示例#4
0
 /// <summary>
 /// @brief コンストラクタ
 /// </summary>
 public CircleShot(GameContainer container, float angle, Vector3 pos, Player p)
     : base(container, angle, pos, p)
 {
     Magazine = 18;
     space = (float)Math.PI / Magazine;
 }
示例#5
0
 public EnemyController(GameContainer container, Player p, ScoreComponent sc)
     : base(container, "enemy.csv")
 {
     PlayerPosition = p;
     SC = sc;
 }
示例#6
0
 /// <summary>
 /// @brief コンストラクタ
 /// </summary>
 /// <param name="from"></param>
 /// <param name="to"></param>
 public BehindAppearEnemyFactory(Vector3 to, Direction dir, float speed, Player pos, ScoreComponent sc)
     : base()
 {
     From = new Vector3 { x = to.x + 300.0f * (dir == Direction.LEFT ? -1 : 1), y = -500.0f, z = 0.0f };
     To = to;
     Speed = speed;
     PlayerPosition = pos;
     SC = sc;
 }
示例#7
0
 public InfrontAppearEnemyFactory(Vector3 to, Direction dir, int stayTime, Player pos, ScoreComponent sc)
 {
     To = to;
     Dir = dir;
     StayTime = stayTime;
     PlayerPosition = pos;
     SC = sc;
 }
示例#8
0
 /// <summary>
 /// @brief コンストラクタ
 /// </summary>
 public VerticalShot(GameContainer container, float angle, Vector3 pos, Player p)
     : base(container, angle, pos, p)
 {
     Angle = -(float)Math.PI * 0.5f;
 }
示例#9
0
文件: Bit.cs 项目: himeiyuna/Raysist
 public BitFactory(Player player, Bit.BitIndex index, Action<GameContainer> option = null)
     : base(option)
 {
     Player = player;
     Index = index;
 }