Esempio n. 1
0
 public void Draw(int layer, DrawingBlendingType blendingType)
 {
     if (_isActive)
     {
         DrawingManager.DrawOnLayer(_drawRequest, layer, blendingType);
     }
 }
Esempio n. 2
0
 public Sprite()
     : base()
 {
     _blendingType            = DrawingBlendingType.Alpha;
     _drawRequest             = default(DrawRequest);
     _drawRequest.tint        = Color.White;
     _drawRequest.scaleRatio  = Vector2.One;
     this.MaterialArea        = "";
     _useTilingSafeBorders    = false;
     this.AutoScroll          = false;
     this.AutoScrollSpeed     = 0;
     this.AutoScrollArea      = 0;
     this.AutoScrollVertical  = false;
     this.AutoScrollMirroring = false;
 }
Esempio n. 3
0
 public ParticleType()
 {
     _name                          = "New particle type";
     _material                      = IceCream.SceneManager.GlobalDataHolder.GetMaterial("DefaultMaterial");
     _texturePivot                  = new Vector2(0.5f);
     _freeParticles                 = new Queue <Particle>();
     _emissionTimerAccumulator      = 0;
     _useEmitterAngle               = false;
     _keepAspectRatio               = true;
     _attachParticlesToEmitter      = false;
     _blendingType                  = DrawingBlendingType.Alpha;
     _particleOrientationType       = ParticleOrientationType.Fixed;
     _fixedParticleOrientationAngle = 0;
     InitializeValues();
 }
Esempio n. 4
0
 public TextItem()
 {
     _blendingType = DrawingBlendingType.Alpha;           
     this.Tint = Color.White;
 }
Esempio n. 5
0
 public Sprite()
     : base()
 {
     _blendingType = DrawingBlendingType.Alpha;           
     _drawRequest = default(DrawRequest);
     _drawRequest.tint = Color.White;
     _drawRequest.scaleRatio = Vector2.One;
     this.MaterialArea = "";
     _useTilingSafeBorders = false;
     this.AutoScroll = false;
     this.AutoScrollSpeed = 0;
     this.AutoScrollArea = 0;
     this.AutoScrollVertical = false;
     this.AutoScrollMirroring = false;
 }
Esempio n. 6
0
 /// <summary>
 /// Draw on the requested layer
 /// </summary>
 /// <param name="drawRequest">The drawRequest to render</param>
 /// <param name="layer">The desired layer</param>
 public static void DrawOnLayer(DrawRequest drawRequest, int layer, DrawingBlendingType blendingType)
 {
     _layers[layer - 1].Draw(drawRequest, blendingType);
 }
Esempio n. 7
0
        public static void DrawFilledRectangle(int layer, Vector2 position, Vector2 size, Color color, DrawingBlendingType blendingType)
        {
            DrawRequest drawRequest = new DrawRequest(_pixelTexture, position, false, null, 0,
                                                      size, Vector2.Zero, false, color, false, false, null);

            DrawOnLayer(drawRequest, layer, blendingType);
        }
Esempio n. 8
0
 public ParticleType()
 {
     _name = "New particle type";
     _material = IceCream.SceneManager.GlobalDataHolder.GetMaterial("DefaultMaterial");
     _texturePivot = new Vector2(0.5f);
     _freeParticles = new Queue<Particle>();
     _emissionTimerAccumulator = 0;
     _useEmitterAngle = false;
     _keepAspectRatio = true;
     _attachParticlesToEmitter = false;
     _blendingType = DrawingBlendingType.Alpha;
     _particleOrientationType = ParticleOrientationType.Fixed;
     _fixedParticleOrientationAngle = 0;
     InitializeValues();            
 }
Esempio n. 9
0
 public TextItem()
 {
     _blendingType = DrawingBlendingType.Alpha;
     this.Tint     = Color.White;
 }
Esempio n. 10
0
 public void Draw(int layer, DrawingBlendingType blendingType)
 {
     if (_isActive)
     {
         DrawingManager.DrawOnLayer(_drawRequest, layer, blendingType);
     }
 }
Esempio n. 11
0
 /// <summary>
 /// Draw a DrawRequest on the specified blending sub layer
 /// </summary>
 /// <param name="drawRequest"></param>
 /// <param name="blendingType"></param>
 public void Draw(DrawRequest drawRequest, DrawingBlendingType blendingType)
 {
     // Forward the request to the correct layer
     _components[(int)blendingType].Draw(drawRequest);
 }
Esempio n. 12
0
 /// <summary>
 /// Draw on the requested layer
 /// </summary>
 /// <param name="drawRequest">The drawRequest to render</param>
 /// <param name="layer">The desired layer</param>
 public static void DrawOnLayer(DrawRequest drawRequest, int layer, DrawingBlendingType blendingType)
 {
     _layers[layer - 1].Draw(drawRequest, blendingType);
 }
Esempio n. 13
0
 public static void DrawFilledRectangle(int layer, Vector2 position, Vector2 size, Color color, DrawingBlendingType blendingType)
 {
     DrawRequest drawRequest = new DrawRequest(_pixelTexture, position,false, null, 0,
         size, Vector2.Zero, false, color, false, false, null);
     DrawOnLayer(drawRequest, layer, blendingType);
 }
Esempio n. 14
0
 /// <summary>
 /// Draw a DrawRequest on the specified blending sub layer
 /// </summary>
 /// <param name="drawRequest"></param>
 /// <param name="blendingType"></param>
 public void Draw(DrawRequest drawRequest, DrawingBlendingType blendingType)
 {
     // Forward the request to the correct layer
     _components[(int)blendingType].Draw(drawRequest);
 }