53 lines
1.6 KiB
TypeScript
53 lines
1.6 KiB
TypeScript
import { IApiGameStartReq, IApiGameStartRes, IApiPlayerJoinReq, IApiPlayerJoinRes, IApiPlayerListReq, IApiPlayerListRes, IApiRoomCreateReq, IApiRoomCreateRes, IApiRoomJoinReq, IApiRoomJoinRes, IApiRoomLeaveReq, IApiRoomLeaveRes, IApiRoomListReq, IApiRoomListRes } from './Api'
|
|
import { ApiMsgEnum } from './Enum'
|
|
import { IMsgClientSync, IMsgGameStart, IMsgPlayerList, IMsgRoom, IMsgRoomList, IMsgServerSync } from './Msg'
|
|
export * from './Api'
|
|
export * from './Msg'
|
|
export * from './Enum'
|
|
export * from './Model'
|
|
export * from './State'
|
|
export * from './Utils'
|
|
export * from './Binary'
|
|
|
|
export interface IModel {
|
|
api: {
|
|
[ApiMsgEnum.ApiPlayerJoin]: {
|
|
req: IApiPlayerJoinReq,
|
|
res: IApiPlayerJoinRes,
|
|
}
|
|
[ApiMsgEnum.ApiPlayerList]: {
|
|
req: IApiPlayerListReq,
|
|
res: IApiPlayerListRes,
|
|
}
|
|
[ApiMsgEnum.ApiRoomList]: {
|
|
req: IApiRoomListReq,
|
|
res: IApiRoomListRes,
|
|
}
|
|
[ApiMsgEnum.ApiRoomCreate]: {
|
|
req: IApiRoomCreateReq,
|
|
res: IApiRoomCreateRes,
|
|
}
|
|
[ApiMsgEnum.ApiRoomJoin]: {
|
|
req: IApiRoomJoinReq,
|
|
res: IApiRoomJoinRes,
|
|
}
|
|
[ApiMsgEnum.ApiRoomLeave]: {
|
|
req: IApiRoomLeaveReq,
|
|
res: IApiRoomLeaveRes,
|
|
}
|
|
[ApiMsgEnum.ApiGameStart]: {
|
|
req: IApiGameStartReq,
|
|
res: IApiGameStartRes,
|
|
}
|
|
},
|
|
msg: {
|
|
[ApiMsgEnum.MsgPlayerList]: IMsgPlayerList
|
|
[ApiMsgEnum.MsgRoomList]: IMsgRoomList,
|
|
[ApiMsgEnum.MsgRoom]: IMsgRoom,
|
|
[ApiMsgEnum.MsgGameStart]: IMsgGameStart,
|
|
[ApiMsgEnum.MsgClientSync]: IMsgClientSync,
|
|
[ApiMsgEnum.MsgServerSync]: IMsgServerSync,
|
|
}
|
|
}
|
|
|