奇葩の灵梦

Results 4 comments of 奇葩の灵梦

```go switch e := elem.(type) { case *message.FaceElement: // 系统表情 case *message.MarketFaceElement: // 表情包 case *message.GroupImageElement: // 图片 } ```

这个新接口 https://api.live.bilibili.com/room/v1/Room/get_info?id=123 要补上吗? 其中id是rid也就是房间ID 返回json格式: ```go type GetRoomInfoResult struct { Code int `json:"code"` Msg string `json:"msg"` Message string `json:"message"` Data struct { Uid int `json:"uid"` RoomId int `json:"room_id"` ShortId int...

https://github.com/SocialSisterYi/bilibili-API-collect/blob/f2f1a52b5a2001d854cf204bc471510aae2a5344/login/login_action/readme.md?plain=1#L43 尝试了token字段填到key,会返回2400-登录密钥错误。其他找了一下,叫key的字段只有公钥了,但是感觉显然不太可能是这个。

自己实现一下codec那个接口就行了,主要是`Encode`和`Decode`函数。下面例子是解析proto,直接调用google的那个proto库。解析json你就换成`json.Marshal`和`json.Unmashal`。解析lua你就找个解析lua的第三方库调用一下就行了。 ```go import ( "github.com/davyxu/cellnet" "github.com/davyxu/cellnet/util" "google.golang.org/protobuf/proto" "google.golang.org/protobuf/reflect/protoreflect" "google.golang.org/protobuf/reflect/protoregistry" "reflect" ) type protoCodec struct { } func (c *protoCodec) Name() string { return "protobuf" // 随便填 } func (c *protoCodec)...