Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
N
Neos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
Neos
Commits
99eae70d
Commit
99eae70d
authored
Apr 26, 2023
by
timel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: jump mora cause duel never starting
parent
26cf22d9
Pipeline
#21381
failed with stages
in 2 minutes and 21 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
src/ui/Mora.tsx
src/ui/Mora.tsx
+4
-4
src/valtioStores/moraStore.ts
src/valtioStores/moraStore.ts
+2
-2
No files found.
src/ui/Mora.tsx
View file @
99eae70d
...
...
@@ -19,7 +19,7 @@ import {
unSelectTpAble
,
}
from
"
@/reducers/moraSlice
"
;
import
{
store
}
from
"
@/store
"
;
import
{
moraStore
}
from
"
@/valtioStores
"
;
import
{
moraStore
,
matStore
}
from
"
@/valtioStores
"
;
const
{
automation
:
{
isAiMode
,
isAiFirst
},
...
...
@@ -36,7 +36,7 @@ const Mora = () => {
const
selectHandAble
=
snapMora
.
selectHandAble
;
const
selectTpAble
=
snapMora
.
selectTpAble
;
const
duelHsStart
=
snapMora
.
duelStart
;
//
const duelHsStart = snapMora.duelStart;
const
navigate
=
useNavigate
();
const
{
player
,
passWd
,
ip
}
=
useParams
<
{
...
...
@@ -58,10 +58,10 @@ const Mora = () => {
useEffect
(()
=>
{
// 若对局已经开始,自动跳转
if
(
duelHsStart
)
{
if
(
!
selectHandAble
)
{
navigate
(
`/duel/
${
player
}
/
${
passWd
}
/
${
ip
}
`
);
}
},
[
duelHsStart
]);
},
[
selectHandAble
]);
useEffect
(()
=>
{
if
(
isAiMode
)
{
...
...
src/valtioStores/moraStore.ts
View file @
99eae70d
...
...
@@ -8,6 +8,6 @@ export interface MoraState {
export
const
moraStore
=
proxy
<
MoraState
>
({
duelStart
:
false
,
selectHandAble
:
fals
e
,
selectTpAble
:
fals
e
,
selectHandAble
:
tru
e
,
selectTpAble
:
tru
e
,
});
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment