diff --git a/webapp/controller/GMController.class.php b/webapp/controller/GMController.class.php index e1ff18fc..c8bff8c1 100644 --- a/webapp/controller/GMController.class.php +++ b/webapp/controller/GMController.class.php @@ -348,20 +348,25 @@ END private function decGold($params) { $itemNum = getXVal($params, 0, 0); - $userInfo = myself()->_getUserInfo('gold'); + $userInfo = myself()->_getUserInfo(array('gold')); $oldGold = myself()->_getItemCount(V_ITEM_GOLD, $userInfo); $decItems = array( array( 'item_id' => V_ITEM_GOLD, - 'item_num' => $iteNum + 'item_num' => $itemNum ) ); - $newUserInfo = myself()->_getUserInfo('gold'); + myself()->_decItems($decItems); + $newUserInfo = myself()->_getUserInfo(array('gold')); $newGold = myself()->_getItemCount(V_ITEM_GOLD, $newUserInfo); + $propertyChgService = new services\PropertyChgService(); + $propertyChgService->addUserChg(); + myself()->_rspData(array( 'oldGold' => $oldGold, 'newGold' => $newGold, 'itemNum' => $itemNum, + 'property_chg' => $propertyChgService->toDto() )); } diff --git a/webapp/mt/MapMode.php b/webapp/mt/MapMode.php index e468ec0b..c1349b93 100644 --- a/webapp/mt/MapMode.php +++ b/webapp/mt/MapMode.php @@ -37,7 +37,7 @@ class MapMode public static function checkLimitTime($meta) { - switch (!$meta['limit_time']) { + switch ($meta['limit_time']) { case 1: { if ($meta['mapMode'] == self::RANKING_MODE) {