I also wondered what determined the item or amount of gold we get so I thought I'd ask this and see what One-eyed Jack will say.
So anyway, what exactly determines what we get from an enemy, say, the boss Captain Blood. What determines us getting a common item that can be sold in the bazaar or a very rare item like his sword or hat, or whether we get 20 gold or 500 gold from a chest. Does fighting a certain way determine better drops? Does finishing the fight at a certain time determine better drops, does having more health at the end of the fight determine better drops? There's so many things that could determine drops, unless the whole system is just random like a spinning wheel (Think of Wheel of Fortune) that when it stops, whatever it stops on determines what you get from the fight. Please answer this question One-eyed Jack, I'm kinda going mad thinking about all of this.