Solved flickering render bug