removes hungarian notiation, fixes multiple var declarations, simplifies methods