X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/graphlib.git/blobdiff_plain/b9a18b0f672431314c0a535826dbe6e52cb15674..bbb605962fbf12b156bdae7424ae4d47ff1ddfbb:/chateaux/chateaux.cpp diff --git a/chateaux/chateaux.cpp b/chateaux/chateaux.cpp index c0c9ade..16f10e2 100644 --- a/chateaux/chateaux.cpp +++ b/chateaux/chateaux.cpp @@ -247,6 +247,7 @@ int tir(DrawingWindow& w, vy += ay * dt; w.msleep(10); +// w.sync(); w.setColor("skyblue"); w.fillCircle(wx, wy, 2); // w.setColor("black"); @@ -280,6 +281,7 @@ int jeu1(DrawingWindow& w) do { joueur = 3 - joueur; + w.sync(); std::cout << "-=| Joueur " << joueur << " |=-"; float alpha; @@ -320,6 +322,7 @@ int jeu1(DrawingWindow& w) w.setBgColor("white"); w.drawTextBg(w.width / 2, w.height / 3, msg.str().c_str(), Qt::AlignCenter); + w.sync(); std::cout << msg.str() << std::endl; return perdant; }