How to create randomly generated, but static background elements within a draw loop

Here’s a link to my project …

I have created a partial work around by drawing a blue rectangle where my car passes on the screen, but that still doesn’t work well and I know it’s not the right solution. The only real solution I can think of is somehow creating a .jpg or .png with the stars already on it, but that’s not the solution I want either.

thanks for looking at it.

Mike