Fixed a few extremely annoying problems.