Add player start entity command and related changes

This commit is contained in:
2026-03-31 03:00:38 +02:00
parent 1b06b754a6
commit cd5d0b5535
5 changed files with 231 additions and 3 deletions

View File

@@ -48,6 +48,14 @@ export function getSelectedBrushFaceId(selection: EditorSelection): BoxFaceId |
return selection.faceId;
}
export function getSingleSelectedEntityId(selection: EditorSelection): string | null {
if (selection.kind !== "entities" || selection.ids.length !== 1) {
return null;
}
return selection.ids[0];
}
export function isBrushSelected(selection: EditorSelection, brushId: string): boolean {
return (
(selection.kind === "brushes" && selection.ids.includes(brushId)) ||