Commit 1b638174 authored by Chunchi Che's avatar Chunchi Che

add selectUnselectInfo in matStore

parent 9adf71b6
Pipeline #26994 passed with stages
in 10 minutes and 48 seconds
...@@ -83,6 +83,11 @@ const initialState: Omit<MatState, "reset"> = { ...@@ -83,6 +83,11 @@ const initialState: Omit<MatState, "reset"> = {
}, },
}, },
tossResult: undefined, tossResult: undefined,
selectUnselectInfo: {
processing: false,
finishable: false,
cancelable: false,
},
chainSetting: ChainSetting.CHAIN_SMART, chainSetting: ChainSetting.CHAIN_SMART,
duelEnd: false, duelEnd: false,
// methods // methods
...@@ -101,6 +106,7 @@ class MatStore implements MatState, NeosStore { ...@@ -101,6 +106,7 @@ class MatStore implements MatState, NeosStore {
unimplemented = initialState.unimplemented; unimplemented = initialState.unimplemented;
handResults = initialState.handResults; handResults = initialState.handResults;
tossResult = initialState.tossResult; tossResult = initialState.tossResult;
selectUnselectInfo = initialState.selectUnselectInfo;
duelEnd = initialState.duelEnd; duelEnd = initialState.duelEnd;
// methods // methods
isMe = initialState.isMe; isMe = initialState.isMe;
...@@ -122,6 +128,12 @@ class MatStore implements MatState, NeosStore { ...@@ -122,6 +128,12 @@ class MatStore implements MatState, NeosStore {
this.unimplemented = 0; this.unimplemented = 0;
this.handResults.me = 0; this.handResults.me = 0;
this.handResults.op = 0; this.handResults.op = 0;
this.tossResult = undefined;
this.selectUnselectInfo = {
processing: false,
finishable: false,
cancelable: false,
};
this.duelEnd = false; this.duelEnd = false;
} }
} }
......
...@@ -34,6 +34,12 @@ export interface MatState { ...@@ -34,6 +34,12 @@ export interface MatState {
tossResult?: string; // 骰子/硬币结果 tossResult?: string; // 骰子/硬币结果
selectUnselectInfo: {
processing: boolean;
finishable: boolean;
cancelable: boolean;
};
handResults: BothSide<HandResult> & { handResults: BothSide<HandResult> & {
set: (controller: number, result: HandResult) => void; set: (controller: number, result: HandResult) => void;
}; // 猜拳结果 }; // 猜拳结果
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment