diff -r fa778c206e7873abe53b4752143bbe6b22973ed5 -r 0737379cc88fd0efd394eccb737c91e1a8a6756d axios/Engine/SimpleDrawableAxiosGameObject.cs --- a/axios/Engine/SimpleDrawableAxiosGameObject.cs Sat Sep 22 14:19:45 2012 -0500 +++ b/axios/Engine/SimpleDrawableAxiosGameObject.cs Sat Sep 22 20:37:41 2012 -0500 @@ -19,6 +19,13 @@ protected Boolean _adjustunits = true; protected Boolean _relativetocamera = true; protected int _draworder; + protected bool _visible = true; + + public bool Visible + { + get { return _visible; } + set { this._visible = value; } + } @@ -38,16 +45,18 @@ public virtual void Draw(AxiosGameScreen gameScreen, GameTime gameTime) { - - if (_relativetocamera) - gameScreen.ScreenManager.SpriteBatch.Begin(0, null, null, null, null, null, gameScreen.Camera.View); - else - gameScreen.ScreenManager.SpriteBatch.Begin(); - if (_adjustunits) - DrawObject(gameScreen.ScreenManager.SpriteBatch, Texture, BodyPart, Origin, true, _scale); - else - DrawObject(gameScreen.ScreenManager.SpriteBatch, Texture, BodyPart, Origin, _scale); - gameScreen.ScreenManager.SpriteBatch.End(); + if (_visible) + { + if (_relativetocamera) + gameScreen.ScreenManager.SpriteBatch.Begin(0, null, null, null, null, null, gameScreen.Camera.View); + else + gameScreen.ScreenManager.SpriteBatch.Begin(); + if (_adjustunits) + DrawObject(gameScreen.ScreenManager.SpriteBatch, Texture, BodyPart, Origin, true, _scale); + else + DrawObject(gameScreen.ScreenManager.SpriteBatch, Texture, BodyPart, Origin, _scale); + gameScreen.ScreenManager.SpriteBatch.End(); + } } protected void DrawObject(SpriteBatch sb, Texture2D texture, Body body, Vector2 origin)