Added new features. A few bugs are still around.