Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro
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
YGOPRO-520DIY
ygopro
Commits
ec176599
Commit
ec176599
authored
May 31, 2016
by
salix5
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
DEFENCE->DEFENSE
parent
e4b8fe8c
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
31 additions
and
31 deletions
+31
-31
gframe/client_card.cpp
gframe/client_card.cpp
+2
-2
gframe/client_field.cpp
gframe/client_field.cpp
+3
-3
gframe/event_handler.cpp
gframe/event_handler.cpp
+2
-2
gframe/replay_mode.cpp
gframe/replay_mode.cpp
+16
-16
gframe/single_duel.cpp
gframe/single_duel.cpp
+4
-4
gframe/tag_duel.cpp
gframe/tag_duel.cpp
+4
-4
No files found.
gframe/client_card.cpp
View file @
ec176599
...
...
@@ -100,7 +100,7 @@ void ClientCard::UpdateInfo(char* buf) {
}
else
myswprintf
(
atkstring
,
L"%d"
,
attack
);
}
if
(
flag
&
QUERY_DEFEN
C
E
)
{
if
(
flag
&
QUERY_DEFEN
S
E
)
{
defense
=
BufferIO
::
ReadInt32
(
buf
);
if
(
defense
<
0
)
{
defstring
[
0
]
=
'?'
;
...
...
@@ -110,7 +110,7 @@ void ClientCard::UpdateInfo(char* buf) {
}
if
(
flag
&
QUERY_BASE_ATTACK
)
base_attack
=
BufferIO
::
ReadInt32
(
buf
);
if
(
flag
&
QUERY_BASE_DEFEN
C
E
)
if
(
flag
&
QUERY_BASE_DEFEN
S
E
)
base_defense
=
BufferIO
::
ReadInt32
(
buf
);
if
(
flag
&
QUERY_REASON
)
reason
=
BufferIO
::
ReadInt32
(
buf
);
...
...
gframe/client_field.cpp
View file @
ec176599
...
...
@@ -91,7 +91,7 @@ void ClientField::Initial(int player, int deckc, int extrac) {
pcard
->
controler
=
player
;
pcard
->
location
=
0x40
;
pcard
->
sequence
=
i
;
pcard
->
position
=
POS_FACEDOWN_DEFEN
C
E
;
pcard
->
position
=
POS_FACEDOWN_DEFEN
S
E
;
GetCardLocation
(
pcard
,
&
pcard
->
curPos
,
&
pcard
->
curRot
);
pcard
->
mTransform
.
setTranslation
(
pcard
->
curPos
);
pcard
->
mTransform
.
setRotationRadians
(
pcard
->
curRot
);
...
...
@@ -878,7 +878,7 @@ void ClientField::GetCardLocation(ClientCard* pcard, irr::core::vector3df* t, ir
t
->
X
=
(
matManager
.
vFields
[
16
].
Pos
.
X
+
matManager
.
vFields
[
17
].
Pos
.
X
)
/
2
+
1.1
f
*
sequence
;
t
->
Y
=
(
matManager
.
vFields
[
16
].
Pos
.
Y
+
matManager
.
vFields
[
18
].
Pos
.
Y
)
/
2
;
t
->
Z
=
0.01
f
;
if
(
pcard
->
position
&
POS_DEFEN
C
E
)
{
if
(
pcard
->
position
&
POS_DEFEN
S
E
)
{
r
->
X
=
0.0
f
;
r
->
Z
=
-
3.1415926
f
/
2.0
f
;
if
(
pcard
->
position
&
POS_FACEDOWN
)
...
...
@@ -895,7 +895,7 @@ void ClientField::GetCardLocation(ClientCard* pcard, irr::core::vector3df* t, ir
t
->
X
=
(
matManager
.
vFields
[
84
].
Pos
.
X
+
matManager
.
vFields
[
85
].
Pos
.
X
)
/
2
-
1.1
f
*
sequence
;
t
->
Y
=
(
matManager
.
vFields
[
84
].
Pos
.
Y
+
matManager
.
vFields
[
86
].
Pos
.
Y
)
/
2
;
t
->
Z
=
0.01
f
;
if
(
pcard
->
position
&
POS_DEFEN
C
E
)
{
if
(
pcard
->
position
&
POS_DEFEN
S
E
)
{
r
->
X
=
0.0
f
;
r
->
Z
=
3.1415926
f
/
2.0
f
;
if
(
pcard
->
position
&
POS_FACEDOWN
)
...
...
gframe/event_handler.cpp
View file @
ec176599
...
...
@@ -198,12 +198,12 @@ bool ClientField::OnEvent(const irr::SEvent& event) {
break
;
}
case
BUTTON_POS_DU
:
{
DuelClient
::
SetResponseI
(
POS_FACEUP_DEFEN
C
E
);
DuelClient
::
SetResponseI
(
POS_FACEUP_DEFEN
S
E
);
mainGame
->
HideElement
(
mainGame
->
wPosSelect
,
true
);
break
;
}
case
BUTTON_POS_DD
:
{
DuelClient
::
SetResponseI
(
POS_FACEDOWN_DEFEN
C
E
);
DuelClient
::
SetResponseI
(
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
HideElement
(
mainGame
->
wPosSelect
,
true
);
break
;
}
...
...
gframe/replay_mode.cpp
View file @
ec176599
...
...
@@ -87,25 +87,25 @@ int ReplayMode::ReplayThread(void* param) {
if
(
!
(
opt
&
DUEL_TAG_MODE
))
{
int
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
int
extra
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
extra
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
dField
.
Initial
(
0
,
main
,
extra
);
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
extra
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
extra
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
dField
.
Initial
(
1
,
main
,
extra
);
}
else
{
int
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
int
extra
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
extra
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
dField
.
Initial
(
0
,
main
,
extra
);
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
...
...
@@ -115,10 +115,10 @@ int ReplayMode::ReplayThread(void* param) {
new_tag_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
LOCATION_EXTRA
);
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
extra
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
extra
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
dField
.
Initial
(
1
,
main
,
extra
);
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
...
...
@@ -226,25 +226,25 @@ void ReplayMode::Restart(bool refresh) {
if
(
!
(
opt
&
DUEL_TAG_MODE
))
{
int
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
int
extra
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
extra
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
dField
.
Initial
(
0
,
main
,
extra
);
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
extra
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
extra
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
dField
.
Initial
(
1
,
main
,
extra
);
}
else
{
int
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
int
extra
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
extra
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
dField
.
Initial
(
0
,
main
,
extra
);
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
...
...
@@ -254,10 +254,10 @@ void ReplayMode::Restart(bool refresh) {
new_tag_card
(
pduel
,
cur_replay
.
ReadInt32
(),
0
,
LOCATION_EXTRA
);
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
extra
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
extra
;
++
i
)
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
cur_replay
.
ReadInt32
(),
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
mainGame
->
dField
.
Initial
(
1
,
main
,
extra
);
main
=
cur_replay
.
ReadInt32
();
for
(
int
i
=
0
;
i
<
main
;
++
i
)
...
...
gframe/single_duel.cpp
View file @
ec176599
...
...
@@ -421,22 +421,22 @@ void SingleDuel::TPResult(DuelPlayer* dp, unsigned char tp) {
last_replay
.
Flush
();
last_replay
.
WriteInt32
(
pdeck
[
0
].
main
.
size
(),
false
);
for
(
int32
i
=
(
int32
)
pdeck
[
0
].
main
.
size
()
-
1
;
i
>=
0
;
--
i
)
{
new_card
(
pduel
,
pdeck
[
0
].
main
[
i
]
->
first
,
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
pdeck
[
0
].
main
[
i
]
->
first
,
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
last_replay
.
WriteInt32
(
pdeck
[
0
].
main
[
i
]
->
first
,
false
);
}
last_replay
.
WriteInt32
(
pdeck
[
0
].
extra
.
size
(),
false
);
for
(
int32
i
=
(
int32
)
pdeck
[
0
].
extra
.
size
()
-
1
;
i
>=
0
;
--
i
)
{
new_card
(
pduel
,
pdeck
[
0
].
extra
[
i
]
->
first
,
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
pdeck
[
0
].
extra
[
i
]
->
first
,
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
last_replay
.
WriteInt32
(
pdeck
[
0
].
extra
[
i
]
->
first
,
false
);
}
last_replay
.
WriteInt32
(
pdeck
[
1
].
main
.
size
(),
false
);
for
(
int32
i
=
(
int32
)
pdeck
[
1
].
main
.
size
()
-
1
;
i
>=
0
;
--
i
)
{
new_card
(
pduel
,
pdeck
[
1
].
main
[
i
]
->
first
,
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
pdeck
[
1
].
main
[
i
]
->
first
,
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
last_replay
.
WriteInt32
(
pdeck
[
1
].
main
[
i
]
->
first
,
false
);
}
last_replay
.
WriteInt32
(
pdeck
[
1
].
extra
.
size
(),
false
);
for
(
int32
i
=
(
int32
)
pdeck
[
1
].
extra
.
size
()
-
1
;
i
>=
0
;
--
i
)
{
new_card
(
pduel
,
pdeck
[
1
].
extra
[
i
]
->
first
,
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
pdeck
[
1
].
extra
[
i
]
->
first
,
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
last_replay
.
WriteInt32
(
pdeck
[
1
].
extra
[
i
]
->
first
,
false
);
}
last_replay
.
Flush
();
...
...
gframe/tag_duel.cpp
View file @
ec176599
...
...
@@ -393,12 +393,12 @@ void TagDuel::TPResult(DuelPlayer* dp, unsigned char tp) {
//
last_replay
.
WriteInt32
(
pdeck
[
0
].
main
.
size
(),
false
);
for
(
int32
i
=
(
int32
)
pdeck
[
0
].
main
.
size
()
-
1
;
i
>=
0
;
--
i
)
{
new_card
(
pduel
,
pdeck
[
0
].
main
[
i
]
->
first
,
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
pdeck
[
0
].
main
[
i
]
->
first
,
0
,
0
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
last_replay
.
WriteInt32
(
pdeck
[
0
].
main
[
i
]
->
first
,
false
);
}
last_replay
.
WriteInt32
(
pdeck
[
0
].
extra
.
size
(),
false
);
for
(
int32
i
=
(
int32
)
pdeck
[
0
].
extra
.
size
()
-
1
;
i
>=
0
;
--
i
)
{
new_card
(
pduel
,
pdeck
[
0
].
extra
[
i
]
->
first
,
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
pdeck
[
0
].
extra
[
i
]
->
first
,
0
,
0
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
last_replay
.
WriteInt32
(
pdeck
[
0
].
extra
[
i
]
->
first
,
false
);
}
//
...
...
@@ -415,12 +415,12 @@ void TagDuel::TPResult(DuelPlayer* dp, unsigned char tp) {
//
last_replay
.
WriteInt32
(
pdeck
[
3
].
main
.
size
(),
false
);
for
(
int32
i
=
(
int32
)
pdeck
[
3
].
main
.
size
()
-
1
;
i
>=
0
;
--
i
)
{
new_card
(
pduel
,
pdeck
[
3
].
main
[
i
]
->
first
,
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
pdeck
[
3
].
main
[
i
]
->
first
,
1
,
1
,
LOCATION_DECK
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
last_replay
.
WriteInt32
(
pdeck
[
3
].
main
[
i
]
->
first
,
false
);
}
last_replay
.
WriteInt32
(
pdeck
[
3
].
extra
.
size
(),
false
);
for
(
int32
i
=
(
int32
)
pdeck
[
3
].
extra
.
size
()
-
1
;
i
>=
0
;
--
i
)
{
new_card
(
pduel
,
pdeck
[
3
].
extra
[
i
]
->
first
,
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
C
E
);
new_card
(
pduel
,
pdeck
[
3
].
extra
[
i
]
->
first
,
1
,
1
,
LOCATION_EXTRA
,
0
,
POS_FACEDOWN_DEFEN
S
E
);
last_replay
.
WriteInt32
(
pdeck
[
3
].
extra
[
i
]
->
first
,
false
);
}
//
...
...
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