Lets say I need to compare the x position of a ball with the x position of a rectangle to see if they have collided. Wouldn't it be easier to just declare x in ball as public so I can use ball.x instead of ball.getX()?
Kuroshi 0 Light Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.