Hey guys,

I am making a block breaker type game.

One panel houses the background, and one panel has the bricks, paddle, and such. and the other has the background. In my main class when I add the panels in this order:

add(new BrickBoard());

the background image shows up over top of the bricks, and when I reverse it to:

add(new BrickBoard());

the bricks show up and the background is plain grey as per usual.

How can I fix this?

Thanks Jon

Edited by PhiberOptik: n/a

8 Years
Discussion Span
Last Post by PhiberOptik

Have you tried adding the brickboard to the panelbg rather than to the window?

Hi darkagn, thanks for the reply,

That is a great idea unfortunately it didn't do the trick.

I had another idea, maybe I could make the background on the brickboard slightly translucent...?

Any other ideas?


Hey sorry about the long reply time.

So I figured the best way to get this working properly is to merge it all into one panel, and I just need to get it to render the background first then the blocks, paddle, etc.


Altered the draw settings works great thanks guys!

Edited by PhiberOptik: n/a

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.