Changed tool selection to numeric ID, fixed tool selection bug