diff --git a/database/wheeldb.sql b/database/wheeldb.sql index 5635b4b7..5324fd53 100644 --- a/database/wheeldb.sql +++ b/database/wheeldb.sql @@ -159,8 +159,7 @@ CREATE TABLE `t_buff` ( `idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id', `account_id` varchar(60) NOT NULL DEFAULT '' COMMENT '账号id', `buff_id` int(11) NOT NULL DEFAULT '0' COMMENT 'buff id', - `start_time` int(11) NOT NULL DEFAULT '0' COMMENT '开始时间', - `effective_time` int(11) NOT NULL DEFAULT '0' COMMENT '有效时间', + `expires_time` int(11) NOT NULL DEFAULT '0' COMMENT '过期时间', `createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间', `modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间', KEY `idx_account_id` (`account_id`), diff --git a/server/wheelserver/service/buff.go b/server/wheelserver/service/buff.go index 8d7bc562..67967429 100644 --- a/server/wheelserver/service/buff.go +++ b/server/wheelserver/service/buff.go @@ -47,7 +47,9 @@ func (this *buff) Add(accountId string, buffList []int32) { buffModel.ModifyTime = nowTime buffModel.Create() } else { + if nowTime - buffModel.StartTime > buffModel.EffectiveTime { + } } } }