map 初始化

This commit is contained in:
meixiongfeng 2023-05-30 17:47:21 +08:00
parent 4b89fd4362
commit 1a560f9ab7
3 changed files with 3 additions and 0 deletions

View File

@ -41,6 +41,7 @@ func (this *apiComp) Awaken(session comm.IUserSession, req *pb.HeroAwakenReq) (c
awakenData, err = this.module.configure.GetHeroAwakenConfig(_hero.HeroID, _hero.JuexingLv+1)
if err != nil {
data = &pb.ErrorData{}
code = pb.ErrorCode_ConfigNoFound
data.Message = err.Error()
return

View File

@ -42,6 +42,7 @@ func (this *modelHunting) getHuntingList(uid string) (result *pb.DBHunting, err
Uid: uid,
Boss: make(map[int32]int32),
BossTime: make(map[string]int32),
Ps: map[int32]int32{},
}
this.Add(uid, result)

View File

@ -37,6 +37,7 @@ func (this *modelViking) getVikingList(uid string) (result *pb.DBViking, err err
Uid: uid,
Boss: make(map[int32]int32),
BossTime: make(map[string]int32),
Ps: make(map[int32]int32),
}
err = nil
this.module.modelViking.Add(uid, result)