fixed loading screen issues and cleaned up loading screen code
resolved merge conflicts