enhance(reversi): tweak reversi

This commit is contained in:
syuilo
2024-01-20 13:14:46 +09:00
parent f86d0186d2
commit b9a81edae5
16 changed files with 225 additions and 131 deletions

View File

@@ -76,11 +76,7 @@ export class MiReversiGame {
@Column('jsonb', {
default: [],
})
public logs: {
at: number;
color: boolean;
pos: number;
}[];
public logs: number[][];
@Column('varchar', {
array: true, length: 64,
@@ -117,9 +113,6 @@ export class MiReversiGame {
})
public form2: any | null;
/**
* ログのposを文字列としてすべて連結したもののCRC32値
*/
@Column('varchar', {
length: 32, nullable: true,
})

View File

@@ -204,22 +204,8 @@ export const packedReversiGameDetailedSchema = {
type: 'array',
optional: false, nullable: false,
items: {
type: 'object',
type: 'array',
optional: false, nullable: false,
properties: {
at: {
type: 'number',
optional: false, nullable: false,
},
color: {
type: 'boolean',
optional: false, nullable: false,
},
pos: {
type: 'number',
optional: false, nullable: false,
},
},
},
},
map: {