pre trying to fix
init process successfully fixed
most bugs fixed, right now one left (undefined bug)