import Packet from "../packet"; import Stream from "../stream"; export class PacketKernelUpdate extends Packet { private url: string = ""; private version: string = ""; public getPacketId(): number { return 0x0D; } public _receive(stream: Stream): void { this.url = stream.readString(); this.version = stream.readString(); } public _send(): Promise | Stream { let stream = new Stream(); stream.writeInt16(this.getPacketId()); stream.writeString(this.url); stream.writeString(this.version); return stream; } public getUrl(): string { return this.url; } public setUrl(url: string): void { this.url = url; } public getVersion(): string { return this.version; } public setVersion(version: string): void { this.version = version; } }