Nice job!! I used to always have bugs in my progs when I would run them first and then it got to a point where I'd just write them up and hardly ever had to make any changes... worked first time! (MAJIN SS, Scarab 21 AP, Attic Buyer, etc)
One thing to note for people using this program: make sure you empty your inventory fully before starting any quests, or you'll be at risk of buying the same items more than once.