挑战结束更新塔信息

This commit is contained in:
meixiongfeng 2023-08-24 17:35:26 +08:00
parent d2628f0349
commit 7f480a670f

View File

@ -14,9 +14,11 @@ import (
//爬塔模块 机器人 //爬塔模块 机器人
type ModuleRobot_Pagoda struct { type ModuleRobot_Pagoda struct {
pagoda *pb.DBPagoda pagoda *pb.DBPagoda
c *configureComp
} }
func (this *ModuleRobot_Pagoda) Init() (err error) { func (this *ModuleRobot_Pagoda) Init() (err error) {
this.c = new(configureComp)
return return
} }
@ -27,7 +29,12 @@ func (this *ModuleRobot_Pagoda) Receive(robot IRobot, stype string, message prot
resp := message.(*pb.PagodaGetListResp) resp := message.(*pb.PagodaGetListResp)
this.pagoda = resp.Data this.pagoda = resp.Data
break break
case "challengeover": // 更新塔信息
resp := message.(*pb.PagodaChallengeOverResp)
this.pagoda = resp.Data
break
} }
return return
} }