Level depth in various draw functions?

In animatedSprite.cs I have:

 public void Draw(SpriteBatch spriteBatch, Vector2 location)
        int width = Texture.Width / Columns;
        int height = Texture.Height / Rows;
        int row = (int)((float)currentFrame / (float)Columns);
        int column = currentFrame % Columns;
         Rectangle sourceRectangle = new Rectangle(width * column, height * row, width, height);
     Rectangle  destinationRectangle = new Rectangle((int)location.X, (int)location.Y, 120, 140);
        if (Game1.przelacznik_w_bezruchu == true) { sourceRectangle = new Rectangle(0, 0, width, height); }
        spriteBatch.Draw(Texture, destinationRectangle, sourceRectangle, Color.White);

In GameScene.cs:

  private void DrawGame()
        spriteBatch.Draw(floor1, rec_floor1, color1);
        spriteBatch.Draw(floor2, rec_floor2, color1);
        spriteBatch.Draw(house1, rec_house1,color1);

I want the floor and the house to be on a lower level than the sprite, so that they do not obscure the sprite. But I dont know how to assign depth levels to textures.

Take a look at this post:

It should help you with your problem.

I can’t use this function:

spriteBatch.Draw(texture: Pixel, destinationRectangle: new Rectangle(0, 0, 100, 100), color: Color.White, layerDepth: 0.2f)

Because I use this:

 spriteBatch.Draw(Texture, destinationRectangle, sourceRectangle, Color.White);

(texture, rectangle, rectangle, color) If I add LayerDepth, got a error

You can use the following overload:
Draw(Texture2D texture, Rectangle destinationRectangle, Rectangle? sourceRectangle, Color color,float rotation, Vector2 origin, SpriteEffects effects, float layerDepth)

To make it function identical to your current code, set the rotation to 0, origin to a zero vector, and SpriteEffects to SpriteEffects.None.