Advertisement
Guest User

Untitled

a guest
Jan 24th, 2017
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.71 KB | None | 0 0
  1.             if (event.type == Event::MouseButtonReleased && event.key.code == Mouse::Left)
  2.             {
  3.                 for (int a = 0; a <= 24; a++)
  4.                 {
  5.                     if (pozycja[a].adr_pion().getGlobalBounds().contains(mysz))
  6.                     {
  7.                         pion1[pom].adr_pion().setPosition(poz.x - x1, poz.y - y1);
  8.                     }
  9.                 }
  10.  
  11.                 for (int a = 0; a <= 24; a++)
  12.                 {
  13.                     if (pozycja[a].adr_pion().getGlobalBounds().contains(mysz))
  14.                     {
  15.                         pion2[pom].adr_pion().setPosition(poz.x - x2, poz.y - y2);
  16.                     }
  17.                     ruch1 = false;
  18.                     ruch2 = false;
  19.                 }
  20.  
  21.             }
  22.  
  23.             if (ruch1)
  24.             {
  25.  
  26.                 pion1[pom].adr_pion().setPosition(poz.x - x1, poz.y - y1);
  27.             }
  28.  
  29.             if (ruch2)
  30.             {
  31.  
  32.                 pion2[pom].adr_pion().setPosition(poz.x - x2, poz.y - y2);
  33.  
  34.             }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement