Ejemplo n.º 1
0
        public CArrow(DIRECTION direction, Vector2 velocity, Vector2 position, ARROW_TYPES arrowType = ARROW_TYPES.STANDARD)
            : base(direction, velocity, position)
        {
            _imageIndex.Add(PROJ_DOWN, new Graphics.CSprite(Graphics.CTextures.EFFECT_ARROW));
            _imageIndex.Add(PROJ_RIGHT, new Graphics.CSprite(Graphics.CTextures.EFFECT_ARROW_RIGHT));
            _imageIndex.Add(PROJ_LEFT, new Graphics.CSprite(Graphics.CTextures.EFFECT_ARROW_RIGHT, true, false));
            _imageIndex.Add(PROJ_UP, new Graphics.CSprite(Graphics.CTextures.EFFECT_ARROW, false, true));

            _arrowCount += 1;
            _name        = "arrow" + _arrowCount;

            _damage = 1;
            _transformArrowType(arrowType);

            startTimer1(60);
        }
Ejemplo n.º 2
0
        private void _transformArrowType(ARROW_TYPES arrowType)
        {
            switch (arrowType)
            {
            case ARROW_TYPES.STANDARD:
                _transformToStandard();
                break;

            case ARROW_TYPES.ICE:
                _transformToIce();
                break;

            case ARROW_TYPES.FIRE:
                _transformToFire();
                break;
            }
        }