PRESS SPACE TO HIDE/SHOW VARS to have an good render without bugs, press the "draw" button. It is due to scratch and flash. used this project here: https://scratch.mit.edu/projects/57695806/
Based on my 2d world generator.