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
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
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
love_飞影
Neos
Commits
f89dedac
Commit
f89dedac
authored
May 28, 2023
by
Chunchi Che
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix chainEnd
parent
16aaeaa3
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
10 deletions
+24
-10
src/service/duel/chainEnd.ts
src/service/duel/chainEnd.ts
+7
-2
src/stores/cardStore.ts
src/stores/cardStore.ts
+16
-7
src/stores/matStore/methods/fetchHint.ts
src/stores/matStore/methods/fetchHint.ts
+1
-1
No files found.
src/service/duel/chainEnd.ts
View file @
f89dedac
import
{
ygopro
}
from
"
@/api
"
;
import
{
ygopro
}
from
"
@/api
"
;
import
{
matStore
}
from
"
@/stores
"
;
import
{
cardStore
,
matStore
}
from
"
@/stores
"
;
export
default
(
_chainEnd
:
ygopro
.
StocGameMessage
.
MsgChainEnd
)
=>
{
export
default
(
_chainEnd
:
ygopro
.
StocGameMessage
.
MsgChainEnd
)
=>
{
while
(
true
)
{
while
(
true
)
{
...
@@ -8,6 +8,11 @@ export default (_chainEnd: ygopro.StocGameMessage.MsgChainEnd) => {
...
@@ -8,6 +8,11 @@ export default (_chainEnd: ygopro.StocGameMessage.MsgChainEnd) => {
break
;
break
;
}
}
matStore
.
setChained
(
chain
,
undefined
);
const
target
=
cardStore
.
find
(
chain
);
if
(
target
)
{
target
.
chainIndex
=
undefined
;
}
else
{
console
.
warn
(
`<ChainEnd>target is null`
);
}
}
}
};
};
src/stores/cardStore.ts
View file @
f89dedac
...
@@ -41,21 +41,30 @@ export interface CardType {
...
@@ -41,21 +41,30 @@ export interface CardType {
class
CardStore
{
class
CardStore
{
inner
:
CardType
[]
=
[];
inner
:
CardType
[]
=
[];
at
(
zone
:
ygopro
.
CardZone
,
controller
:
number
):
CardType
[];
at
(
zone
:
ygopro
.
CardZone
,
controller
:
number
):
CardType
[];
at
(
zone
:
ygopro
.
CardZone
,
controller
:
number
,
sequence
?:
number
):
CardType
;
at
(
zone
:
ygopro
.
CardZone
,
controller
:
number
,
sequence
?:
number
):
CardType
|
undefined
;
at
(
zone
:
ygopro
.
CardZone
,
controller
:
number
,
sequence
?:
number
)
{
at
(
zone
:
ygopro
.
CardZone
,
controller
:
number
,
sequence
?:
number
)
{
if
(
sequence
!==
undefined
)
{
if
(
sequence
!==
undefined
)
{
return
this
.
inner
.
filter
(
return
this
.
inner
.
filter
(
(
card
)
=>
(
card
)
=>
card
.
zone
===
zone
&&
card
.
zone
===
zone
&&
card
.
controller
===
controller
&&
card
.
controller
===
controller
&&
card
.
sequence
===
sequence
card
.
sequence
===
sequence
)[
0
];
)
.
at
(
0
);
}
else
{
}
else
{
return
this
.
inner
.
filter
(
return
this
.
inner
.
filter
(
(
card
)
=>
card
.
zone
===
zone
&&
card
.
controller
===
controller
(
card
)
=>
card
.
zone
===
zone
&&
card
.
controller
===
controller
);
);
}
}
}
}
find
(
location
:
ygopro
.
CardLocation
):
CardType
|
undefined
{
return
this
.
at
(
location
.
location
,
location
.
controler
,
location
.
sequence
);
}
}
}
export
const
cardStore
=
proxy
(
new
CardStore
());
export
const
cardStore
=
proxy
(
new
CardStore
());
...
...
src/stores/matStore/methods/fetchHint.ts
View file @
f89dedac
...
@@ -69,7 +69,7 @@ export const fetchEsHintMeta = async ({
...
@@ -69,7 +69,7 @@ export const fetchEsHintMeta = async ({
location
.
controler
,
location
.
controler
,
location
.
sequence
location
.
sequence
);
);
if
(
fieldMeta
.
text
.
name
)
{
if
(
fieldMeta
?
.
text
.
name
)
{
esHint
=
esHint
.
replace
(
"
[?]
"
,
fieldMeta
.
text
.
name
);
esHint
=
esHint
.
replace
(
"
[?]
"
,
fieldMeta
.
text
.
name
);
}
}
}
}
...
...
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