diff --git a/Common.py b/Common.py
index fd10af5..1ee0026 100644
--- a/Common.py
+++ b/Common.py
@@ -321,7 +321,7 @@ class downloader(XiGuaLiveApi):
if self.__danmakuBiasTime is None:
return
ts = (now - self.__danmakuBiasTime).total_seconds()
- _c = """""".format(ts, gift.user.name, gift.name, gift.count)
+ _c = """\r\n""".format(ts, gift.user.name, gift.name, gift.count)
self.__danmakuFile.write(_c.encode("UTF-8"))
def onChat(self, chat):
@@ -330,14 +330,9 @@ class downloader(XiGuaLiveApi):
if self.__danmakuBiasTime is None:
return
ts = (now - self.__danmakuBiasTime).total_seconds()
- _c = """{}""".format(ts, now.timestamp()*1000, chat.user.ID, chat.user.name, chat.content)
+ _c = """{}\r\n""".format(ts, now.timestamp()*1000, chat.user.ID, chat.user.name, chat.content)
self.__danmakuFile.write(_c.encode("UTF-8"))
- def getDanmaku(self):
- super(downloader, self).getDanmaku()
- if self.__danmakuFile is not None and self.__danmakuFile.writable():
- self.__danmakuFile.flush()
-
@property
def playlist(self):
return self.__playlist