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
dd863b0e
Commit
dd863b0e
authored
Jul 20, 2018
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
-9 for quitting random duel
parent
7f826778
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
0 deletions
+3
-0
ygopro-server.coffee
ygopro-server.coffee
+2
-0
ygopro-server.js
ygopro-server.js
+1
-0
No files found.
ygopro-server.coffee
View file @
dd863b0e
...
...
@@ -2727,6 +2727,8 @@ if settings.modules.random_duel.enabled
if
time_passed
>=
settings
.
modules
.
random_duel
.
hang_timeout
and
!
room
.
waiting_for_player
.
closed
room
.
last_active_time
=
moment
()
ROOM_ban_player
(
room
.
waiting_for_player
.
name
,
room
.
waiting_for_player
.
ip
,
"${random_ban_reason_AFK}"
)
room
.
scores
[
room
.
waiting_for_player
.
name
]
=
-
9
#log.info room.waiting_for_player.name, room.scores[room.waiting_for_player.name]
ygopro
.
stoc_send_chat_to_room
(
room
,
"
#{
room
.
waiting_for_player
.
name
}
${kicked_by_system}"
,
ygopro
.
constants
.
COLORS
.
RED
)
room
.
waiting_for_player
.
server
.
destroy
()
else
if
time_passed
>=
(
settings
.
modules
.
random_duel
.
hang_timeout
-
20
)
and
not
(
time_passed
%
10
)
and
!
room
.
waiting_for_player
.
closed
...
...
ygopro-server.js
View file @
dd863b0e
...
...
@@ -3456,6 +3456,7 @@
if (time_passed >= settings.modules.random_duel.hang_timeout && !room.waiting_for_player.closed) {
room.last_active_time = moment();
ROOM_ban_player(room.waiting_for_player.name, room.waiting_for_player.ip, "${random_ban_reason_AFK}");
room.scores[room.waiting_for_player.name] = -9;
ygopro.stoc_send_chat_to_room(room, room.waiting_for_player.name + " ${kicked_by_system}", ygopro.constants.COLORS.RED);
room.waiting_for_player.server.destroy();
} else if (time_passed >= (settings.modules.random_duel.hang_timeout - 20) && !(time_passed % 10) && !room.waiting_for_player.closed) {
...
...
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