Author Topic: Random numbers and more  (Read 3113 times)


  • Newbie
  • *
  • Posts: 3
Random numbers and more
« on: April 15, 2007, 07:04:37 PM »
I think there is a way to do this, how can I get random numbers. Like I could say 10-10,000,000 and it would pick out a number in that range.

Also I would like to have a counter, so everytime it say, noticed someone from ontext, it would say "I have exploded *counted number* of times"



  • Administrator
  • Hero Member
  • *****
  • Posts: 1974
    • IceChat IRC Client
Re: Random numbers and more
« Reply #1 on: April 15, 2007, 07:29:36 PM »
Well, I am not sure what version of scripting you want.

$rnd(10,10000)  will give you a random number in that range.

As for adding a counter, just declare a variable outside of all your sub, and it will keep it counting. But, that number will reset each time the script is re-loaded, so you could just save the number to an INI file, and read it on script load.
The IceChat God