feat(config): 添加服务器调试模式配置和塔配置重构 - 在ServerList结构体中添加IsDebug字段用于调试模式标识 - 修改GetServerInfoList函数增加isdebug参数支持 - 移除硬编码的rpcaddr本地地址配置 - 重构塔配置模型,将tower_500和tower_600合并到tower_110
32 lines
584 B
Go
32 lines
584 B
Go
package service
|
|
|
|
import (
|
|
"blazing/cool"
|
|
"blazing/modules/config/model"
|
|
)
|
|
|
|
type EffectService struct {
|
|
*cool.Service
|
|
}
|
|
|
|
func (s *EffectService) Args(id uint32) (int, []int) {
|
|
m := dbm(s.Model).Where("se_idx", id)
|
|
var tt model.PlayerPetSpecialEffect
|
|
m.Scan(&tt)
|
|
|
|
return int(tt.Eid), tt.Args
|
|
|
|
}
|
|
func NewEffectService() *EffectService {
|
|
return &EffectService{
|
|
&cool.Service{
|
|
|
|
Model: model.NewPlayerPetSpecialEffect(),
|
|
UniqueKey: map[string]string{"idx_se_idx": "索引不能重复"},
|
|
PageQueryOp: &cool.QueryOp{
|
|
KeyWordField: []string{"desc"},
|
|
},
|
|
},
|
|
}
|
|
}
|