Commit 2b6ddbcc authored by nanahira's avatar nanahira

fix sendchat

parent 21ce6360
......@@ -55,3 +55,5 @@
- yuzuthread(多线程执行器): ~/test/yuzuthread
- typed-reflector(反射器): ~/test/koishi-related/typed-reflector
- nfkit(工具库,事件触发器,IoC): ~/test/nfkit
- koishi: ~/test/koishi-related/koishi
- satori: ~/test/koishi-related/satori
......@@ -153,6 +153,14 @@ export class Client {
if (this.isInternal) {
return;
}
if (type <= NetPlayerType.OBSERVER) {
return this.send(
new YGOProStocChat().fromPartial({
msg: msg,
player_type: type,
}),
);
}
const locale = this.getLocale();
const lines = type <= NetPlayerType.OBSERVER ? [msg] : msg.split(/\r?\n/);
const sendTasks: Promise<unknown>[] = [];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment