title: Make my object move left and right continuously c#
body: <p>So I created a monster which I want to be consistently moving right and left between x= 156 and x = 501
  Here's what i have done so far in my move() method:</p>
  
  <pre><code>public void move()
  {
      int left = 156;
      int right = 501;
  
      if (left &lt;= x)
      {
          x++;   
      }
      if (x &gt;= 501)
      {  
          x -= 1;
      }
  }
  </code></pre>
  
  <p>Then I call the method using a timer</p>
  
  <pre><code>private void tmr2_Tick(object sender, EventArgs e)
  {
      foreach (Monster m in monsters_)
      {
          m.move();
      }
      screen.Refresh();
  }
  </code></pre>
  
  <p>This doesn't work. Could someone please help out.
  Thanks</p>