changed many things
code cleaned, various fixes and updates