Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
YGOMobile
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
fallenstardust
YGOMobile
Commits
43c8656f
Commit
43c8656f
authored
Jun 03, 2024
by
fallenstardust
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sync ocgcore
parent
4f83e133
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
0 deletions
+15
-0
Classes/ocgcore/field.h
Classes/ocgcore/field.h
+1
-0
Classes/ocgcore/libduel.cpp
Classes/ocgcore/libduel.cpp
+13
-0
Classes/ocgcore/scriptlib.h
Classes/ocgcore/scriptlib.h
+1
-0
No files found.
Classes/ocgcore/field.h
View file @
43c8656f
...
@@ -303,6 +303,7 @@ struct processor {
...
@@ -303,6 +303,7 @@ struct processor {
int32
summon_count
[
2
]{};
int32
summon_count
[
2
]{};
uint8
extra_summon
[
2
]{};
uint8
extra_summon
[
2
]{};
int32
spe_effect
[
2
]{};
int32
spe_effect
[
2
]{};
int32
last_select_hint
[
2
]{
0
};
int32
duel_options
{
0
};
int32
duel_options
{
0
};
int32
duel_rule
{
CURRENT_RULE
};
//current rule: 5, Master Rule 2020
int32
duel_rule
{
CURRENT_RULE
};
//current rule: 5, Master Rule 2020
uint32
copy_reset
{
0
};
uint32
copy_reset
{
0
};
...
...
Classes/ocgcore/libduel.cpp
View file @
43c8656f
...
@@ -3703,12 +3703,24 @@ int32 scriptlib::duel_hint(lua_State * L) {
...
@@ -3703,12 +3703,24 @@ int32 scriptlib::duel_hint(lua_State * L) {
if
(
htype
==
HINT_OPSELECTED
)
if
(
htype
==
HINT_OPSELECTED
)
playerid
=
1
-
playerid
;
playerid
=
1
-
playerid
;
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
if
(
htype
==
HINT_SELECTMSG
)
pduel
->
game_field
->
core
.
last_select_hint
[
playerid
]
=
desc
;
pduel
->
write_buffer8
(
MSG_HINT
);
pduel
->
write_buffer8
(
MSG_HINT
);
pduel
->
write_buffer8
(
htype
);
pduel
->
write_buffer8
(
htype
);
pduel
->
write_buffer8
(
playerid
);
pduel
->
write_buffer8
(
playerid
);
pduel
->
write_buffer32
(
desc
);
pduel
->
write_buffer32
(
desc
);
return
0
;
return
0
;
}
}
int32
scriptlib
::
duel_get_last_select_hint
(
lua_State
*
L
)
{
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
uint8
playerid
=
pduel
->
game_field
->
core
.
reason_player
;
if
(
lua_gettop
(
L
)
>=
1
)
playerid
=
(
uint8
)
lua_tointeger
(
L
,
1
);
if
(
playerid
!=
0
&&
playerid
!=
1
)
return
0
;
lua_pushinteger
(
L
,
pduel
->
game_field
->
core
.
last_select_hint
[
playerid
]);
return
1
;
}
int32
scriptlib
::
duel_hint_selection
(
lua_State
*
L
)
{
int32
scriptlib
::
duel_hint_selection
(
lua_State
*
L
)
{
check_param_count
(
L
,
1
);
check_param_count
(
L
,
1
);
check_param
(
L
,
PARAM_TYPE_GROUP
,
1
);
check_param
(
L
,
PARAM_TYPE_GROUP
,
1
);
...
@@ -4963,6 +4975,7 @@ static const struct luaL_Reg duellib[] = {
...
@@ -4963,6 +4975,7 @@ static const struct luaL_Reg duellib[] = {
{
"CheckRemoveOverlayCard"
,
scriptlib
::
duel_check_remove_overlay_card
},
{
"CheckRemoveOverlayCard"
,
scriptlib
::
duel_check_remove_overlay_card
},
{
"RemoveOverlayCard"
,
scriptlib
::
duel_remove_overlay_card
},
{
"RemoveOverlayCard"
,
scriptlib
::
duel_remove_overlay_card
},
{
"Hint"
,
scriptlib
::
duel_hint
},
{
"Hint"
,
scriptlib
::
duel_hint
},
{
"GetLastSelectHint"
,
scriptlib
::
duel_get_last_select_hint
},
{
"HintSelection"
,
scriptlib
::
duel_hint_selection
},
{
"HintSelection"
,
scriptlib
::
duel_hint_selection
},
{
"SelectEffectYesNo"
,
scriptlib
::
duel_select_effect_yesno
},
{
"SelectEffectYesNo"
,
scriptlib
::
duel_select_effect_yesno
},
{
"SelectYesNo"
,
scriptlib
::
duel_select_yesno
},
{
"SelectYesNo"
,
scriptlib
::
duel_select_yesno
},
...
...
Classes/ocgcore/scriptlib.h
View file @
43c8656f
...
@@ -569,6 +569,7 @@ public:
...
@@ -569,6 +569,7 @@ public:
static
int32
duel_remove_overlay_card
(
lua_State
*
L
);
static
int32
duel_remove_overlay_card
(
lua_State
*
L
);
static
int32
duel_hint
(
lua_State
*
L
);
static
int32
duel_hint
(
lua_State
*
L
);
static
int32
duel_get_last_select_hint
(
lua_State
*
L
);
static
int32
duel_hint_selection
(
lua_State
*
L
);
static
int32
duel_hint_selection
(
lua_State
*
L
);
static
int32
duel_select_effect_yesno
(
lua_State
*
L
);
static
int32
duel_select_effect_yesno
(
lua_State
*
L
);
static
int32
duel_select_yesno
(
lua_State
*
L
);
static
int32
duel_select_yesno
(
lua_State
*
L
);
...
...
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