"sell_weapon" = NPC takes weapon and pays amount of $ back and/or gives you items in return "exchange" = NPC takes items/money and gives items/weapons/money in return ...
Over on YouTube [Andrew Neal] has a Function Generator Build for Beginners. As beginner videos go this one is fairly ...