public bool IsViewable(TransformableEntity e) { return IsViewable(e.Position); // TODO: Add hitbox testing too. }
public static void DrawTransformableEntity(this SpriteBatch spriteBatch, TransformableEntity transformableEntity, Texture2D texture, Rectangle sourceRectangle, SpriteEffects spriteEffects, float layerDepth) { spriteBatch.Draw(texture, transformableEntity.RenderPosition, sourceRectangle, transformableEntity.RenderColor, transformableEntity.RenderRotation, transformableEntity.RenderOrigin, transformableEntity.Scale, spriteEffects, layerDepth); }
public void Follow(TransformableEntity target) { if (target == null) return; Tracking = target; Mode = CameraMode.TrackTarget; }