Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First draft of commands for lobbies #15

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
112 changes: 112 additions & 0 deletions src/schema/lobby_command.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
import { Type } from "@sinclair/typebox";

import { ServiceSchema } from "../helpers";

export const lobbyCommandEndpoints = {
// Anybody, anytime
roll: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

// Requires vote
change_map: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

lock: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

unlock: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

// Requires boss
set_welcome_message: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},
set_meme: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},
rename: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},
set_rating_levels: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

// Host
makeready: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

speclock: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

forceplay: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

ban: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

unban: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

// Moderator
set_player_limit: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

vote_succeed: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

queue_vip: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

pull: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

settag: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

explain: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

set: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},

reset_consul: {
request: Type.Object({}, { additionalProperties: true }),
response: Type.Object({}, { additionalProperties: true }),
},
} as const satisfies ServiceSchema;