123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216 |
- package msg
- import "leafstalk/covenant/model"
- // 服务器发送有用户登录
- type Login struct {
- AccId int64 `json:"accId"`
- OpenId string `json:"openId"`
- RemoteAddr string `json:"remoteAddr"`
- NickName string `json:"nickName"`
- ImgUrl string `json:"imgUrl"`
- GateId int64 `json:"gateId"`
- LineId int64 `json:"lineId"`
- ClickId string `json:"clickId"`
- AdId string `json:"adId"`
- AdSrc string `json:"adSrc"`
- Flag int `json:"flag"`
- Plat string `json:"plat"`
- SubPlat string `json:"subPlat"`
- SessionKey string `json:"sessionKey"`
- }
- type ResponseLogin struct {
- AccId int64 `json:"userId"`
- DocId int64 `json:"docId"`
- ErrCode int `json:"errCode"`
- }
- type Logout struct {
- RpcRequestMsg
- PlayerIds []int64 `json:"userIds"`
- }
- type ResponseLogout struct {
- RpcResponseMsg
- PlayerIds []int64 `json:"userIds"`
- }
- // Entry 登录
- type Entry struct {
- UserId int64 `json:"userId"` //客户端->gate:accid; gate->world:playerId
- PhoneType int64 `json:"phoneType"`
- ClientFlag string `json:"clientPlat"`
- Version string `json:"version"`
- Token string `json:"token"`
- LineId int64 `json:"serverId"`
- SubPlat string `json:"subPlat"`
- }
- type BuffData struct {
- BuffId int `json:"buffId"` //buFF id
- CoolDown int `json:"coolDown"` //倒计时
- }
- // type EntryDataFort struct {
- // Level int64 `json:"level"` //等级
- // Parts [6]*model.FortPart `json:"parts"` //部位
- // TalentTree [2]int64 `json:"talents"` //天赋树
- // Skin *model.FortSkin `json:"skin"` //皮肤
- // SkillIds [3]int64 `json:"skill"` //技能
- // }
- type GmPlayer struct {
- MsgId string `json:"msgId"`
- PlayerID int64 `json:"userId"`
- OperatorId int64 `json:"operatorId"`
- }
- type ResponseGmPlayer struct {
- ErrCode int `json:"errCode"`
- MsgId string `json:"msgId"`
- Data *EntryData
- }
- // 增加 金币、钻石、材料、装备
- type GmAddMaterial struct {
- MsgId string `json:"msgId"`
- PlayerID int64 `json:"userId"`
- Materials map[int64]int64 `json:"materials"`
- Runes map[int64]int64 `json:"runes"`
- Legends map[int64]int64 `json:"legends"`
- Equipments []int64 `json:"equipments"`
- Treasures []int64 `json:"treasures"`
- OperatorId int64 `json:"operatorId"`
- ClientPlat string `json:"clientPlat"`
- }
- type ResponseGmAddMaterial struct {
- ErrCode int `json:"errCode"`
- MsgId string `json:"msgId"`
- }
- // 要塞时装(皮肤)
- // type FortSkin struct {
- // Wear int64 `json:"wear"`
- // Skins map[int64]int64 `json:"skins"` //皮肤id:星级
- // }
- // type Hero struct {
- // ID int64 `json:"id"`
- // Level int64 `json:"level"` // 当等级=0时,表示英雄未解锁,可以拥有皮肤
- // Wear int64 `json:"wear"`
- // Skins []int64 `json:"skins"`
- // }
- type ChapterProcess struct {
- Standard int64 `json:"standard"` //主章节当前进度
- Advanced int64 `json:"advanced"` //精英
- Cooperation int64 `json:"cooperation"` //合作关卡
- Levels map[int64]*LevelProcess `json:"levels"`
- CDs []int64 `json:"cds"` //普通 困难 噩梦
- OpenServerTl int64 `json:"openServerTl"` //开服时长
- }
- type LevelProcess struct {
- Level int64 `json:"id"` //关卡
- Wave int64 `json:"wave"` //首通波次
- Geted int64 `json:"geted"` //首通获取到的波次
- SubWave int64 `json:"subWave"` //次通波次
- SubGeted int64 `json:"subGeted"` //次通获取到的波次
- }
- type Legend struct {
- Level int64 `json:"level"` // 精通等级
- SlotWear map[int64]int64 `json:"slotWear"` // {slotId:modelId}
- Legends map[int64]int64 `json:"legends"` // {modelId:num}
- }
- type PayParam struct {
- WxIosOpenLevel int64 `json:"wxIosOpenLevel"`
- PayMethod int `json:"payMethod"`
- }
- type EntryData struct {
- PlayerId int64 `json:"userId"`
- Level int `json:"userLevel"`
- AccId int64 `json:"accId"`
- Exp int64 `json:"userExp"`
- Heros map[int64]*model.Hero `json:"heros"`
- Fort *model.EntryDataFort `json:"fort"`
- Materials map[int64]int64 `json:"materials"`
- Runes map[string]*model.BagRune `json:"runes"`
- Treasures map[int64]*model.GrowableTreasure `json:"treasures"`
- Chapters *ChapterProcess `json:"chapters"`
- Crystals map[int64]int64 `json:"crystals"`
- Arenas model.ClientArena `json:"arenas"`
- Resonances []*model.GrowableResonance `json:"resonances"`
- Renown int64 `json:"renown"`
- LoginDays int64 `json:"loginDays"`
- Legends *Legend `json:"legends"`
- ServerTs int64 `json:"serverts"`
- HeadId int64 `json:"headId"`
- FrameId int64 `json:"frameId"`
- Nick string `json:"nick"`
- ChangedNickNum int64 `json:"changedNickNum"`
- CreditScore int64 `json:"creditScore"`
- CoopTickets map[int64]int64 `json:"coopTickets"`
- GameSyncEnterRoom *model.EnterRoomData `json:"gameSyncEnterRoom"`
- Pay PayParam `json:"pay"`
- LanuchShare UserShareData `json:"lanuchShare"`
- // TimeStamp int64 `json:"timeStamp"`
- // Stamina int `json:"stamina"`
- // LastLogoutTick int64 `json:"lastLogoutTick"`
- // FirstWeapon bool `json:"firstGame"`
- // Guide []int `json:"guide"`
- // Funs []int `json:"funs"`
- // Equipments []*model.DropEquipment `json:"equipments"`
- // Roles []*model.DropedRole `json:"roles"`
- // Treasures []*model.DropedTreasure `json:"treasures"`
- // Talents []*model.DropTalent `json:"talents"`
- // TalentPoint int `json:"talentPoint"`
- // PassRoom []*model.PlayerPassRoom `json:"passRoom"`
- // Buff *BuffData `json:"buff"`
- // LastChapter *model.ChapterSummary `json:"lastChapter"`
- // BodyParts []*model.BodyPart `json:"bodyParts"`
- // RoleCollocate []int `json:"roleCollocate"` // 角色羁绊
- // PayMethod *model.PayMethodData `json:"payMethod"`
- // DoubleAdCount int `json:"adCount"`
- // Location int `json:"adState"`
- // Flag int `json:"flag"`
- // MaxCombatEffe int64 `json:"maxCombatEffe"`
- // PaySwitch int `json:"paySwitch"`
- // New bool `json:"isNew"` // 新注册玩家
- // CreateTick int64 `json:"createTick"`
- // AutoCheckToken int `json:"autoCheckToken"` // 是否发送随机种子 0/1
- // NickName string `json:"nickName"`
- // ImgUrl string `json:"imgUrl"`
- // HeadId int `json:"headId"` // 头像 -1 代表使用 AvatarURL 微信授权头像
- // FrameId int `json:"frameId"` // 头像框
- // InviterStatus int `json:"inviterStatus"` // 邀请设置
- // List []*HeadFrameDataList `json:"framelist"`
- // VipId []int64 `json:"vipId"` // 截止到登录还生效的月卡 季卡 永久卡
- // CreateTime int64 `json:"createtime"`
- // NowTime int64 `json:"nowtime"`
- // RoleTreasure []*model.RoleTreasureInfo `json:"roleTreasure"` // 专属宝物
- }
- type ResponseEntry struct {
- ErrCode int `json:"errCode"`
- Msg string `json:"msg,omitempty"`
- Data *EntryData `json:"data"`
- }
- // ReLogin 重新连接
- type ReLogin struct {
- UID int64 `json:"userId"`
- ClientFlag int `json:"clientFlag"`
- Version string `json:"version"`
- Token string `json:"token"`
- }
- type ResponseReLogin struct {
- ErrCode int `json:"errCode"`
- Msg string `json:"msg,omitempty"`
- Data *EntryData `json:"data"`
- }
|