title: If a variable = this, then do this
body: <p>I'm new to coding with C# and I've looked around for an answer but none really make sense to me, I'm trying to set a variable to a random number, and if it equals 1, do this, if it equals 2, do this. Thanks </p>
  
  <p>Code: </p>
  
  <pre><code>if (goright == true)
              {
                  Random rand = new Random();
                  var x = rand.Next(1, 8);
  
                       if x = 1 ;
                      {
                          makeBullet2();
                          makeBullet3();
                          makeBullet4();
                      }
  </code></pre>