Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
S
srvpro
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
nanahira
srvpro
Commits
a43f84af
Commit
a43f84af
authored
Nov 26, 2018
by
mercury233
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add test_mode.surrender_anytime
parent
5f586497
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
3 deletions
+4
-3
data/default_config.json
data/default_config.json
+2
-1
ygopro-server.coffee
ygopro-server.coffee
+1
-1
ygopro-server.js
ygopro-server.js
+1
-1
No files found.
data/default_config.json
View file @
a43f84af
...
...
@@ -154,7 +154,8 @@
"test_mode"
:
{
"watch_public_hand"
:
false
,
"no_connect_count_limit"
:
false
,
"no_ban_player"
:
false
"no_ban_player"
:
false
,
"surrender_anytime"
:
false
},
"pre_util"
:
{
"enabled"
:
false
,
...
...
ygopro-server.coffee
View file @
a43f84af
...
...
@@ -2459,7 +2459,7 @@ ygopro.ctos_follow 'SURRENDER', true, (buffer, info, client, server)->
return
unless
room
if
!
room
.
started
or
room
.
hostinfo
.
mode
==
2
return
true
if
room
.
random_type
and
room
.
turn
<
3
and
not
client
.
flee_free
if
room
.
random_type
and
room
.
turn
<
3
and
not
client
.
flee_free
and
not
settings
.
modules
.
test_mode
.
surrender_anytime
ygopro
.
stoc_send_chat
(
client
,
"${surrender_denied}"
,
ygopro
.
constants
.
COLORS
.
BABYBLUE
)
return
true
return
false
...
...
ygopro-server.js
View file @
a43f84af
...
...
@@ -3044,7 +3044,7 @@
if
(
!
room
.
started
||
room
.
hostinfo
.
mode
===
2
)
{
return
true
;
}
if
(
room
.
random_type
&&
room
.
turn
<
3
&&
!
client
.
flee_free
)
{
if
(
room
.
random_type
&&
room
.
turn
<
3
&&
!
client
.
flee_free
&&
!
settings
.
modules
.
test_mode
.
surrender_anytime
)
{
ygopro
.
stoc_send_chat
(
client
,
"
${surrender_denied}
"
,
ygopro
.
constants
.
COLORS
.
BABYBLUE
);
return
true
;
}
...
...
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