1. Is there a way to get the socket bonus from an item in your inventory? (The socket bonus is of course the stats bonus you get for inserting gems that match the color of the sockets in an item.) Thanks for your help!

  2. Let me rephrase the question: Is there a function whose argument is an item your character has equipped and which returns (in some form or another) the socket bonus of that item?