@battle-racing/br-common-lib
Version:
Common library for all Battle Racing Repositorios
27 lines (26 loc) • 906 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.kartHardwareStateSchema = void 0;
const zod_1 = require("zod");
const checkpoint_1 = require("../checkpoint");
const hardware_1 = require("../hardware");
exports.kartHardwareStateSchema = zod_1.z.object({
speed: zod_1.z
.object({
status: hardware_1.speedStatusSchema,
current: zod_1.z.number(),
configured: zod_1.z.number(),
})
.nullable(),
rgb: hardware_1.rgbStatusSchema.nullable(),
flag: zod_1.z
.object({
status: hardware_1.flagStatusSchema,
checkpointType: checkpoint_1.checkpointTypeSchema.nullable(),
checkpointAddress: zod_1.z.number().nullable(),
})
.nullable(),
screen: hardware_1.screenStatusSchema.nullable(),
isConnectedToServer: zod_1.z.boolean(),
isSteeringWheelPressed: zod_1.z.boolean(),
});