wip create working(?)
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
import iconv = require("iconv-lite");
|
||||
|
||||
import { RequestCode } from "./_defs";
|
||||
import { CreateProfileRequest } from "../request/createProfile";
|
||||
import { car } from "./_car";
|
||||
import { chara } from "./_chara";
|
||||
import { RequestCode } from "./_defs";
|
||||
import { CreateProfileRequest } from "../request/createProfile";
|
||||
import { AimeId } from "../../model";
|
||||
|
||||
createProfile.msgCode = 0x0066 as RequestCode;
|
||||
createProfile.msgLen = 0x00c0;
|
||||
@@ -11,7 +12,7 @@ createProfile.msgLen = 0x00c0;
|
||||
export function createProfile(buf: Buffer): CreateProfileRequest {
|
||||
return {
|
||||
type: "create_profile_req",
|
||||
aimeId: buf.readInt32LE(0x0004),
|
||||
aimeId: buf.readInt32LE(0x0004) as AimeId,
|
||||
luid: buf.slice(0x0008, buf.indexOf("\0", 0x0008)).toString("ascii"),
|
||||
name: iconv.decode(
|
||||
buf.slice(0x001e, buf.indexOf("\0", 0x001e)),
|
||||
|
||||
Reference in New Issue
Block a user