Random number function error!

I think Im Dead
01 Oct 2004, 05:50
I have this bit of code here...


set string <Register.temp[userid]; $name(%userid%)$$rand(1;9999)$>
msg <Would you like to use #Register.temp[userid]# as your Account name(if available)?|nY/N?|n>


And it's spitting out names with an additional space between the name and the random number...

John 9423
Mark 234

Doesn't seem like this should be happening, seems like a simple slip up in quest or questnet.

Alex
01 Oct 2004, 09:16
Thanks for pointing this out. As a workaround I think you could try putting the random number into a string variable first, e.g.


set string <randnum; $rand(1;9999)$>
set string <Register.temp[userid]; $name(%userid%)$#randnum#>


I think that ought to work - can't test it right now though.

I think Im Dead
01 Oct 2004, 09:54
Work around does indeed work.