idz: Add explicit CreateProfileResponse
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
import { CreateProfileResponse } from "../response/createProfile";
|
||||
|
||||
export function createProfile(res: CreateProfileResponse) {
|
||||
const buf = Buffer.alloc(0x0020);
|
||||
|
||||
// Shares message type code with the "generic" response
|
||||
buf.writeInt16LE(0x0001, 0x0000);
|
||||
buf.writeInt32LE(res.aimeId, 0x0004);
|
||||
|
||||
return buf;
|
||||
}
|
||||
@@ -2,6 +2,7 @@ import logger from "debug";
|
||||
|
||||
import { _team } from "./_team";
|
||||
import { checkTeamName } from "./checkTeamName";
|
||||
import { createProfile } from "./createProfile";
|
||||
import { createTeam } from "./createTeam";
|
||||
import { discoverProfile } from "./discoverProfile";
|
||||
import { generic } from "./generic";
|
||||
@@ -47,6 +48,9 @@ function encode110(res: Response): Buffer {
|
||||
case "create_auto_team_res":
|
||||
return _team(res);
|
||||
|
||||
case "create_profile_res":
|
||||
return createProfile(res);
|
||||
|
||||
case "create_team_res":
|
||||
return createTeam(res);
|
||||
|
||||
@@ -149,6 +153,9 @@ function encode130(res: Response): Buffer {
|
||||
case "create_auto_team_res":
|
||||
return _team(res);
|
||||
|
||||
case "create_profile_res":
|
||||
return createProfile(res);
|
||||
|
||||
case "create_team_res":
|
||||
return createTeam(res);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user