Move GameVersion and its tests to the api module and add prefix matching (42, 42.21, 42.21.0). Add the abstract Mod base class with ModContext, bound through a ScopedValue while the mod is constructed. Add mod discovery, mod.toml parsing (night-config TOML), validation of API and game versions and dependencies, dependency ordering, and per-mod class loaders in core.mods. Add Forge to load mods and call their lifecycle methods from ServerHooks, and ConsoleLogger for log output. Add tests for versions, descriptors, discovery, resolution, and loading.
This commit is contained in:
1 parent
837367047c
commit
df4d58a279
46 files changed
+1846
-131
No files matched your search
@@ -2,7 +2,7 @@
|
||||
#
|
||||
# Container entrypoint: starts the patched Project Zomboid dedicated server
|
||||
# with the ZomboidForge agent. Arguments are passed through to
|
||||
# zombie.network.GameServer.
|
||||
# zombie.network.GameServer. Java mods are loaded from /forge/mods/<id>/.
|
||||
#
|
||||
# Environment variables (unset or empty keep the value in the server .ini, or the game default):
|
||||
#
|
||||
@@ -46,6 +46,7 @@ set -o pipefail
|
||||
|
||||
readonly INSTALL_DIR="/opt/pz"
|
||||
readonly DATA_DIR="/data"
|
||||
readonly FORGE_DIR="/forge"
|
||||
readonly AGENT_JAR="${INSTALL_DIR}/zomboidforge-agent.jar"
|
||||
readonly JAVA="${INSTALL_DIR}/jre64/bin/java"
|
||||
readonly SANDBOX_PRESET_DIR="${INSTALL_DIR}/media/lua/shared/Sandbox"
|
||||
@@ -235,6 +236,7 @@ check_admin_account() {
|
||||
build_jvm_args() {
|
||||
jvm_args=(
|
||||
"-javaagent:${AGENT_JAR}"
|
||||
"-Dzomboidforge.dir=${FORGE_DIR}"
|
||||
"-Djava.awt.headless=true"
|
||||
"--enable-native-access=ALL-UNNAMED"
|
||||
"-Xmx${JVM_MAX_HEAP}"
|
||||
|
||||
Reference in new issue
Block a user