vy += ay * dt;
w.msleep(10);
- w.sync();
+// w.sync();
w.setColor("skyblue");
w.fillCircle(wx, wy, 2);
// w.setColor("black");
do {
joueur = 3 - joueur;
+ w.sync();
std::cout << "-=| Joueur " << joueur << " |=-";
float alpha;
perdant = tir(w, x0, y0, v0, alpha, x, y);
dessineExplosion(w, x, y);
dessineVent(w, wnd);
- w.sync();
} while (!perdant);
dessineFlammes(w, x, y);
std::stringstream msg;
- msg << "Joueur " << perdant;
+ msg << " Joueur " << perdant;
if (perdant == joueur)
- msg << " s'est suicidé !";
+ msg << " s'est suicidé ! ";
else
- msg << " a perdu !";
+ msg << " a perdu ! ";
w.setColor("darkred");
w.setBgColor("white");
w.drawTextBg(w.width / 2, w.height / 3, msg.str().c_str(),