several fixes, added some modifications from old muJava++