源战役客户端
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

49 行
1.7 KiB

  1. --[[ string 名字
  2. int:8
  3. int:8
  4. int:8
  5. string
  6. int:32
  7. int:16 id
  8. int:8 0| 1| 2|
  9. ]]
  10. PictureProtoVo = PictureProtoVo or {}
  11. PictureProtoVo.pro_list = {
  12. [1] = {"role_id","l"}
  13. ,[2] = {"name","s"}
  14. ,[3] = {"sex","c"}
  15. ,[4] = {"career","c"}
  16. ,[5] = {"turn","c"} -- 转生次数
  17. ,[6] = {"vip_type","c"} -- vip类型(普通 or 至尊特权)
  18. ,[7] = {"vip_flag","c"} -- vip等级
  19. ,[8] = {"level","h"} --玩家等级
  20. ,[9] = {"fighting","l"} -- 战斗力
  21. ,[10] = {"picture","s"} -- 玩家上传的头像地址
  22. ,[11] = {"picture_ver","i"} -- 玩家上传的头像版本号(每次上传一个头像,自动加1
  23. ,[12] = {"profile_photo_id","i"} -- 本地头像图片id
  24. ,[13] = {"dress_id","i"} --头像装扮id
  25. ,[14] = {"sup_vip_type","c"} --是否是永久贵族 0|否 1|体验 2|永久
  26. }
  27. function PictureProtoVo.ReadFmt(target)
  28. local vo = nil
  29. local len = nil
  30. local list_vo = nil
  31. for i = 1, #PictureProtoVo.pro_list do
  32. vo = PictureProtoVo.pro_list[i]
  33. target[vo[1]] = UserMsgAdapter.ReadFmt(vo[2])
  34. -- if i == 13 then
  35. -- len = UserMsgAdapter.ReadFmt("h")
  36. -- target[vo[1]] = {}
  37. -- for j = 1,len do
  38. -- list_vo = {}
  39. -- for k = 1,#vo[2] do
  40. -- list_vo[vo[2][k][1]] = UserMsgAdapter.ReadFmt(vo[2][k][2])
  41. -- end
  42. -- table.insert(target[vo[1]],list_vo)
  43. -- end
  44. -- else
  45. -- target[vo[1]] = UserMsgAdapter.ReadFmt(vo[2])
  46. -- end
  47. end
  48. end