Refactored drawing into separate file