diff --git a/server/matchserver/common/types.go b/server/matchserver/common/types.go index ea48595d..2ed46600 100644 --- a/server/matchserver/common/types.go +++ b/server/matchserver/common/types.go @@ -37,6 +37,32 @@ type LoginRsp struct { } `json:"info"` } +type UserRsp struct { + Errcode int `json:"errcode"` + Errmsg string `json:"errmsg"` + Info struct { + UserInfo struct { + Activated string `json:"activated"` + RenameCount string `json:"rename_count"` + AccountId string `json:"account_id"` + Name string `json:"name"` + HeadId string `json:"head_id"` + HeroId string `json:"hero_id"` + HeadFrame string `json:"head_frame"` + TotalLucky interface{} `json:"total_lucky"` + AdmissionItemNum interface{} `json:"admission_item_num"` + } `json:"user_info"` + HeroInfo struct { + HeroUniId string `json:"hero_uniid"` + HeroId string `json:"hero_id"` + Quality string `json:"quality"` + SpecSkill string `json:"spec_skill"` + Wealth interface{} `json:"wealth"` + ValidLefttime interface{} `json:"valid_lefttime"` + } `json:"hero_info"` + } `json:"info"` +} + type MapInfoRsp struct { ModeId interface{} `json:"mode_id"` MapId int32 `json:"map_id"` diff --git a/server/matchserver/player/player.go b/server/matchserver/player/player.go index 7c3f0390..d8d26517 100644 --- a/server/matchserver/player/player.go +++ b/server/matchserver/player/player.go @@ -402,12 +402,12 @@ func (this *player) CMRefreshUser(hdr *f5.MsgHdr, msg *cs.CMRefreshUser) { "account_id": this.GetAccountId(), "session_id": this.GetSessionId(), } - rspObj := common.LoginRsp{} + rspObj := common.UserRsp{} url := fmt.Sprintf("%s/webapp/index.php", mt.Table.Config.GetById(0).GetGameapiUrl()) f5.GetHttpCliMgr().SendJsStyleJsonRspRequest( url, params, - rspObj, + &rspObj, func(rsp f5.HttpCliResponse) { this.SendMsg(rspMsg) if rsp.GetErr() == nil && rsp.JsonParseOk() { @@ -425,7 +425,7 @@ func (this *player) CMRefreshUser(hdr *f5.MsgHdr, msg *cs.CMRefreshUser) { q5.DuckToSimple(rspObj.Info.HeroInfo.ValidLefttime, &this.hero.validLeftTime) } if this.GetTeam() != nil { - this.GetTeam().SendStateNotify() + this.GetTeam().SendUpdateNotify() } } }) diff --git a/third_party/f5 b/third_party/f5 index c31eaf2c..380443c3 160000 --- a/third_party/f5 +++ b/third_party/f5 @@ -1 +1 @@ -Subproject commit c31eaf2c49d16754fb76241466208ff9dc412826 +Subproject commit 380443c39edace66279a0ea21f9f7c80f6ec1fd4