many additions + fixes