Ejemplo n.º 1
0
 /**
  * Remove items from the clan bank.
  * @param SR_Clan $clan
  * @param string $itemname
  * @param int $amt
  * @param int $weight
  * @return boolean
  */
 public function pop(SR_Clan $clan, $amt, $weight)
 {
     if ($this->getAmt() > $amt) {
         if (false === $this->increase('sr4cb_iamt', -$amt)) {
             return false;
         }
     } else {
         if (false === $this->delete()) {
             return false;
         }
     }
     return $clan->increase('sr4cl_storage', -$weight);
 }