Update typings for bootstrapper for 0.11.13
All checks were successful
Build / build (pull_request) Successful in 1m27s
All checks were successful
Build / build (pull_request) Successful in 1m27s
This commit is contained in:
parent
1f8d437fad
commit
de544a437d
@ -1,16 +1,9 @@
|
||||
import type { RequestHandler } from "express";
|
||||
import type { ITunables } from "../../types/bootstrapperTypes.ts";
|
||||
|
||||
// This endpoint is specific to the OpenWF Bootstrapper: https://openwf.io/bootstrapper-manual
|
||||
|
||||
interface ITunables {
|
||||
prohibit_skip_mission_start_timer?: boolean;
|
||||
prohibit_fov_override?: boolean;
|
||||
prohibit_freecam?: boolean;
|
||||
prohibit_teleport?: boolean;
|
||||
prohibit_scripts?: boolean;
|
||||
}
|
||||
|
||||
const tunablesController: RequestHandler = (_req, res) => {
|
||||
export const tunablesController: RequestHandler = (_req, res) => {
|
||||
const tunables: ITunables = {};
|
||||
//tunables.prohibit_skip_mission_start_timer = true;
|
||||
//tunables.prohibit_fov_override = true;
|
||||
@ -19,5 +12,3 @@ const tunablesController: RequestHandler = (_req, res) => {
|
||||
//tunables.prohibit_scripts = true;
|
||||
res.json(tunables);
|
||||
};
|
||||
|
||||
export { tunablesController };
|
||||
|
||||
@ -8,6 +8,7 @@ import type { IDatabaseAccountJson } from "../types/loginTypes.ts";
|
||||
import type { HydratedDocument } from "mongoose";
|
||||
import { logError, logger } from "../utils/logger.ts";
|
||||
import type { Request } from "express";
|
||||
import type { ITunables } from "../types/bootstrapperTypes.ts";
|
||||
|
||||
let wsServer: WebSocketServer | undefined;
|
||||
let wssServer: WebSocketServer | undefined;
|
||||
@ -89,8 +90,9 @@ interface IWsMsgToClient {
|
||||
logged_out?: boolean;
|
||||
have_game_ws?: boolean;
|
||||
|
||||
// to game
|
||||
// to game/bootstrapper (https://openwf.io/bootstrapper-manual)
|
||||
sync_inventory?: boolean;
|
||||
tunables?: ITunables;
|
||||
}
|
||||
|
||||
const wsOnConnect = (ws: WebSocket, req: http.IncomingMessage): void => {
|
||||
|
||||
9
src/types/bootstrapperTypes.ts
Normal file
9
src/types/bootstrapperTypes.ts
Normal file
@ -0,0 +1,9 @@
|
||||
// This is specific to the OpenWF Bootstrapper: https://openwf.io/bootstrapper-manual
|
||||
export interface ITunables {
|
||||
token?: string;
|
||||
prohibit_skip_mission_start_timer?: boolean;
|
||||
prohibit_fov_override?: boolean;
|
||||
prohibit_freecam?: boolean;
|
||||
prohibit_teleport?: boolean;
|
||||
prohibit_scripts?: boolean;
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user