title: Trying to make block collision for c++ cmd game so that platforms are solid, but wont work
body: <p>Im working on a cmd game for fun and I've run into a problem.  I've coded in the movement and gravity, but in my last if statement where I attempt to make the character seize his downward movement if above a '219' char or in other wards a block, it doesnt work.  I end up still going right through the block and deleting it if I attempt to fall on it.  Heres the full source code so you may run it and see what I mean.
  <pre>
  using namespace std;</p>
  
  <code>char Map[10][81] =
  {
  
     "                                                                                ",
     "                                                                                ",
     "                                                                                ",
     "                                                                                ",
     "                                                   ###                          ",
     "                                                                                ",
     "                                                                                ",
     "                                                                                ",
     "                                                                                ",
     "################################################################################",
  };
  
  int main()
  {
  bool start = true;
  char dood('0');
  bool print(false);
  
  int x = 1;
  int y = 8;
  
  Map [y][x] = dood;
  int cnt = 0;
  int Height = 0;
  int space_below = Map [y + 1][x];
  
  while(start = true)
  {
  
      Sleep(20);
      system("cls");
  
  
      for(auto &amp;c: Map)
      {
          for(auto &amp;d: c)
          {
                  if(d == '#')
                  {
                      d = 219;
                  }
                  cout &lt;&lt; d;
          }
          cout &lt;&lt; endl;
  
      }
      cout &lt;&lt; "Height: " &lt;&lt; Height &lt;&lt;" units";
  
  
  
      if(GetAsyncKeyState(VK_RIGHT) != 0)
          {
              if(x != 79)
              {
              Map [y][x] = ' ';
              x++;
              Map [y][x] = dood;
              }
          }
      if(GetAsyncKeyState(VK_LEFT) != 0)
              {
                  if(x != 0)
                  {
                  Map [y][x] = ' ';
                  x--;
                  Map [y][x] = dood;
                  }
              }
  
  
      if (GetAsyncKeyState(VK_UP) != 0)
      {
          if(y &lt; 9 &amp;&amp; y &gt; 0)
          {
              Map[y][x] = ' ';
              y--;
              Height++;
              Map[y][x] = dood;
          }
      }
  
      if(y &lt; 8 &amp;&amp; !GetAsyncKeyState(VK_UP))
          {
              if(space_below  != '219')
              {
                  Map[y][x] = ' ';
                  y++;
                  Height--;
                  Map[y][x] = dood;
              }
          }
  }
  return 0;
  }
  </code></pre>
  
  <p>
  *Note: Inlude statements would work when pasting them in here, but I included iostream, windows.h, and time.h. </p>
  
  <p>The last if statement is my gravity which procs if the player is not holding up, and when space_below, or the block below him is not a '219' ascii character, but but for some reason when I try to jump on that platform I made this doesn't work and that character just falls through and turns the block into a space(deletes it)!</p>
  
  <p>I'm kinda new to c++, so I understand my mistake could be stupidly simple, but I haven't been able to find a fix on the internet.  Any help is much appreciated :)</p>