This commit is contained in:
aozhiwei 2022-09-21 21:10:40 +08:00
parent 29a32a5cbf
commit 32ef8c643a
2 changed files with 9 additions and 1 deletions

View File

@ -171,7 +171,7 @@ class Fragment {
't_fragment_pool',
['fragment_id', element['item_id']],
['type', element['type']],
//['fragment_type', element['type']],
['fragment_type', this.getFragementType(element['type'])],
['fragment_num', element['item_num']],
['alloc_num', element['item_num']],
['alloc_time', hourSeconds],
@ -282,6 +282,13 @@ class Fragment {
return YESTERDAY_GUN_NUM;
}
getFragementType(itemId) {
if (constant.ALL_HERO_FRAGMENT.indexOf(itemId) >= 0) {
return 0;
}
return 1;
}
}
function init() {

View File

@ -613,6 +613,7 @@ CREATE TABLE `t_fragment_pool` (
`type` int(11) NOT NULL DEFAULT '0' COMMENT '0:pvp 1:pve',
`fragment_type` int(11) NOT NULL DEFAULT '0' COMMENT '碎片类型 0:英雄 1:武器',
`fragment_num` int(11) NOT NULL DEFAULT '0' COMMENT '剩余碎片数量',
`alloced_num` int(11) NOT NULL DEFAULT '0' COMMENT '已经分配的碎片数量',
`alloc_num` int(11) NOT NULL DEFAULT '0' COMMENT '分配的碎片数量',
`alloc_time` int(11) NOT NULL DEFAULT '0' COMMENT '分配时间',
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',