Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-core
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
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
ygopro-core
Commits
3730610e
Commit
3730610e
authored
Dec 27, 2018
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
disable hints in server mode
parent
e43543ea
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
libdebug.cpp
libdebug.cpp
+6
-0
No files found.
libdebug.cpp
View file @
3730610e
...
@@ -14,12 +14,14 @@
...
@@ -14,12 +14,14 @@
#include "ocgapi.h"
#include "ocgapi.h"
int32
scriptlib
::
debug_message
(
lua_State
*
L
)
{
int32
scriptlib
::
debug_message
(
lua_State
*
L
)
{
#ifndef YGOPRO_SERVER_MODE
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
lua_getglobal
(
L
,
"tostring"
);
lua_getglobal
(
L
,
"tostring"
);
lua_pushvalue
(
L
,
-
2
);
lua_pushvalue
(
L
,
-
2
);
lua_pcall
(
L
,
1
,
1
,
0
);
lua_pcall
(
L
,
1
,
1
,
0
);
interpreter
::
sprintf
(
pduel
->
strbuffer
,
"%s"
,
lua_tostring
(
L
,
-
1
));
interpreter
::
sprintf
(
pduel
->
strbuffer
,
"%s"
,
lua_tostring
(
L
,
-
1
));
handle_message
(
pduel
,
2
);
handle_message
(
pduel
,
2
);
#endif
return
0
;
return
0
;
}
}
int32
scriptlib
::
debug_add_card
(
lua_State
*
L
)
{
int32
scriptlib
::
debug_add_card
(
lua_State
*
L
)
{
...
@@ -174,6 +176,7 @@ int32 scriptlib::debug_reload_field_end(lua_State *L) {
...
@@ -174,6 +176,7 @@ int32 scriptlib::debug_reload_field_end(lua_State *L) {
return
0
;
return
0
;
}
}
int32
scriptlib
::
debug_set_ai_name
(
lua_State
*
L
)
{
int32
scriptlib
::
debug_set_ai_name
(
lua_State
*
L
)
{
#ifndef YGOPRO_SERVER_MODE
check_param_count
(
L
,
1
);
check_param_count
(
L
,
1
);
check_param
(
L
,
PARAM_TYPE_STRING
,
1
);
check_param
(
L
,
PARAM_TYPE_STRING
,
1
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
...
@@ -187,9 +190,11 @@ int32 scriptlib::debug_set_ai_name(lua_State *L) {
...
@@ -187,9 +190,11 @@ int32 scriptlib::debug_set_ai_name(lua_State *L) {
pduel
->
bufferp
+=
len
;
pduel
->
bufferp
+=
len
;
pduel
->
bufferlen
+=
len
;
pduel
->
bufferlen
+=
len
;
pduel
->
write_buffer8
(
0
);
pduel
->
write_buffer8
(
0
);
#endif
return
0
;
return
0
;
}
}
int32
scriptlib
::
debug_show_hint
(
lua_State
*
L
)
{
int32
scriptlib
::
debug_show_hint
(
lua_State
*
L
)
{
#ifndef YGOPRO_SERVER_MODE
check_param_count
(
L
,
1
);
check_param_count
(
L
,
1
);
check_param
(
L
,
PARAM_TYPE_STRING
,
1
);
check_param
(
L
,
PARAM_TYPE_STRING
,
1
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
...
@@ -203,5 +208,6 @@ int32 scriptlib::debug_show_hint(lua_State *L) {
...
@@ -203,5 +208,6 @@ int32 scriptlib::debug_show_hint(lua_State *L) {
pduel
->
bufferp
+=
len
;
pduel
->
bufferp
+=
len
;
pduel
->
bufferlen
+=
len
;
pduel
->
bufferlen
+=
len
;
pduel
->
write_buffer8
(
0
);
pduel
->
write_buffer8
(
0
);
#endif
return
0
;
return
0
;
}
}
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