The killing of Candy's old dog is a good example of Steinbeck's naturalism. He wanted to demonstrate that there was a gun available. He wanted George to see it, know where it was kept, and how to fire it. The whole episode of Carlson shooting Candy's dog is intended to establish the existence of a German Luger in a "naturalistic" manner. George can't help seeing where Carlson keeps the Luger pistol and how he works the mechanism.
Carlson found a little cleaning rod in the bag and a can of oil. He laid them on his bed and then brought out the pistol, took out the magazine and snapped the loaded shell from the chamber. Then he fell to cleaning the barrel with the little rod.
A Luger is a distinctive-looking handgun. When George pulls it out of his jacket at the campsite, the reader will know that it belongs to Carlson and that George must have stolen it with the intention of shooting Lennie. When Carlson is talking Candy into letting him shoot the dog, he explains how he can do it painlessly with one shot at a certain point on the back of the head. George uses this knowledge to shoot Lennie in the same place. It seems as if George has acquired his knowledge of the location of the Luger, how to work it, and where to point it, all "naturally." But actually it was all carefully thought out by the author. In real life things usually seem to evolve "naturally" like this. If Carlson had volunteered to show the boys his Luger, explain how he got it and how it works, that would be un-natural. But a lesser writer probably would have handled the events in some such way.