Complex sentence: Customers entering the store were handed a small pistol-like key that they placed in the keyhole below the goods they wished to buy, the quantity being determined by the number of times they pulled the key's trigger.
Split into simpler sentences: Customers entering the store were given a small pistol-like key that they placed in the keyhole below the goods they wished to buy. The quantity desired was determined by the number of times they pulled the key's trigger.