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
3fdb3d4e
Commit
3fdb3d4e
authored
Mar 25, 2023
by
Chunchi Che
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add counters in CardState
parent
f586fbb6
Pipeline
#20925
passed with stages
in 16 minutes and 37 seconds
Changes
8
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
23 additions
and
0 deletions
+23
-0
src/reducers/duel/cemeretySlice.ts
src/reducers/duel/cemeretySlice.ts
+1
-0
src/reducers/duel/deckSlice.ts
src/reducers/duel/deckSlice.ts
+1
-0
src/reducers/duel/exclusionSlice.ts
src/reducers/duel/exclusionSlice.ts
+1
-0
src/reducers/duel/extraDeckSlice.ts
src/reducers/duel/extraDeckSlice.ts
+2
-0
src/reducers/duel/generic.ts
src/reducers/duel/generic.ts
+2
-0
src/reducers/duel/handsSlice.ts
src/reducers/duel/handsSlice.ts
+3
-0
src/reducers/duel/magicSlice.ts
src/reducers/duel/magicSlice.ts
+6
-0
src/reducers/duel/monstersSlice.ts
src/reducers/duel/monstersSlice.ts
+7
-0
No files found.
src/reducers/duel/cemeretySlice.ts
View file @
3fdb3d4e
...
...
@@ -51,6 +51,7 @@ export const cemeteryCase = (builder: ActionReducerMapBuilder<DuelState>) => {
sequence
,
},
idleInteractivities
:
[],
counters
:
{},
};
if
(
judgeSelf
(
controler
,
state
))
{
extendState
(
state
.
meCemetery
,
newCemetery
);
...
...
src/reducers/duel/deckSlice.ts
View file @
3fdb3d4e
...
...
@@ -24,6 +24,7 @@ export const initDeckImpl: CaseReducer<
location
:
ygopro
.
CardZone
.
DECK
,
},
idleInteractivities
:
[],
counters
:
{},
});
}
...
...
src/reducers/duel/exclusionSlice.ts
View file @
3fdb3d4e
...
...
@@ -53,6 +53,7 @@ export const exclusionCase = (builder: ActionReducerMapBuilder<DuelState>) => {
sequence
,
},
idleInteractivities
:
[],
counters
:
{},
};
if
(
judgeSelf
(
controler
,
state
))
{
extendState
(
state
.
meExclusion
,
newExclusion
);
...
...
src/reducers/duel/extraDeckSlice.ts
View file @
3fdb3d4e
...
...
@@ -40,6 +40,7 @@ export const extraDeckCase = (builder: ActionReducerMapBuilder<DuelState>) => {
location
:
ygopro
.
CardZone
.
EXTRA
,
},
idleInteractivities
:
[],
counters
:
{},
};
});
state
.
meExtraDeck
=
{
inner
:
cards
};
...
...
@@ -64,6 +65,7 @@ export const extraDeckCase = (builder: ActionReducerMapBuilder<DuelState>) => {
sequence
,
},
idleInteractivities
:
[],
counters
:
{},
};
const
extraDeck
=
judgeSelf
(
controler
,
state
)
?
state
.
meExtraDeck
...
...
src/reducers/duel/generic.ts
View file @
3fdb3d4e
...
...
@@ -34,6 +34,7 @@ export interface CardState {
sequence
:
number
;
}
>
;
// 选择位置状态下的互动信息
overlay_materials
?:
CardMeta
[];
// 超量素材
counters
:
{
[
type
:
number
]:
number
};
// 指示器
reload
?:
boolean
;
// 这个字段会在收到MSG_RELOAD_FIELD的时候设置成true,在收到MSG_UPDATE_DATE的时候设置成false
}
...
...
@@ -351,6 +352,7 @@ export function reloadFieldMeta<T extends DuelFieldState>(
position
:
action
.
position
,
},
idleInteractivities
:
[],
counters
:
{},
reload
:
true
,
};
});
...
...
src/reducers/duel/handsSlice.ts
View file @
3fdb3d4e
...
...
@@ -93,6 +93,7 @@ export const handsCase = (builder: ActionReducerMapBuilder<DuelState>) => {
controler
:
player
,
location
:
ygopro
.
CardZone
.
HAND
,
},
counters
:
{},
idleInteractivities
:
[],
};
});
...
...
@@ -130,6 +131,7 @@ export const handsCase = (builder: ActionReducerMapBuilder<DuelState>) => {
occupant
:
{
id
:
code
,
data
:
{},
text
:
{}
},
location
:
{
controler
},
idleInteractivities
:
[],
counters
:
{},
});
});
builder
.
addCase
(
insertHandMeta
.
fulfilled
,
(
state
,
action
)
=>
{
...
...
@@ -154,6 +156,7 @@ export const handsCase = (builder: ActionReducerMapBuilder<DuelState>) => {
location
:
ygopro
.
CardZone
.
HAND
,
},
idleInteractivities
:
[],
counters
:
{},
};
});
...
...
src/reducers/duel/magicSlice.ts
View file @
3fdb3d4e
...
...
@@ -37,6 +37,7 @@ export const initMagicsImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
0
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -45,6 +46,7 @@ export const initMagicsImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
1
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -53,6 +55,7 @@ export const initMagicsImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
2
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -61,6 +64,7 @@ export const initMagicsImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
3
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -69,6 +73,7 @@ export const initMagicsImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
4
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
// 场地区
...
...
@@ -78,6 +83,7 @@ export const initMagicsImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
5
,
},
idleInteractivities
:
[],
counters
:
{},
},
],
};
...
...
src/reducers/duel/monstersSlice.ts
View file @
3fdb3d4e
...
...
@@ -40,6 +40,7 @@ export const initMonstersImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
0
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -48,6 +49,7 @@ export const initMonstersImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
1
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -56,6 +58,7 @@ export const initMonstersImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
2
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -64,6 +67,7 @@ export const initMonstersImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
3
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -72,6 +76,7 @@ export const initMonstersImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
4
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -80,6 +85,7 @@ export const initMonstersImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
5
,
},
idleInteractivities
:
[],
counters
:
{},
},
{
location
:
{
...
...
@@ -88,6 +94,7 @@ export const initMonstersImpl: CaseReducer<DuelState, PayloadAction<number>> = (
sequence
:
6
,
},
idleInteractivities
:
[],
counters
:
{},
},
],
};
...
...
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