Hoot's right - it all depends on what type of gun it is. The specific parts that wear first or fastest or are most critical change depending on whether you are looking for a pump, a semi-auto or an O/U.
But for all guns... open the gun and work the action (ask how if you don't know how!), watch the parts move to and fro as you move them around. It is clean? Does anything look particularly worn or different from other used examples of the same model? Does it feel slightly stiff (good) or really loose (bad)? Does it lock up tight (good) or can you move the locked action (bad)?
Don't discount the external condition of a used gun, it is often an indication of how the insides were cared for. Handling marks are to be expected on a gun that was shot, and even scratches and scrapes are usual on a hunting gun. More than this and I'd only make an offer if I was looking for (another) restoring project.