src/Player.cc
changeset 409 1a03ff151abc
parent 408 e6cfc44266af
child 412 721c60072091
equal deleted inserted replaced
408:e6cfc44266af 409:1a03ff151abc
    96     }
    96     }
    97 }
    97 }
    98 
    98 
    99 void Player::respawn (TimeMS dt) {
    99 void Player::respawn (TimeMS dt) {
   100     (void) dt;
   100     (void) dt;
   101 
   101     
   102     // XXX: ...
   102     // spawn in the middle of the world
   103     spawn(Vector(PLAYER_INITIAL_X, PLAYER_INITIAL_Y));
   103     spawn(world.dimensions / 2); 
   104 }
   104 }
   105 
   105 
   106 void Player::handleDig (Vector pos, float radius) {
   106 void Player::handleDig (Vector pos, float radius) {
   107     // calculate new position and velocity
   107     // calculate new position and velocity
   108     Vector digPosition = pos + getDirection() * PROJECTILE_START_DISTANCE;
   108     Vector digPosition = pos + getDirection() * PROJECTILE_START_DISTANCE;