28.10.2011, 23:07
Hi,
I have created a public which bascially generates a random location where players have to go to then. Everything is working fine, but I have noticed that sometimes comes the same location 2 times in a row.
I want to find a way around it somehow, and created a function which just adds the 3 positions to a sum. So then I want to do it like:
It first checks the sum. If it is NOT the same as in the check before, it will create a checkpoint. But if it IS the same, then it shalle generate it again.
I was unsure how to do this, and thought if it is possible to do that with a do - while loop, but I am totally stuck, and hope that somebody here can help me.
Thanks in advance.
(I hope that my explanation was clear)
I have created a public which bascially generates a random location where players have to go to then. Everything is working fine, but I have noticed that sometimes comes the same location 2 times in a row.
I want to find a way around it somehow, and created a function which just adds the 3 positions to a sum. So then I want to do it like:
It first checks the sum. If it is NOT the same as in the check before, it will create a checkpoint. But if it IS the same, then it shalle generate it again.
I was unsure how to do this, and thought if it is possible to do that with a do - while loop, but I am totally stuck, and hope that somebody here can help me.
Thanks in advance.
(I hope that my explanation was clear)