Update items.c

updated sort weight, works if you run it before sort by cost,