Moved some bools to enums to make the code more readable.