made some messages more readable, little algorithm fixex