Merge branch 'james' of git.kingsome.cn:server/game2006api into james
This commit is contained in:
commit
e6127558c9
@ -267,6 +267,7 @@ CREATE TABLE `t_chip` (
|
|||||||
`lucky_final` varchar(10) NOT NULL DEFAULT '0' COMMENT '最终幸运值',
|
`lucky_final` varchar(10) NOT NULL DEFAULT '0' COMMENT '最终幸运值',
|
||||||
`strength_max` varchar(10) NOT NULL DEFAULT '0' COMMENT '最大体力值',
|
`strength_max` varchar(10) NOT NULL DEFAULT '0' COMMENT '最大体力值',
|
||||||
`strength` varchar(10) NOT NULL DEFAULT '0' COMMENT '前一天体力值',
|
`strength` varchar(10) NOT NULL DEFAULT '0' COMMENT '前一天体力值',
|
||||||
|
`upgrade_mint` double NOT NULL DEFAULT '0' COMMENT 'mint费用',
|
||||||
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
|
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
|
||||||
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
|
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
|
||||||
`labour` int(11) NOT NULL DEFAULT '0' COMMENT '劳力值',
|
`labour` int(11) NOT NULL DEFAULT '0' COMMENT '劳力值',
|
||||||
|
@ -164,6 +164,7 @@ class Chip extends BaseModel
|
|||||||
'rand_attr' => json_encode($randAttr),
|
'rand_attr' => json_encode($randAttr),
|
||||||
'chip_grade' => $grade,
|
'chip_grade' => $grade,
|
||||||
'chip_type' => $itemMeta['sub_type'],
|
'chip_type' => $itemMeta['sub_type'],
|
||||||
|
'labour' => 0,
|
||||||
'createtime' => myself()->_getNowTime(),
|
'createtime' => myself()->_getNowTime(),
|
||||||
'modifytime' => myself()->_getNowTime()
|
'modifytime' => myself()->_getNowTime()
|
||||||
);
|
);
|
||||||
|
@ -130,6 +130,10 @@ class Gun extends BaseModel {
|
|||||||
if ($row) {
|
if ($row) {
|
||||||
$cb($row);
|
$cb($row);
|
||||||
}
|
}
|
||||||
|
}else{
|
||||||
|
if ($row) {
|
||||||
|
$cb($row);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -255,6 +259,7 @@ class Gun extends BaseModel {
|
|||||||
'lock_type' => self::NO_LOCK,
|
'lock_type' => self::NO_LOCK,
|
||||||
'unlock_time' => 0,
|
'unlock_time' => 0,
|
||||||
'unlock_trade_time' => 0,
|
'unlock_trade_time' => 0,
|
||||||
|
'labour' => 0,
|
||||||
'createtime' => myself()->_getNowTime(),
|
'createtime' => myself()->_getNowTime(),
|
||||||
'modifytime' => myself()->_getNowTime()
|
'modifytime' => myself()->_getNowTime()
|
||||||
);
|
);
|
||||||
|
@ -123,6 +123,10 @@ class Hero extends BaseModel {
|
|||||||
if ($row) {
|
if ($row) {
|
||||||
$cb($row);
|
$cb($row);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
if ($row) {
|
||||||
|
$cb($row);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -267,6 +271,7 @@ class Hero extends BaseModel {
|
|||||||
'unlock_time' => 0,
|
'unlock_time' => 0,
|
||||||
'unlock_trade_time' => 0,
|
'unlock_trade_time' => 0,
|
||||||
'skill_points' => 0,
|
'skill_points' => 0,
|
||||||
|
'labour' => 0,
|
||||||
'createtime' => myself()->_getNowTime(),
|
'createtime' => myself()->_getNowTime(),
|
||||||
'modifytime' => myself()->_getNowTime()
|
'modifytime' => myself()->_getNowTime()
|
||||||
);
|
);
|
||||||
|
@ -211,6 +211,16 @@ class User extends BaseModel {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static function getUserByRankMess($row){
|
public static function getUserByRankMess($row){
|
||||||
|
$currSeasonMeta = mt\RankSeason::getCurrentSeason();
|
||||||
|
$gameTimes = 0;
|
||||||
|
if ($currSeasonMeta){
|
||||||
|
$season = Season::find($currSeasonMeta['id']);
|
||||||
|
if ($season){
|
||||||
|
$battleData = json_decode($season['battle_data'], true);
|
||||||
|
$seasonBattleData = isset($battleData) ? getXVal($battleData, 'season_data', array()) : array();
|
||||||
|
$gameTimes = getXVal($seasonBattleData, 'total_battle_times', 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
$toDto =array(
|
$toDto =array(
|
||||||
'idx' => $row['idx'],
|
'idx' => $row['idx'],
|
||||||
'account_id' => $row['account_id'],
|
'account_id' => $row['account_id'],
|
||||||
@ -223,7 +233,7 @@ class User extends BaseModel {
|
|||||||
'score' => $row['score'],
|
'score' => $row['score'],
|
||||||
'history_best_score' => $row['history_best_score'],
|
'history_best_score' => $row['history_best_score'],
|
||||||
//排位场数
|
//排位场数
|
||||||
'rank_num' => 0,
|
'rank_num' => $gameTimes,
|
||||||
);
|
);
|
||||||
return $toDto;
|
return $toDto;
|
||||||
}
|
}
|
||||||
|
@ -63,8 +63,11 @@ class UserSeasonRing extends BaseModel
|
|||||||
if ($row) {
|
if ($row) {
|
||||||
$cb($row);
|
$cb($row);
|
||||||
}
|
}
|
||||||
|
}else{
|
||||||
|
if ($row) {
|
||||||
|
$cb($row);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user