diff --git a/client/http_api.go b/client/http_api.go index 3d37f998..35ae0b63 100644 --- a/client/http_api.go +++ b/client/http_api.go @@ -11,7 +11,6 @@ import ( "net/textproto" "net/url" "strconv" - "strings" "github.com/pkg/errors" @@ -21,51 +20,6 @@ import ( "github.com/Mrs4s/MiraiGo/utils" ) -/* -------- VipInfo -------- */ - -type VipInfo struct { - Uin int64 - Name string - Level int - LevelSpeed float64 - VipLevel string - VipGrowthSpeed int - VipGrowthTotal int -} - -func (c *QQClient) GetVipInfo(target int64) (*VipInfo, error) { - b, err := utils.HttpGetBytes(fmt.Sprintf("https://h5.vip.qq.com/p/mc/cardv2/other?platform=1&qq=%d&adtag=geren&aid=mvip.pingtai.mobileqq.androidziliaoka.fromqita", target), c.getCookiesWithDomain("h5.vip.qq.com")) - if err != nil { - return nil, err - } - ret := VipInfo{Uin: target} - b = b[bytes.Index(b, []byte(``))+24:] - t := b[:bytes.Index(b, []byte(``))] - ret.Name = string(t) - b = b[bytes.Index(b, []byte(`LV`))+17:] - t = b[:bytes.Index(b, []byte(`
`))] - ret.Level, _ = strconv.Atoi(string(t)) - b = b[bytes.Index(b, []byte(``))+3:]
- t = b[:bytes.Index(b, []byte(`倍`))]
- ret.LevelSpeed, _ = strconv.ParseFloat(string(t), 64)
- b = b[bytes.Index(b, []byte(` `))+3:]
- st := string(b[:bytes.Index(b, []byte(` `))+3:]
- t = b[:bytes.Index(b, []byte(` `))+3:]
- t = b[:bytes.Index(b, []byte(`