Search Unity

Random.seed is required to set only once in entire project?

Discussion in 'Scripting' started by leegod, Feb 3, 2013.

  1. leegod

    leegod

    Joined:
    May 5, 2010
    Posts:
    2,476
    As title, just one set of Random.seed take effect to whole scenes, gameobjects, scripts in entire project's Random.Range(0~10) or Random.value calculations?

    Thank.
     
  2. Gibbonator

    Gibbonator

    Joined:
    Jul 27, 2012
    Posts:
    204
    Yes, that is correct. If you want to have several random number generators you can use the System.Random class from the .NET libs.