Search Unity

Question Random.Range is not working on another device

Discussion in 'Scripting' started by eayaz, May 22, 2023.

  1. eayaz

    eayaz

    Joined:
    Oct 30, 2020
    Posts:
    1
    Hi, I know the title may seem kinda weird but I didn't know how else to tell the problem I am facing.

    I am making a game in which I am generating a random value between 0-1000. And the build is working fine on my Macbook and also my Windows laptop. But when I send the build to my friend, Random.Range only generates 0. Why is this happening and how can I solve it?
     
  2. Chubzdoomer

    Chubzdoomer

    Joined:
    Sep 27, 2014
    Posts:
    132
    Can you post the snippet of code that's using Random.Range?