A 2D tile-based sandbox game.
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

Player.cc 192B

12345678910111213
  1. #include "Player.h"
  2. void Player::draw(Win &win) {
  3. body_.outline(win);
  4. }
  5. void Player::update(float dt) {
  6. body_.vel_.x = 1;
  7. body_.update(dt);
  8. if (body_.pos_.x > 20)
  9. body_.pos_.x = 0;
  10. }