Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
ziqian zhang
Grasscutter
Commits
765f569e
Commit
765f569e
authored
May 02, 2022
by
KingRainbow44
Browse files
Initialize `ServerHook`
parent
2c3c5937
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/emu/grasscutter/Grasscutter.java
View file @
765f569e
...
...
@@ -10,6 +10,7 @@ import java.util.Calendar;
import
emu.grasscutter.command.CommandMap
;
import
emu.grasscutter.plugin.PluginManager
;
import
emu.grasscutter.plugin.api.ServerHook
;
import
emu.grasscutter.scripts.ScriptLoader
;
import
emu.grasscutter.utils.Utils
;
import
org.reflections.Reflections
;
...
...
@@ -83,6 +84,8 @@ public final class Grasscutter {
// Create server instances.
dispatchServer
=
new
DispatchServer
();
gameServer
=
new
GameServer
(
new
InetSocketAddress
(
getConfig
().
getGameServerOptions
().
Ip
,
getConfig
().
getGameServerOptions
().
Port
));
// Create a server hook instance with both servers.
new
ServerHook
(
gameServer
,
dispatchServer
);
// Start servers.
if
(
getConfig
().
RunMode
==
ServerRunMode
.
HYBRID
)
{
...
...
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