Made x and y private and created getters+setters