I got it working! :D
Well I sort of got it working, every so often it would put an extra item that wasn't supposed to be there in and then it would stop randomizing after a few times, but mizal was able to fix that part.
I'm excited though, this is the biggest and most complicated script I've ever made and I have ideas for other things I can do with it now too.