Trying to get a random spawn that doesn't repeat

Do you *always *want 4 unique tiles? This will always give you 4 unique elements, it creates a temporary array and removes elements that were used:

If you want to allow for a non-unique element, iterate 3 times instead of 4, and add another element from the All Tiles list. This way you will have 3 unique and a small chance (eyeballing it at 20-25%) for a single repetition.