Refactored a bit and added a function for creating a basic shape.