From: qydysky Date: Thu, 7 Jan 2021 14:03:04 +0000 (+0800) Subject: 类型修正 解释 X-Git-Tag: v0.5.6~2^2~25 X-Git-Url: http://127.0.0.1:8081/?a=commitdiff_plain;h=c0fe0d7d5da19fd9a5365523304e5fa08cdacf70;p=bili_danmu%2F.git 类型修正 解释 --- diff --git a/README.md b/README.md index 48fa0ce..959e50b 100644 --- a/README.md +++ b/README.md @@ -90,10 +90,12 @@ golang go version go1.15 linux/amd64 #### 私信 在登录后,可以使用私信 + 私信配置在`demo/config/config_K_v.json`有说明 #### 语音 调用tts默认使用ffplay,安装[ffmpeg](http://ffmpeg.org/download.html) + 或使用其他程序:可在`demo/config/config_K_v.json`中编辑调用的程序及附加选项 ``` config_K_v.json diff --git a/Reply/README.md b/Reply/README.md index 30df87f..e4b3011 100644 --- a/Reply/README.md +++ b/Reply/README.md @@ -4,6 +4,7 @@ |目录|说明| |-|-| |./|接收的数据处理区| +|ws_msg/|弹幕服务器传回的Msg类型json的golang struct表述| |0Init.go|最初始载入配置| |F.go|附加功能| |Heartbeat.go|人气数据分派| diff --git a/Reply/Reply.go b/Reply/Reply.go index 7f67897..ebf6382 100644 --- a/Reply/Reply.go +++ b/Reply/Reply.go @@ -524,7 +524,7 @@ func (replyF) panel(s string){ //Msg-热门榜变动 func (replyF) hot_rank_changed(s string){ - msglog := msglog.Base_add("房").Log_show_control(false) + msglog := msglog.Base_add("房") var type_item ws_msg.HOT_RANK_CHANGED if e := json.Unmarshal([]byte(s), &type_item);e != nil { @@ -537,7 +537,6 @@ func (replyF) hot_rank_changed(s string){ } else { c.Note += strconv.Itoa(type_item.Data.Rank) } - fmt.Println("热门榜", c.Note) msglog.L(`I: `, "热门榜", c.Note) } } diff --git a/Reply/ws_msg/HOT_RANK_CHANGED.go b/Reply/ws_msg/HOT_RANK_CHANGED.go index 93bd398..4f498ac 100644 --- a/Reply/ws_msg/HOT_RANK_CHANGED.go +++ b/Reply/ws_msg/HOT_RANK_CHANGED.go @@ -5,8 +5,8 @@ type HOT_RANK_CHANGED struct { Data struct { Rank int `json:"rank"` Trend int `json:"trend"` - Countdown string `json:"countdown"` - Timestamp string `json:"timestamp"` + Countdown int `json:"countdown"` + Timestamp int `json:"timestamp"` Web_url string `json:"web_url"` Live_url string `json:"live_url"` Blink_url string `json:"blink_url"` diff --git a/Reply/ws_msg/README.md b/Reply/ws_msg/README.md new file mode 100644 index 0000000..f03ebe4 --- /dev/null +++ b/Reply/ws_msg/README.md @@ -0,0 +1,8 @@ + +--- +### 目录释义 +|目录|说明| +|-|-| +|./|弹幕服务器传回的Msg类型json的golang struct表述| +|HOT_RANK_CHANGED.go|热门榜位置改变| +--- \ No newline at end of file