added additional cube object, cleaned up code