It seems that you're using an outdated browser. Some things may not work as they should (or don't work at all).
We suggest you upgrade newer and better browser like: Chrome, Firefox, Internet Explorer or Opera

×
Hello!

I cannot find a way to host LAN game, is that possible at all?

Thanks,
Marko
Hello! I'm not sure what platform you are on, but it should be as simple as running ProjectZomboidServer.bat / .sh from the game's install directory.
Thanks. I gathered that much from info on the net. But I looked all over the installation directory, and there seem to be no such file. There is PZServerSettings.sh to set up all the details, but nothing to run the actual server. I'm on Linux.
avatar
m12425: Thanks. I gathered that much from info on the net. But I looked all over the installation directory, and there seem to be no such file. There is PZServerSettings.sh to set up all the details, but nothing to run the actual server. I'm on Linux.
On Linux there should be a server script packaged in the game contents. I can't remember exactly what it's called offhand; will run it by our Linux guy real quick. Cheers!
Below is the .sh script to start the server. Hopefully the forum doesn't break the formatting. Put it in a shell script such as ProjectZomboid/projectzomboid/start-server.sh.



#!/bin/bash

INSTDIR="`dirname $0`" ; cd "${INSTDIR}" ; INSTDIR="`pwd`"
JARPATH="./:./jinput.jar:./lwjgl.jar:./lwjgl_util.jar:./sqlite-jdbc-3.8.10.1.jar:./uncommons-maths-1.2.3.jar"

if "${INSTDIR}/jre64/bin/java" -version > /dev/null 2>&1; then
echo "64-bit java detected"
export PATH="${INSTDIR}/jre64/bin:$PATH"
export LD_LIBRARY_PATH="${INSTDIR}/linux64:${INSTDIR}:${INSTDIR}/jre64/lib/amd64:${LD_LIBRARY_PATH}"
JSIG="libjsig.so"
LD_PRELOAD="${LD_PRELOAD}:${JSIG}" "${INSTDIR}/jre64/bin/java" \
-cp "${JARPATH}" -Xms2048m -Xmx2048m \
-Dzomboid.steam=0 -Dzomboid.znetlog=1 \
-Djava.library.path=linux64/:./ \
-XX:-UseSplitVerifier -Djava.security.egd=file:/dev/urandom \
zombie/network/GameServer "$@"
elif "${INSTDIR}/jre/bin/java" -client -version > /dev/null 2>&1; then
echo "32-bit java detected"
export PATH="${INSTDIR}/jre/bin:$PATH"
export LD_LIBRARY_PATH="${INSTDIR}/linux32:${INSTDIR}:${INSTDIR}/jre/lib/i386:${LD_LIBRARY_PATH}"
JSIG="libjsig.so"
LD_PRELOAD="${LD_PRELOAD}:${JSIG}" "${INSTDIR}/jre/bin/java" -client \
-cp "${JARPATH}" -Xms768m -Xmx768m \
-Dzomboid.steam=0 -Dzomboid.znetlog=1 \
-Djava.library.path=linux32/:./ \
-XX:-UseSplitVerifier -Djava.security.egd=file:/dev/urandom \
zombie/network/GameServer "$@"
else
echo "couldn't determine 32/64 bit of java"
fi
exit 0
avatar
EasyPickins: Below is the .sh script to start the server. Hopefully the forum doesn't break the formatting.
Better to stick it on one of the paste sites and link to it. Hmm, don't believe you can post proper clickable links yet (remove the protocol). Guess you could always do both.
Link to start-server.sh pastebin.com/bs9YSgT3
Post edited January 30, 2016 by EasyPickins
Great. Thanks. The script works. I had to put it into ProjectZomboid/game/projectzomboid or change the INSTDIR variable appropriately.
Ah, we forgot the sh file for servers then. It's usually downloaded in a separate server package via SteamCMD, but of course that doesn't apply to GoG. :D

Sorry about that.
what effects does web design have on human's life ?
web design is a best way of introducing and advertising job and it make the human's life more faster and easier because of its options .
the people can find what ever they want inside web designs available in google
here are some links for your more information about web design


npco
sitecode
idea-soft
limotorsh
Is this info still correct for hosting LAN on Linux?
I'm getting the following when trying to run the start-server.sh

Exception in thread "main" java.lang.NoClassDefFoundError: com/Google/common/until/concurrent/FutureCallback
at zombie.network.GameServer.<clinit>(GameServer.java:157)
Caused by: java.lang.ClassNotFoundException: com.google.common.util.concurrent.FutureCallback
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.Classloader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 1 more
avatar
Alpha_Guardian: I'm getting the following when trying to run the start-server.sh

Exception in thread "main" java.lang.NoClassDefFoundError: com/Google/common/until/concurrent/FutureCallback
at zombie.network.GameServer.<clinit>(GameServer.java:157)
Caused by: java.lang.ClassNotFoundException: com.google.common.util.concurrent.FutureCallback
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.Classloader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 1 more
In case you get this (or anyone else finds this looking for a solution) I got it to work by editing start-server.sh to add guava-23.0.jar to the JARPATH. You can't just copy/paste the below line because of forum formatting issues, but it should look something like this:

JARPATH="./:./jinput.jar:./lwjgl.jar:./lwjgl_util.jar:./sqlite-jdbc-3.8.10.1.jar:./trove-3.0.3.jar:./uncommons -maths-1.2.3.jar:./guava-23.0.jar"

Note: There should not be a space between 'uncommons' and '-maths-1.2.3.jar' - other than that, that line should work.
Post edited July 19, 2019 by JeevesPleez
Thank you!

I will give this a try in Mint as well.

Do you have success running this dedicated server on a workstation that runs the game as well?

I have a 6-core AMD with 8GB RAM to run it.

Also, how do you allocate more memory to the server in case it starts lagging?
avatar
brianinthered: Thank you!

I will give this a try in Mint as well.

Do you have success running this dedicated server on a workstation that runs the game as well?

I have a 6-core AMD with 8GB RAM to run it.

Also, how do you allocate more memory to the server in case it starts lagging?
I believe I ran both the server and client at the same time, but it's been a while so I couldn't tell you for sure.

To change the memory size you should be able to specify the java virtual machine heap sizes.