Esempio n. 1
0
        /*
         * public Bullet(Vector2 position,float direction)
         * {
         *  objectDirection = direction;
         *  v_position = position;
         *  SetSprite("bullet");
         * //        depth = -10;
         * }
         */

        public Bullet(BulletModifiers gunBulletStats, Vector2 position, float direction)
        {
            objectDirection = direction;
            v_position      = position;
            bulletStats     = gunBulletStats;
            aliveTime       = bulletStats.lifespan;

            scale = new Vector2(bulletStats.width, bulletStats.height);

            SetSprite("bullet");
        }
Esempio n. 2
0
        /*
        public Bullet(Vector2 position,float direction)
        {
            objectDirection = direction;
            v_position = position;
            SetSprite("bullet");
        //        depth = -10;
        }
        */
        public Bullet(BulletModifiers gunBulletStats,Vector2 position, float direction)
        {
            objectDirection = direction;
            v_position = position;
            bulletStats = gunBulletStats;
            aliveTime = bulletStats.lifespan;

            scale = new Vector2(bulletStats.width, bulletStats.height);

            SetSprite("bullet");
        }