refactor a bit more
This commit is contained in:
+1
-6
@@ -1,5 +1,5 @@
|
||||
import { sock } from "./server.js";
|
||||
import { Commands, CommandsByValue } from "./func_replacements.js";
|
||||
import { ControlCommands, Commands, CommandsByValue } from "./datatypes.js";
|
||||
import { createWriteStream } from "node:fs";
|
||||
import { SendUsrAck, SendUsrChk, create_P2pRdy } from "./impl.js";
|
||||
|
||||
@@ -97,11 +97,6 @@ const deal_with_data = (dv: DataView) => {
|
||||
}
|
||||
};
|
||||
|
||||
const ControlCommands = {
|
||||
ConnectUser: 0x2010,
|
||||
ConnectUserAck: 0x2011,
|
||||
};
|
||||
|
||||
const makeDrwAck = (dv: DataView): DataView => {
|
||||
const pkt_id = dv.add(6).readU16();
|
||||
const m_stream = dv.add(5).readU8(); // data = 1, control = 0
|
||||
|
||||
Reference in New Issue
Block a user