Cleaned some code, option boxes work correctly.