public BoxSprite() { this.name = BoxSprite.Name.Uninitialized; Debug.Assert(BoxSprite.poScreenRect != null); BoxSprite.poScreenRect.Set(0, 0, 1, 1); Debug.Assert(BoxSprite.poColor != null); BoxSprite.poColor.Set(1, 1, 1); // Here is the actual new this.poBoxSprite = new Azul.SpriteBox(poScreenRect, poColor); Debug.Assert(this.poBoxSprite != null); // Here is the actual new this.poLineColor = new Azul.Color(1, 1, 1); Debug.Assert(this.poLineColor != null); this.x = poBoxSprite.x; this.y = poBoxSprite.y; this.sx = poBoxSprite.sx; this.sy = poBoxSprite.sy; this.angle = poBoxSprite.angle; this.speedX = 0; this.speedY = 0; }
public BoxSprite() { //set the name; this.name = GameSprite.Name.Blank; Debug.Assert(pPrivScreenRect != null); Debug.Assert(defaultBoxColor_Red != null); //initialize default line color of all sprite box objects this.poLineColor = new Azul.Color(defaultBoxColor_Red); Debug.Assert(this.poLineColor != null); //initialize screen coordinates this.poScreenRect = new Azul.Rect(pPrivScreenRect); Debug.Assert(this.poScreenRect != null); //initialize azul sprite box this.poAzulSpriteBox = new Azul.SpriteBox(pPrivScreenRect, this.poLineColor); Debug.Assert(this.poAzulSpriteBox != null); //pull the coordinates this.x = poAzulSpriteBox.x; this.y = poAzulSpriteBox.y; this.sx = poAzulSpriteBox.sx; this.sy = poAzulSpriteBox.sy; this.angle = poAzulSpriteBox.angle; }
public override DLink Wash() { this.poAzulSpriteBox = null; this.name = Name.Uninitialized; this.color = null; return(this); }
public BoxSprite(Name name, float ag, float sx, float sy, float x, float y, float red, float green, float blue, float posx, float posy, float w, float h) { this.name = name; this.poRect = new Azul.Rect(posx, posy, w, h); this.poAzulSpriteBox = new Azul.SpriteBox(new Azul.Rect(posx, posy, w, h), new Azul.Color(red, green, blue)); this.poAzulSpriteBox.angle = ag; this.poAzulSpriteBox.sx = sx; this.poAzulSpriteBox.sy = sy; this.poAzulSpriteBox.x = x; this.poAzulSpriteBox.y = y; }
public SpriteBox() : base() { this.name = SpriteBaseName.Uninitialized; this.pAzulSpriteBox = new Azul.SpriteBox(); this.pLineColor = ColorFactory.Create(ColorName.White).pAzulColor; this.pScreenRect = new Azul.Rect(); this.x = 0.0f; this.y = 0.0f; this.sx = 1.0f; this.sy = 1.0f; this.angle = 0.0f; }
//--------------------------------------------------------------------------------------------------------- // Constructor //--------------------------------------------------------------------------------------------------------- public SpriteBox() : base() { Debug.Assert(SpriteBox.psTmpRect != null); SpriteBox.psTmpRect.Set(0, 0, 1, 1); Debug.Assert(SpriteBox.psTmpColor != null); SpriteBox.psTmpColor.Set(1, 1, 1); this.pAzulSpriteBox = new Azul.SpriteBox(psTmpRect, psTmpColor); Debug.Assert(this.pAzulSpriteBox != null); this.pLineColor = new Azul.Color(1, 1, 1); Debug.Assert(this.pLineColor != null); this.name = Name.Default; }
public SpriteBox() { this.cSpriteBoxName = SpriteBox.SpriteBoxName.Uninitilized; this.cSpriteBoxRect = new Azul.Rect(cDefScreenRect); this.cSpriteBoxColor = new Azul.Color(); // this.cSpriteBoxColor = cDefColor; Debug.Assert(this.cSpriteBoxColor != null); this.azulSpriteBox = new Azul.SpriteBox(this.cSpriteBoxRect, this.cSpriteBoxColor); Debug.Assert(this.azulSpriteBox != null); this.x = azulSpriteBox.x; this.y = azulSpriteBox.y; this.sx = azulSpriteBox.sx; this.sy = azulSpriteBox.sy; this.angle = azulSpriteBox.angle; }
//--------------------------------------------------------------------------------------------------------- // Constructor //--------------------------------------------------------------------------------------------------------- public BoxSprite() : base() // <--- Delegate (kick the can) { this.name = BoxSprite.Name.Uninitialized; Debug.Assert(BoxSprite.psTmpRect != null); this.ClearTmpRect(); Debug.Assert(BoxSprite.psTmpColor != null); this.ClearTmpColor(); // Here is the actual new this.poAzulSpriteBox = new Azul.SpriteBox(psTmpRect, psTmpColor); Debug.Assert(this.poAzulSpriteBox != null); // Here is the actual new //this.poLineColor = new Azul.Color(0, 0, 0); this.poLineColor = new Azul.Color(1, 1, 1); Debug.Assert(this.poLineColor != null); //this.poLineColorHolder = new Azul.Color(0, 0, 0); this.BaseSet(poAzulSpriteBox.x, poAzulSpriteBox.y, poAzulSpriteBox.sx, poAzulSpriteBox.sy, poAzulSpriteBox.angle); }
public BoxSprite() : base() { this.name = BoxSprite.Name.Unitialized; Debug.Assert(BoxSprite.psTempRect != null); BoxSprite.psTempRect.Set(0, 0, 1, 1); Debug.Assert(BoxSprite.psTempColor != null); BoxSprite.psTempColor.Set(1, 1, 1); this.poAzulSpriteBox = new Azul.SpriteBox(psTempRect, psTempColor); Debug.Assert(this.poAzulSpriteBox != null); this.poLineColor = new Azul.Color(1, 1, 1); Debug.Assert(this.poLineColor != null); this.x = poAzulSpriteBox.x; this.y = poAzulSpriteBox.y; this.sx = poAzulSpriteBox.sx; this.sy = poAzulSpriteBox.sy; this.angle = poAzulSpriteBox.angle; }
public BoxSprite() : base() { this.name = BoxSprite.Name.Uninitialized; Debug.Assert(BoxSprite.psTmpRect != null); BoxSprite.psTmpRect.Set(0, 0, 1, 1); Debug.Assert(BoxSprite.psTmpColor != null); BoxSprite.psTmpColor.Set(1, 1, 1); // Here is the actual new this.poAzulBoxSprite = new Azul.SpriteBox(psTmpRect, psTmpColor); Debug.Assert(this.poAzulBoxSprite != null); // Here is the actual new this.poLineColor = new Azul.Color(1, 1, 1); Debug.Assert(this.poLineColor != null); this.x = poAzulBoxSprite.x; this.y = poAzulBoxSprite.y; this.sx = poAzulBoxSprite.sx; this.sy = poAzulBoxSprite.sy; this.angle = poAzulBoxSprite.angle; }
//---------------------------------------------------------------------------------- // Constructor //---------------------------------------------------------------------------------- public BoxSprite() : base() { // delegates to SpriteBase for x, y, sx, sy, angle //specific to this class this.name = BoxSprite.Name.Uninitialized; Debug.Assert(BoxSprite.psTempRect != null); Debug.Assert(BoxSprite.psTempColor != null); BoxSprite.psTempRect.Set(0, 0, 1, 1); BoxSprite.psTempColor.Set(1, 1, 1); this.poAzulBoxSprite = new Azul.SpriteBox(psTempRect, psTempColor); Debug.Assert(this.poAzulBoxSprite != null); this.poLineColor = new Azul.Color(1, 1, 1); Debug.Assert(this.poLineColor != null); this.x = this.poAzulBoxSprite.x; this.y = this.poAzulBoxSprite.y; this.sx = this.poAzulBoxSprite.sx; this.sy = this.poAzulBoxSprite.sy; this.angle = this.poAzulBoxSprite.angle; }
public void SetAzulSpriteBox(Azul.SpriteBox newSpriteBox) { this.pAzulSpriteBox = newSpriteBox; }
public CollisionSprite(Azul.Rect rect) { collisionBox = new Azul.SpriteBox(rect, ColorFactory.instance.w.getColor()); }