Advertisement
Guest User

Untitled

a guest
Apr 18th, 2011
239
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.73 KB | None | 0 0
  1.     if (from->paperdoll[Character::Weapon] == util::to_int(this->world->mining_config["MiningWeapon"]))
  2.     {
  3.         if ((from->direction == DIRECTION_UP && this->GetSpec(from->x, from->y-1) == Map_Tile::Mining) ||
  4.             (from->direction == DIRECTION_RIGHT && this->GetSpec(from->x+1, from->y) == Map_Tile::Mining) ||
  5.             (from->direction == DIRECTION_DOWN && this->GetSpec(from->x, from->y+1) == Map_Tile::Mining) ||
  6.             (from->direction == DIRECTION_LEFT && this->GetSpec(from->x-1, from->y) == Map_Tile::Mining))
  7.         {
  8.             this->Mine(from);
  9.         }
  10.         else
  11.         {
  12.             from->ServerMsg("You can't use the mining weapon for anything besides mining");
  13.         }
  14.         return;
  15.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement