A Modified Flash Random Number Generator

A few weeks ago, I was tasked to create a little program that would generate a random set of numbers in a specified range for a Christmas party in a very limited time (in a span of less than 4 hours).

A quick search in Google showed Flanture’s random number generator. It had 3 digits and when the roll button was pressed, a random number from 000 to 999 would be generated.

I wanted more flare and some fancy effects to go with the random number generator (for one, I needed a specific range of random numbers). And it was a 4 digit number, not just a 3 digit number.

Modifying the flash and actionscript was simple enough.

I added some modifications to add flashvars to the original code such as:
ftitle: Title shown to the flash app (value below is “Christmas Raffle”)
minval: minimum value in the range to be shown (value below is “3000”)
maxval: maximum value in the range to be shown (value below is “5000”)

If you want the modified source code (with other effects and range of random numbers), you can get the source code here.

 
 

3 comments for “A Modified Flash Random Number Generator

  1. Nathaniel
    March 27, 2011 at 10:28 pm

    hey

    the link to the modified generator only contains the swf file

  2. clintcan
    March 31, 2011 at 7:33 am

    Hey Nathaniel,

    Sorry about that – the code is uploaded now.

  3. ravi
    July 16, 2011 at 1:49 am

    this work is awesome plz send a generator with 2 digits and starts stop limits

Leave a Reply

Your email address will not be published. Required fields are marked *

Current ye@r *