title: Block user from moving anywhere
body: <p>I have made a game which is nearly identical to Popcap's Atomica. (<a href="http://www.popcap.com/gamepopup.php?theGame=atomica" rel="nofollow noreferrer">http://www.popcap.com/gamepopup.php?theGame=atomica</a>)</p>
  
  <p>It's almost finished, except for one important function; blocking the user from moving spheres anywhere. Like, if there is a wall of other spheres in between the sphere the user is trying to move, and the field it is trying to move it to, the user should not be able to move it.</p>
  
  <p>I have stored all the fields and spheres in a multidimensional array[x-loc, y-loc] where "e" equals empty, "s" sphere, etc. I've tried running a loop through it to find out if there is a clear road between the two fields, but nothing has worked.</p>
  
  <p>Can anyone please give me a hint of how I can solve this problem?</p>