Constructs Random - A quick example

This forum is currently in read-only mode.
From the Asset Store
Casino? money? who knows? but the target is the same!
  • For anyone worried that the construct random might be badly made because its built in, or doesn't produce good random value, or is bias to higher ranges or something, this should hopefully prove them wrong Construct uses the mersenne twister algorithm

  • YES!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! SMILEY RACING!

  • Is it possible to set the seed for the random number generator? That kind of thing can be pretty useful, especially if you're doing procedurally generated stuff.

  • what would a seed do? random is random (i think... )

  • Seed would provide you with repeatable random sequences which would be of use when creating replays of game (so that you won't have to store all random moving objects position but only seed that'd reprocude all their movement correctly).

  • what would a seed do? random is random (i think... )

    Computer generated random numbers aren't truly random and are generated using an algorithm (there are lots of different methods), but that algorithm needs a starting number to generate all the others from. If you put in the same seed number, you'll get the same results each time, so often people use the current time in milliseconds to seed the generator so that it appears different each time. However, like Broo said, it can be useful to set the seed number, especially if you want everything to happen as it did the first time like in replays for example.

  • off topic, but how did you manage to put an expression into the 'set color filter' action? it defaults to a colorpicker ...

  • off topic, but how did you manage to put an expression into the 'set color filter' action? it defaults to a colorpicker ...

    After you've chosen "Set colour filter" as the action, right click where it says "Filter", and you can choose to use an expression from the menu that appears.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • > off topic, but how did you manage to put an expression into the 'set color filter' action? it defaults to a colorpicker ...

    >

    After you've chosen "Set colour filter" as the action, right click where it says "Filter", and you can choose to use an expression from the menu that appears.

    Right click? <img src="http://www.b3tards.com/u/2951c544e5d930f23b20/emot-doh.gif">

    So that's how you do it. I was having trouble with that the other day.

  • It IS pretty confusing... It isn't generally very good UI design to hide features EXCLUSIVELY inside context menus... There could be some kind of VISIBLE hint?

  • hm, this is the second time i find something important hidden behind a right-click at the right spot ...

    i don't know if this is random or intentional reoccurance, but it would certainly be great to document it somewhere :)

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)