Tutorial: (G)ZDoom multiplayer between Windows & Linux

Advanced OpenGL source port fork from ZDoom, picking up where ZDoomGL left off.
[Home] [Download] [Git builds (Win)] [Git builds (Mac)] [Wiki] [Repo] [Bugs&Suggestions]

Moderator: Graf Zahl

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Tutorial: (G)ZDoom multiplayer between Windows & Linux

Post by Fincer » Mon Feb 02, 2015 14:38

****

Old topic title was: "About linux version of GZDoom"

Tutorial part added afterwards.

****

I have a few questions related to GZDoom linux version. I would be thankful if you could answer them. :)

1. Issue with version numbering: <unknown version>. I'm using Arch Linux (64-bit). When compiling GZDoom successfully from source (github), the version number is always marked as <unknown version>. I've tried this with versions 2.0.0.3 and 2.0.0.4 of GZDoom. Both the same. How can I compile GZDoom on linux with the correct version number shown? I've used mainly AUR repository for compiling (https://aur.archlinux.org/packages/gzdoom/).

2. Windows & Linux versions compatibility question (Multiplayer). I have ZDL 3.2.2.3 daemon on Linux (see https://aur.archlinux.org/packages/zdl/). My friend has the same version of ZDL daemon on Windows 7 installed. However, if, on the contrary, GZDoom versions differ, does it cause a conflict such as inability to play Doom in multiplayer mode? And related to this question: If we basically have the same version of GZDoom (like 2.0.0.3) but mine is marked, however, as <unknown version>, does this still cause a conflict in multiplayer mode?

3. Source code of version 2.0.0.5. As referred in this topic, Windows binary of GZDoom 2.0.0.5 is available. When I last checked Github releases, I can't find source code for this version. Neither I can't find Windows binary of GZDoom 2.0.0.4 anywhere. If different versions of GZDoom conflict between each other in multiplayer, it leads to a problem: I can't install version 2.0.0.5 on my Linux machine and neither my friend can't easily install (yes, you can compile if you are talented) version 2.0.0.4 on his Windows 7 machine. This forces me and my friend to use older version 2.0.0.3 instead, and I'm not happy with this solution. So, could source code for version 2.0.0.5 be released in Github anytime soon?

Thanks in advance.
Last edited by Fincer on Mon Feb 09, 2015 18:55, edited 5 times in total.

User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Re: About linux version of GZDoom

Post by Graf Zahl » Mon Feb 02, 2015 18:59

Do you have the git command line utilities installed? The broken version number suggests you have not.

With this you can also retrieve the source for any branch or tag, including the release versions.

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Re: About linux version of GZDoom

Post by Fincer » Mon Feb 02, 2015 21:32

Do you have the git command line utilities installed? The broken version number suggests you have not.
Yes, I do:

Code: Select all

[fincer@fincer-laptop fincer]$ pacman -Q |grep git
git 2.2.2-1
With this you can also retrieve the source for any branch or tag, including the release versions.
Aah, okay. I think my installation method has been incorrect, though. I assume you mean the following method (or alike) is more correct. I built a tar.xz package manually on Arch Linux, so the final steps are more Arch-related stuff:

Code: Select all

[fincer@fincer-laptop fincer]$ git clone --mirror git://github.com/coelckers/gzdoom.git
[fincer@fincer-laptop fincer]$ cd ./gzdoom.git
[fincer@fincer-laptop gzdoom.git]$ git tag -l
2.1.0
2.1.1
2.1.2
2.1.3
2.1.4
2.1.5
2.1.6
2.1.7
2.2.0
2.3.0
2.3.1
2.4.0
2.4.1
2.5.0
2.6.0
2.6.1
2.7.0
2.8pre
G1.9pre
g1.8.07
g1.8.08
g1.8.09
g1.8.1
g1.8.2
g1.8.3
g1.8.4
g1.8.5
g1.8.6
g2.0.00_Beta
g2.0.01_Beta
g2.0.01pre
g2.0.02
g2.0.03
g2.0.04
g2.1.pre
g2.1pre
notok#2

[fincer@fincer-laptop gzdoom.git]$ git clone -b g2.0.04 git://github.com/coelckers/gzdoom.git gzdoom-g2.0.04
Cloning into 'gzdoom-g2.0.04'...
remote: Counting objects: 53470, done.
remote: Compressing objects: 100% (10327/10327), done.
remote: Total 53470 (delta 43074), reused 53470 (delta 43074)
Receiving objects: 100% (53470/53470), 19.12 MiB | 2.16 MiB/s, done.
Resolving deltas: 100% (43074/43074), done.
Checking connectivity... done.
Note: checking out '8fabd17c56995dc0611908554e13fbf036d5fd58'.
<blabla>
[fincer@fincer-laptop gzdoom.git]$ tar -zcf gzdoom-g2.0.04.tar.gz ./gzdoom-g2.0.04
[fincer@fincer-laptop gzdoom.git]$ mv gzdoom-g2.0.04.tar.gz /home/fincer/arch_linux_programs/gzdoom/
[fincer@fincer-laptop gzdoom]$ updpkgsums
<blabla>
[fincer@fincer-laptop gzdoom]$ makepkg
<source code is being compiled>
[fincer@fincer-laptop gzdoom]$ sudo pacman -U gzdoom-2.0.04-1-x86_64.pkg.tar.xz
(For people using Arch: I've used a modified PKGBUILD document)

With this method, I get rid of the <unknown version> label and instead, get the correct version number shown. Thank you! :cheers:

Issue 1 solved. Issues 2 and 3 still remain open.
Last edited by Fincer on Mon Feb 02, 2015 22:19, edited 3 times in total.

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Re: About linux version of GZDoom

Post by Fincer » Mon Feb 02, 2015 22:11

A little offtopic, sorry for that. Anyway, here is a quick fix for Arch Linux PKGBUILD file. It follows the above installation method. If you use Arch Linux and want GZDoom version number shown correctly (window title & command line), just copy & paste and replace the contents of old PKGBUILD file available currently in AUR with the following one:

Code: Select all

# This PKGBUILD is maintained at <https://github.com/grubber/archlinux-packages>
# Maintainer: Jan Cholasta <grubber at grubber cz>
# Contributor: Christoph Zeiler <rabyte*gmail>

pkgname=gzdoom
pkgver=2.0.04
pkgrel=1
pkgdesc="Doom source port based on ZDoom with an OpenGL renderer."
arch=('i686' 'x86_64')
url="http://www.osnanet.de/c.oelckers/gzdoom/"
license=('custom')
depends=('fluidsynth' 'fmodex4.26.36' 'glew' 'gtk2' 'gxmessage' 'sdl')
makedepends=('nasm' 'cmake' 'imagemagick' 'mesa' 'git')
optdepends=('blasphemer: Blasphemer (free Heretic) game data'
            'chexquest3-wad: Chex Quest 3 game data'
            'doom1-wad: Doom shareware game data'
            'freedoom: FreeDoom game data'
            'hacx-wad: HacX game data'
            'harmony-wad: Harmony game data'
            'heretic1-wad: Heretic shareware game data'
            'hexen1-wad: Hexen demo game data'
            'strife0-wad: Strife shareware game data'
            'urbanbrawl-wad: Urban Brawl: Action Doom 2 game data')
            
_gitroot="-b g$pkgver git://github.com/coelckers/gzdoom.git $pkgname-g$pkgver"
source=(config-update-fix.patch \
        doom-share-dir.patch \
        stack-noexec.patch \
        gzdoom.desktop)
md5sums=('eed301389f533effbd127681a3ddc2c5'
         '3ee3d6bb1f777445438bc40ae81a95df'
         '4778bb22190c445a4ed764c64432de12'
         '3f5920d839086c9ad04ed1338c3fb546')

_fmodver=4.26.36
_libdir=/usr/lib/gzdoom
_sharedir=/usr/share/games/gzdoom

prepare() {

    cd $srcdir/
    
    msg "Connecting to the GIT server...."
    git clone ${_gitroot}
    msg "GIT checkout done."
    msg "Starting make for: $pkgname"

  cd gzdoom-g$pkgver

  patch -p1 <"$srcdir/config-update-fix.patch"
  patch -p1 <"$srcdir/doom-share-dir.patch"
  patch -p1 <"$srcdir/stack-noexec.patch"

  sed -i "s|setPluginPath(progdir)|setPluginPath(\"$_libdir\")|" src/sound/fmodsound.cpp
}

build() {
  cd gzdoom-g$pkgver

  cmake -DFMOD_INCLUDE_DIR=/usr/include/fmodex-$_fmodver \
        -DFMOD_LIBRARY=/usr/lib/libfmodex-$_fmodver.so \
        -DCMAKE_C_FLAGS="$CFLAGS -DSHARE_DIR=\\\"$_sharedir\\\"" \
        -DCMAKE_CXX_FLAGS="$CXXFLAGS -DSHARE_DIR=\\\"$_sharedir\\\"" \
        .
  make

  convert "src/win32/icon1.ico[2]" gzdoom.png
}

package() {
  cd gzdoom-g$pkgver

  install -Dm755 gzdoom "$pkgdir/usr/bin/gzdoom"
  install -Dm755 liboutput_sdl.so "$pkgdir/$_libdir/liboutput_sdl.so"
  install -Dm644 gzdoom.pk3 "$pkgdir/$_sharedir/gzdoom.pk3"
  install -Dm644 brightmaps.pk3 "$pkgdir/$_sharedir/brightmaps.pk3"
  install -Dm644 lights.pk3 "$pkgdir/$_sharedir/lights.pk3"

  install -Dm644 gzdoom.png "$pkgdir/usr/share/pixmaps/gzdoom.png"
  install -Dm644 "$srcdir/gzdoom.desktop" "$pkgdir/usr/share/applications/gzdoom.desktop"
  install -Dm644 docs/BUILDLIC.TXT "$pkgdir/usr/share/licenses/$pkgname/BUILDLIC.TXT"
  install -Dm644 docs/doomlic.txt "$pkgdir/usr/share/licenses/$pkgname/DOOMLIC.TXT"
}
Please remember to include the patch files provided by GZDoom AUR tarball.

Edit:

I patched the build script a little. It works at least for the following GZDoom versions with AUR tarball patches used:
1.8.5
1.8.6
1.8.07
1.8.08
1.8.09
2.0.00_Beta
g2.1pre
2.0.01pre
2.0.01_Beta
2.0.02
2.0.03
2.0.04

If you want to install some of these specified versions instead of the default one, simply change pkgver to the wished version number in PKGBUILD file and run makepkg.

For example:
pkgver=2.1pre OR pkgver=1.8.09

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Tutorial: (G)ZDoom multiplayer between Windows & Linux

Post by Fincer » Mon Feb 09, 2015 3:32

Tutorial: (G)ZDoom multiplayer between Windows & Linux (Ubuntu, Mint & Arch)

Installation instructions

As a solution for the multiplayer between Windows & Linux, the following requirements would have to be met:
  • 1) It is available as Windows binary on the internet
    2) It is available as compile-friendly source code for Linux on Github
    3) It uses OpenGL 2.X
It became clear that the latest GZDoom version that could be used for multiplayer gaming (with taking abovementioned requirements into consideration) was version 1.8.6. Additionally for GZDoom, you also need to install ZDL Launcher. What you have to do to get multiplayer functioning in full is described below as step-by-step instructions:

Windows
  • 1) Download GZDoom 1.8.6 Win32 binary from here
    2) Download ZDL 3.2.2.3 beta daemon from here
    3) Start ZDL and set up the settings. Source Port for GZDoom executable is your gzdoom.exe. Set up your iWAD files and multiplayer settings (external files, internet port, game mode etc.). iWAD files are the main WAD files you want to play. External files are mod files, run within the main WAD you've selected.

    4) If you set up a server in ZDL, share your WAN/LAN IP with your client-side friends. If you're a client and your friend hosts the multiplayer server, get your friend's WAN/LAN IP and paste it to IP field in ZDL. Configure Multi Settings for a specific port address etc.

    5) Start multiplayer. Have fun!
Linux

Arch Linux
  • 1) Download & extract GZDoom AUR tarball (do NOT use pacaur or yaourt, see the following steps why not)
    2) Replace the contents of PKGBUILD file with the following one:

    Code: Select all

    # This PKGBUILD is maintained at <https://github.com/grubber/archlinux-packages>
    # Maintainer: Jan Cholasta <grubber at grubber cz>
    # Contributor: Christoph Zeiler <rabyte*gmail>
    
    pkgname=gzdoom
    pkgver=1.8.6
    pkgrel=1
    pkgdesc="Doom source port based on ZDoom with an OpenGL renderer."
    arch=('i686' 'x86_64')
    url="http://www.osnanet.de/c.oelckers/gzdoom/"
    license=('custom')
    depends=('fluidsynth' 'fmodex4.26.36' 'glew' 'gtk2' 'gxmessage' 'sdl')
    makedepends=('nasm' 'cmake' 'imagemagick' 'mesa' 'git')
    optdepends=('blasphemer: Blasphemer (free Heretic) game data'
                'chexquest3-wad: Chex Quest 3 game data'
                'doom1-wad: Doom shareware game data'
                'freedoom: FreeDoom game data'
                'hacx-wad: HacX game data'
                'harmony-wad: Harmony game data'
                'heretic1-wad: Heretic shareware game data'
                'hexen1-wad: Hexen demo game data'
                'strife0-wad: Strife shareware game data'
                'urbanbrawl-wad: Urban Brawl: Action Doom 2 game data')
                
    _gitroot="-b g$pkgver git://github.com/coelckers/gzdoom.git $pkgname-g$pkgver"
    source=(config-update-fix.patch \
            doom-share-dir.patch \
            stack-noexec.patch \
            gzdoom.desktop)
    md5sums=('eed301389f533effbd127681a3ddc2c5'
             '3ee3d6bb1f777445438bc40ae81a95df'
             '4778bb22190c445a4ed764c64432de12'
             '3f5920d839086c9ad04ed1338c3fb546')
    
    _fmodver=4.26.36
    _libdir=/usr/lib/gzdoom
    _sharedir=/usr/share/games/gzdoom
    
    prepare() {
    
        cd $srcdir/
        
        msg "Connecting to the GIT server...."
        git clone ${_gitroot}
        msg "GIT checkout done."
        msg "Starting make for: $pkgname"
    
      cd gzdoom-g$pkgver
    
      patch -p1 <"$srcdir/config-update-fix.patch"
      patch -p1 <"$srcdir/doom-share-dir.patch"
      patch -p1 <"$srcdir/stack-noexec.patch"
    
      sed -i "s|setPluginPath(progdir)|setPluginPath(\"$_libdir\")|" src/sound/fmodsound.cpp
    }
    
    build() {
      cd gzdoom-g$pkgver
    
      cmake -DFMOD_INCLUDE_DIR=/usr/include/fmodex-$_fmodver \
            -DFMOD_LIBRARY=/usr/lib/libfmodex-$_fmodver.so \
            -DCMAKE_C_FLAGS="$CFLAGS -DSHARE_DIR=\\\"$_sharedir\\\"" \
            -DCMAKE_CXX_FLAGS="$CXXFLAGS -DSHARE_DIR=\\\"$_sharedir\\\"" \
            .
      make
    
      convert "src/win32/icon1.ico[2]" gzdoom.png
    }
    
    package() {
      cd gzdoom-g$pkgver
    
      install -Dm755 gzdoom "$pkgdir/usr/bin/gzdoom"
      install -Dm755 liboutput_sdl.so "$pkgdir/$_libdir/liboutput_sdl.so"
      install -Dm644 gzdoom.pk3 "$pkgdir/$_sharedir/gzdoom.pk3"
      install -Dm644 brightmaps.pk3 "$pkgdir/$_sharedir/brightmaps.pk3"
      install -Dm644 lights.pk3 "$pkgdir/$_sharedir/lights.pk3"
    
      install -Dm644 gzdoom.png "$pkgdir/usr/share/pixmaps/gzdoom.png"
      install -Dm644 "$srcdir/gzdoom.desktop" "$pkgdir/usr/share/applications/gzdoom.desktop"
      install -Dm644 docs/BUILDLIC.TXT "$pkgdir/usr/share/licenses/$pkgname/BUILDLIC.TXT"
      install -Dm644 docs/doomlic.txt "$pkgdir/usr/share/licenses/$pkgname/DOOMLIC.TXT"
    }
    
    3) Compile GZDoom by running makepkg in command line in the same directory where PKGBUILD file locates. After compilation, install package by typing
    sudo pacman -U gzdoom-1.8.6-1-x86_64.pkg.tar.xz (64-bit)
    sudo pacman -U gzdoom-1.8.6-1-i686.pkg.tar.xz (32-bit)

    4) Install zdl 3.2.2.3 beta from AUR (or use pacaur -S zdl OR yaourt zdl)

    5) Copy gzdoom.pk3, brightmaps.pk3 & lights.pk3 from this Windows ZIP into /usr/share/games/gzdoom/ and replace the old ones. Requires root priviledges.

    6) Start ZDL and set up the settings. Source Port for GZDoom executable is located at /usr/bin/gzdoom. Set up your iWAD files and multiplayer settings (external files, internet port, game mode etc.). iWAD files are the main WAD files you want to play. External files are mod files, run within the main WAD you've selected.

    7) If you set up a server in ZDL, share your WAN/LAN IP with your client-side friends. If you're a client and your friend hosts the multiplayer server, get your friend's WAN/LAN IP and paste it to IP field in ZDL. Configure Multi Settings for a specific port address etc.

    8) Start multiplayer. Have fun!
Ubuntu & Linux Mint

Ubuntu and Linux Mint users have to install GZDoom and ZDL separately in order to play GZDoom online. There is no simple PPA way to do it at the moment since not many if any available deb packages are floating around the internet for these programs (as far as I know). Anyway, please read the following instructions to proceed with the installation.

For multiplayer between Windows & Linux, version 1.8.6 of GZDoom is recommended.

Whichever method you use to install GZDoom and ZDL, install prerequisites BEFORE installing the corresponding deb package!

GZDoom installation

Two individual installation methods are provided. Use either A) or B) Method, whichever you prefer over the other one.

A) Method - Precompiled package (easy for beginners):

Use one of these packages, depending on what Ubuntu/Linux Mint version you're running on your computer.

You can install an individual .deb packages eitheer by
  • - opening a new terminal
    - in terminal: go to the same directory where your .deb file locates
    - type the following command: sudo dpkg -i mydebfile.deb. Just replace string mydebfile with the real name of your deb file.
or using a graphical package manager (such as Ubuntu Software Center).

If you use terminal way, make sure you have all prerequisites installed first! If you, however, accidentally mess up with apt-get, run sudo apt-get install -f.

NOTE: The following deb packages have NOT been tested with ANY Linux Mint distribution. The compatilibity with Mint is estimated by using this Wikipedia article as a reference.

Ubuntu 13.10 (and Linux Mint 16)
Ubuntu 14.04 & 14.10 (and Linux Mint 17 & 17.1)
These packages work on Kubuntu 14.10 Plasma 5, too (with ZDL).

B) Method - DEB package from source code, automatic bash script provided below:

If, for a reason or another, precompiled packages are not suitable for you, I provide a fully automated bash script for building GZDoom easily from source into an installable DEB package. The script is tested on Ubuntu 13.10, 14.04 and 14.10 (32-bit & 64-bit versions) and should work with GZDoom 1.8.6, 1.8.09 & 2.0.04 Github source codes at least.

The script asks for root (sudo) password. The password is asked only for installing possibly missing packages required for successful compilation process. If you miss some critical packages, there would probably be a ton of required packages to be installed. Don't panic or get confused. All other script actions are run as normal user and do not require any user actions/interference.

After you've run the script you should see a new gzdoom_xxxx.deb file compiled in the same folder where this script is located at. Install this compiled deb package with Ubuntu Software Center (or equivalent) or simply by typing sudo dpkg -i gzdoom_xxxx.deb in terminal. You have to use correct deb file name here, of course.

Copy the script below and save it as a text file (gzdoom.sh for example). Execute it in terminal by typing bash gzdoom.sh or use equivalent command. The script may not work with sh command. I recommend you to use bash command instead.

Code: Select all

#!/bin/bash

PKGVERSION=1.8.6
SOURCEDIR=gzdoom-$PKGVERSION
_sharedir=/usr/share/games/gzdoom

sudo apt-get install git cmake imagemagick dh-make build-essential zlib1g-dev libsdl1.2-dev libsdl2-dev libjpeg-dev nasm tar libbz2-dev libgtk2.0-dev cmake git libfluidsynth-dev libgme-dev libgl1-mesa-dev libglew-dev

git clone -b g$PKGVERSION git://github.com/coelckers/gzdoom.git gzdoom-$PKGVERSION
cd $SOURCEDIR

if [ "$(uname -m)" = "x86_64" ]; then 
FMODFOLDER="fmodapi42636linux64" 
else
FMODFOLDER="fmodapi42636linux"
fi && \
wget -nc http://www.fmod.org/download/fmodex/api/Linux/$FMODFOLDER.tar.gz && \
tar -xvzf $FMODFOLDER.tar.gz -C ./

if [ "$(uname -m)" = "x86_64" ]; then
FMODFOLDER="fmodapi42636linux64"
FMODFILE="libfmodex64-4.26.36"
else
FMODFOLDER="fmodapi42636linux"
FMODFILE="libfmodex-4.26.36"
fi && \
cmake -DCMAKE_BUILD_TYPE=Release \
-DFMOD_LIBRARY=./$FMODFOLDER/api/lib/$FMODFILE.so \
-DFMOD_INCLUDE_DIR=./$FMODFOLDER/api/inc \
-DCMAKE_C_FLAGS="$CFLAGS -DSHARE_DIR=\\\"$_sharedir\\\"" \
-DCMAKE_CXX_FLAGS="$CXXFLAGS -DSHARE_DIR=\\\"$_sharedir\\\"" && \

make

convert "src/win32/icon1.ico[2]" gzdoom.png

printf "[Desktop Entry]\nEncoding=UTF-8\nVersion=1.0\nType=Application\nName=GZDoom\nGenericName=Enhanced Doom Engine\nIcon=gzdoom\nExec=gzdoom %F\nTerminal=false\nCategories=Game;ActionGame;\nStartupNotify=true\n" > gzdoom.desktop

mkdir -p ./$SOURCEDIR/usr/bin
mkdir -p ./$SOURCEDIR/usr/lib/gzdoom
mkdir -p ./$SOURCEDIR/usr/share/applications
mkdir -p ./$SOURCEDIR/usr/share/games/gzdoom
mkdir -p ./$SOURCEDIR/usr/share/licenses/gzdoom
mkdir -p ./$SOURCEDIR/usr/share/pixmaps
mkdir -p ./$SOURCEDIR/usr/share/licenses/gzdoom

mv gzdoom ./$SOURCEDIR/usr/bin/
mv ./output_sdl/liboutput_sdl.so ./$SOURCEDIR/usr/lib/gzdoom/
mv gzdoom.pk3 brightmaps.pk3 lights.pk3 ./$SOURCEDIR/usr/share/games/gzdoom/
mv gzdoom.png ./$SOURCEDIR/usr/share/pixmaps/
mv gzdoom.desktop ./$SOURCEDIR/usr/share/applications/
mv ./docs/BUILDLIC.TXT ./$SOURCEDIR/usr/share/licenses/gzdoom/
mv ./docs/doomlic.txt ./$SOURCEDIR/usr/share/licenses/gzdoom/
cp ./$FMODFOLDER/api/lib/$FMODFILE.so ./$SOURCEDIR/usr/lib/

cd ./$SOURCEDIR/

dh_make -s -y --createorig
mkdir -p ./debian/gzdoom/
cp -R ./usr ./debian/gzdoom/usr/
printf "usr/* usr/" > ./debian/gzdoom.install

dpkg-buildpackage -us -uc -b
cd ..
mv *.deb ../
ZDL - Installation

These ZDL installation instructions are for Ubuntu 13.10, 14.04, 14.10 & Linux Mint 16, 17 & 17.1.

About ZDL:

"ZDL is a feature rich Doom launcher for ZDoom and GZDoom. It supports multiplayer (WAN/LAN) and Doom mods (such as Brutal Doom)."Multiple mods can be loaded simultaneously into one game session."

I provide to two alternative installation methods for the latest ZDL 3.2.2.3 beta version.

A) Method - Precompiled package (easy for beginners):

Use one of these packages, depending on what OS architecture (amd64 or i386) you're running on your computer.

ZDL 3.2.2.3 beta (64-bit) - .deb file
ZDL 3.2.2.3 beta (32-bit) - .deb file

Prerequisites:

Code: Select all

sudo apt-get install libc6 libgcc1 libqt4-network libqtcore4 libqtgui4 libstdc++6
B) Method - DEB package from source code, automatic bash script provided below:

Save the script to your computer as a .sh file (zdl.sh for example) and execute it in terminal by typing bash zdl.sh:

Code: Select all

#!/bin/bash

PKGVERSION=3.2.2.3
SOURCEDIR=zdl-$PKGVERSION

sudo apt-get install qt4-dev-tools make gdb git autotools-dev imagemagick dh-make
git clone -b v$PKGVERSION git://github.com/qbasicer/qzdl.git $SOURCEDIR
cd $SOURCEDIR
./configure --prefix=/usr --disable-updater
make

convert "res/ico_icon.ico[2]" ./zdl.png

printf "[Desktop Entry]\nEncoding=UTF-8\nName=ZDL Doom Launcher\nGenericName=Doom launcher\nComment=A feature rich Doom launcher for ZDoom and GZDoom\nExec=zdl\nIcon=zdl\nTerminal=false\nType=Application\nCategories=Game;\nStartupNotify=true\n" > zdl.desktop

mkdir -p ./$SOURCEDIR/usr/bin
mkdir -p ./$SOURCEDIR/usr/share/applications
mkdir -p ./$SOURCEDIR/usr/share/pixmaps

mv zdl ./$SOURCEDIR/usr/bin/
mv zdl.png ./$SOURCEDIR/usr/share/pixmaps/
mv zdl.desktop ./$SOURCEDIR/usr/share/applications/

cd ./$SOURCEDIR

dh_make -s -y --createorig

mkdir -p ./debian/zdl/
cp -R ./usr ./debian/zdl/usr/
printf "usr/* usr/" > ./debian/zdl.install

dpkg-buildpackage -us -uc -nc -b

cd ..
mv *.deb ../
After the script execution there should be zdl-someversion.deb file compiled for you in the script folder.

Post-installation configuration

<note>these instructions are for Ubuntu/Mint/Arch users only. Skip if you use Windows.</note>

After you have installed GZDoom and ZDL, you should have two new desktop shortcuts in your application menu (under "Games"). Physically they're located at /usr/share/applications folder in your system.

GZDoom stores your settings in $HOME/.config/gzdoom/zdoom.ini. It's recommended that you use the same folder to store your WAD files, too. To run GZDoom individually without ZDL, it requires at least one WAD file being stored in the beforementioned folder.

Running the game

<note>these instructions are for Ubuntu/Mint(/Arch) users only. Skip if you use Windows.</note>
  • 1) Copy gzdoom.pk3, brightmaps.pk3 & lights.pk3 from this Windows ZIP into /usr/share/games/gzdoom/ and replace the old ones. Requires root priviledges.

    2) Start ZDL and set up the settings. Source Port for GZDoom executable is located at /usr/bin/gzdoom. Set up your iWAD files and multiplayer settings (external files, internet port, game mode etc.). iWAD files are the main WAD files you want to play. External files are mod files, run within the main WAD you've selected.

    3) If you set up a server in ZDL, share your WAN/LAN IP with your client-side friends. If you're a client and your friend hosts the multiplayer server, get your friend's WAN/LAN IP and paste it to IP field in ZDL. Configure Multi Settings for a specific port address etc.

    4) Start multiplayer. Have fun!
Using ZDoom instead of GZDoom

Version 2.7.1 is recommended.

Windows

Download Windows binary (2.7.1) from here

Linux

Changes to GZDoom installation instructions:
  • - zdoom.pk3 instead of gzdoom.pk3 (Replace the linux version of this file with Windows version. zdoom.pk3 is installed to /usr/share/games/zdoom/ folder so you need root priviledges to replace the file)
    - No brightmaps.pk3 or lights.pk3
    - Default user settings directory is located at $HOME/.config/zdoom. This is the place where you should put your WAD files.
    - Executable (Source Port) for zdoom is /usr/bin/zdoom file
Arch Linux

Get zdoom 2.7.1 from AUR (or use pacaur -S zdoom OR yaourt zdoom).

Ubuntu & Linux Mint

A) Method - Precompiled package (easy for beginners):

Ubuntu 13.10 (and Linux Mint 16)

ZDoom 2.7.1 (64-bit) - .deb file
ZDoom 2.7.1 (32-bit) - .deb file

Prerequisites:

Code: Select all

sudo apt-get install libbz2-1.0 libc6 libfluidsynth1 fluidsynth libgcc1 libglib2.0-0 libgtk2.0-0 libjpeg8 libsdl1.2debian libstdc++6 zlib1g
Ubuntu 14.04 & 14.10 (and Linux Mint 17 & 17.1)

ZDoom 2.7.1 (64-bit) - .deb file
ZDoom 2.7.1 (32-bit) - .deb file

Prerequisites:

Code: Select all

sudo apt-get install libbz2-1.0 libc6 libfluidsynth1 fluidsynth libgcc1 libglib2.0-0 libgtk2.0-0 libjpeg8 libsdl1.2debian libstdc++6 zlib1g
B) Method - compile ZDoom by using an automated script:

Save the following script to your computer as zdoom.sh and execute it by typing bash zdoom.sh in terminal. Root/Sudo password is required only for installation of necessary development packages to compile ZDoom successfully (apt-get). All other script actions are run as normal user.

After the script has been executed, a compiled & fresh zdoom debian package should be in your zdoom.sh script directory. Install runtime dependencies/prerequisites (above) and then the .deb package itself.

The script is based on the GZDoom compilation script shown earlier. It has just some minor modifications for ZDoom adaptation. Please feel free to modify it for your needs.

Code: Select all

#!/bin/bash

PKGVERSION=2.7.1
SOURCEDIR=zdoom-$PKGVERSION
_sharedir=/usr/share/games/zdoom

sudo apt-get install git cmake imagemagick dh-make build-essential zlib1g-dev libsdl1.2-dev libsdl2-dev libjpeg-dev nasm tar libbz2-dev libgtk2.0-dev cmake git libfluidsynth-dev fluidsynth libgme-dev libgl1-mesa-dev libglew-dev

git clone -b $PKGVERSION git://github.com/rheit/zdoom.git zdoom-$PKGVERSION
cd $SOURCEDIR

if [ "$(uname -m)" = "x86_64" ]; then 
FMODFOLDER="fmodapi42636linux64" 
else
FMODFOLDER="fmodapi42636linux"
fi && \
wget -nc http://www.fmod.org/download/fmodex/api/Linux/$FMODFOLDER.tar.gz && \
tar -xvzf $FMODFOLDER.tar.gz -C ./

if [ "$(uname -m)" = "x86_64" ]; then
FMODFOLDER="fmodapi42636linux64"
FMODFILE="libfmodex64-4.26.36"
else
FMODFOLDER="fmodapi42636linux"
FMODFILE="libfmodex-4.26.36"
fi && \
cmake -DCMAKE_BUILD_TYPE=Release \
-DFMOD_LIBRARY=./$FMODFOLDER/api/lib/$FMODFILE.so \
-DFMOD_INCLUDE_DIR=./$FMODFOLDER/api/inc \
-DCMAKE_C_FLAGS="$CFLAGS -DSHARE_DIR=\\\"$_sharedir\\\"" \
-DCMAKE_CXX_FLAGS="$CXXFLAGS -DSHARE_DIR=\\\"$_sharedir\\\"" && \

make

convert "src/win32/icon1.ico[2]" zdoom.png

printf "[Desktop Entry]\nEncoding=UTF-8\nVersion=1.0\nType=Application\nName=ZDoom\nGenericName=Doom Engine\nIcon=zdoom\nExec=zdoom %F\nTerminal=false\nCategories=Game;ActionGame;\nStartupNotify=true\n" > zdoom.desktop

mkdir -p ./$SOURCEDIR/usr/bin
mkdir -p ./$SOURCEDIR/usr/lib/zdoom
mkdir -p ./$SOURCEDIR/usr/share/applications
mkdir -p ./$SOURCEDIR/usr/share/games/zdoom
mkdir -p ./$SOURCEDIR/usr/share/licenses/zdoom
mkdir -p ./$SOURCEDIR/usr/share/pixmaps
mkdir -p ./$SOURCEDIR/usr/share/licenses/zdoom

mv zdoom ./$SOURCEDIR/usr/bin/
mv ./output_sdl/liboutput_sdl.so ./$SOURCEDIR/usr/lib/zdoom/
mv zdoom.pk3 ./$SOURCEDIR/usr/share/games/zdoom/
mv zdoom.png ./$SOURCEDIR/usr/share/pixmaps/
mv zdoom.desktop ./$SOURCEDIR/usr/share/applications/
mv ./docs/BUILDLIC.TXT ./$SOURCEDIR/usr/share/licenses/zdoom/
mv ./docs/doomlic.txt ./$SOURCEDIR/usr/share/licenses/zdoom/
cp ./$FMODFOLDER/api/lib/$FMODFILE.so ./$SOURCEDIR/usr/lib/

cd ./$SOURCEDIR/

dh_make -s -y --createorig
mkdir -p ./debian/zdoom/
cp -R ./usr ./debian/zdoom/usr/
printf "usr/* usr/" > ./debian/zdoom.install

dpkg-buildpackage -us -uc -b
cd ..
mv *.deb ../
User settings directory of Zdoom is located at $HOME/.config/zdoom/ on Linux.

Troubleshooting (Linux)

General
  • Issue: I try install these deb packages via command line with command sudo dpkg -i somepackage.deb. However, I get complains about missing packages or dependencies on my system.
    Solution: Install all packages listed under Prerequisites titles before installing individually downloaded deb packages. If you missed that, you can always try to get things right with command sudo apt-get install -f which attempts to correct dependency-related installation errors. If a not-listed package is missing, install it with command sudo apt-get update && sudo apt-get install <missingpackages> (use correct package names here).
GZDoom/ZDoom
  • Issue: I can't start GZDoom/ZDoom because of missing wads. (or "GZDoom/ZDoom doesn't launch").
    Solution: Make sure you have .config/gzdoom/ (or ./config/zdoom if using ZDoom) in your home directory. You must also place at least one valid WAD file there (doom2.wad for example). After having done that, run gzdoom again.

    Issue: Audio is not working
    Solution: To get audio working, try different midi devices (Options -> Sound Options). For me, OPL SYNTH EMULATION works perfectly with both music & other sounds. However, GZDoom sounds may not work if you have some another program opened using audio (Flash in Firefox, VirtualBox etc.).

    Issue: Crackling sounds
    Solution: GZDoom sounds may not work if you have some another program opened using audio (Flash in Firefox, VirtualBox etc.). I got crackling sounds in GZDoom while VirtualBox session was running on the background.
EDIT: Hamachi & Haguichi related requirements/stuff removed.
EDIT 2: ZDoom part added. Text trimmed little bit.
Last edited by Fincer on Mon Feb 09, 2015 18:54, edited 3 times in total.

User avatar
Edward850
Posts: 63
Joined: Fri Mar 20, 2009 21:48

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Edward850 » Mon Feb 09, 2015 3:53

Any tutorial that suggests Hamachi as the required networking method is automatically ill equipped and misinformed as a tutorial. Plus most of it seems redundant.

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Fincer » Mon Feb 09, 2015 4:19

I know there are some open source multiplayer daemons around, but I've not tested them all so far. You can always suggest a better method for GZDoom multiplayer gaming. A method which works both for Windows & Linux (natively) & between the two. I've found none so far specifically for GZDoom (not searched much, though). Hamachi, no matter how rude solution it is, works perfectly for GZDoom multiplayer/online purposes between Linux & Windows with all mods enabled and with simple ZDL interface. At least for now - until someone will develop a native online gaming support for ZDL (or make another easy-to-use native online doom daemon) with full mods + Linux support.

What comes to your sentence "misinformed as a tutorial", I don't follow you. I've not specified what kind of tutorial this is or what methods are used to achieve the goal - which is multiplayer gaming for GZDoom as already told in the title. By following my instructions, the goal successfully achieved.

If you disagree with hamachi-based solution, it doesn't mean that someone else might do. This is only a single solution, I'm sure there may be other available, too. Sorry, but in my point of view, I don't quite understand your complaint. Hamachi or not, it's still a tutorial.
Last edited by Fincer on Mon Feb 09, 2015 4:24, edited 1 time in total.

User avatar
Edward850
Posts: 63
Joined: Fri Mar 20, 2009 21:48

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Edward850 » Mon Feb 09, 2015 4:22

Your default method should always be native first (i.e direct). Not virtual. Especially not with a restricted pay-for service with transparent overheads that the end user may not comprehend (Hamachi will arbitrarily decide to use a routing point rather than a direct connection, and UDP-over-TCP, which is ultra bad for G/ZDoom). You really don't want any sort of unnecessary overheads, and Hamachi is nothing but, and thus should never be considered a primary method.

Plus it doesn't even make any sense. ZDoom's player limit at the moment is 8. Hamachi's connection limit without paying money is 5. You can't even get a full game going on with that.

Native direct connections will always run faster, and it's much better to teach the end user what's going on, rather than assuming they are idiots. Hence the point of the tutorial I linked.
Last edited by Edward850 on Mon Feb 09, 2015 4:41, edited 1 time in total.

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Fincer » Mon Feb 09, 2015 4:41

Your default method should always be native first (i.e direct). Not virtual.
Sure. I understand your point. However, ZDL doesn't provide any direct methods for online gaming (only for LAN). You feel that hamachi is like a hacked, dirty solution. Yes, you can say that. However, you can also suggest better (and tested) methods to achieve multiplayer gaming support for GZDoom Windows + Linux (native) + mods enabled like my tutorial does. This tutorial gives only one approach to the subject. I'm sorry if you feel it's not the right one. In your point of view, it may not be.
Hamachi will arbitrarily decide to use a routing point rather than a direct connection, and UDP-over-TCP, which is ultra bad for G/ZDoom). Native direct connections will always run faster...
Theoretically, I understand this point, too. I don't specifically know about GZDoom but I've had no issues in other games with Hamachi used for online gaming purposes. Even for hours, and neither desync or lag issues have ever occured at all.
Plus it doesn't even make any sense. ZDoom's player limit at the moment is 8. Hamachi's connection limit without paying money is 5. You can't even get a full game going on with that.
Okay well. Some new information here. Looks like ZDoom approach is more elegant than mine. Let me ask a stupid question now: Does ZDL support online gaming? If the answer is yes, I may be misinformed by a friend of mine then... *feels frustated* :oops:
Last edited by Fincer on Mon Feb 09, 2015 4:51, edited 1 time in total.

User avatar
Edward850
Posts: 63
Joined: Fri Mar 20, 2009 21:48

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Edward850 » Mon Feb 09, 2015 4:45

Fincer wrote:Sure. I understand your point. However, ZDL doesn't provide any direct methods for online gaming (only for LAN). You feel that hamachi is like a hacked, dirty solution. Yes, you can say that. However, you can also suggest better (and tested) methods to achieve multiplayer gaming support for GZDoom Windows + Linux (native) + mods enabled like my tutorial does. This tutorial gives only one approach to the subject. I'm sorry if you feel it's not the right one. In your point of view, it may not be.
It's called using the WAN address. ZDL is most certainly not restricted to a LAN (and infact, does not care as it doesn't create connections in the first place), and neither is the command prompt/terminal.

It sounds like the only reason why you're suggesting to use Hamachi is because you don't seem to fully comprehend the different between 192.168.1.53 and 111.68.72.53 as absolutly no difference at all, as far as ZDL or ZDoom or anything is concerned. Hence why it's a bad idea for you to write up a tutorial. If you don't understand what's going on, why are you trying to tell other people how it works?
Fincer wrote:Theoretically, I understand this point, too.
You keep using that word...

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Fincer » Mon Feb 09, 2015 4:56

It's called using the WAN address. ZDL is most certainly not restricted to a LAN (and infact, does not care as it doesn't create connections in the first place), and neither is the command prompt/terminal.
Right, that explains *all*. Thanks for the info. I must admit I'm badly and *completely* misinformed here (should never trust vague info). All my mistake. I take the tutorial off and edit it until all hamachi-related stuff is removed.
You keep using that word...
That was the first time I actually used it. :)

User avatar
Edward850
Posts: 63
Joined: Fri Mar 20, 2009 21:48

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Edward850 » Mon Feb 09, 2015 5:11

Fincer wrote:Okay well. Some new information here. Looks like ZDoom approach is more elegant than mine. Let me ask a stupid question now: Does ZDL support online gaming? If the answer is yes, I may be misinformed by a friend of mine then... *feels frustated* :oops:
ZDL doesn't actually care, and is simply a "dumb launcher". It never checks nor validates files, connections, or anything of the like. It just simply launches ZDoom with command line parameters.

To the extent that you don't actually need ZDL in the slightest. Everything ZDL does is simply a GUI frontend for this:
Image
Image
It otherwise provides no extra facilities.

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Fincer » Mon Feb 09, 2015 12:39

Allright. Thanks again about the strict statement you made about hamachi/haguichi. I edited the tutorial as *practically* requested. Any better now?

Though ZDL would not be needed for multiplayer, I still keep its installation part there because using a GUI front-end is often perceived as more user-friendly way to set up a multiplayer game session.

User avatar
Edward850
Posts: 63
Joined: Fri Mar 20, 2009 21:48

Re: Tutorial: GZDoom multiplayer between Windows & Linux

Post by Edward850 » Mon Feb 09, 2015 14:18

Fincer wrote:Though ZDL would not be needed for multiplayer, I still keep its installation part there because using a GUI front-end is often perceived as more user-friendly way to set up a multiplayer game session.
Never said you shouldn't use. What I said was it doesn't do anything extra, and does not own any of ZDoom's multiplayer functions. Your friend is technically right in that ZDL doesn't have online gaming, however that's because it has no networking function to start with. That's all ZDoom's job.
Fincer wrote:Allright. Thanks again about the strict statement you made about hamachi/haguichi. I edited the tutorial as *practically* requested. Any better now?
Well, you see, now there's the problem of redundancy. :P
It seems like what should be happening is you should explain what isn't very clear to you from the current guide (above) or the wiki (here, specifically). That way, everything that needs to be explained is explained, and nobody runs the risk of confusing from potentially out of date or conflicting information.

Fincer
Posts: 12
Joined: Mon Feb 02, 2015 14:11

Re: Tutorial: (G)ZDoom multiplayer between Windows & Linux

Post by Fincer » Fri Feb 27, 2015 23:42

As what I can tell by experience, we have found multiplayer between Windows and Linux a bit unstable, especially if played over the internet with hamachi. You are likely to get "out of sync" situation. I've investigated this with a friend of mine. To do some further comparison, I installed GZDoom Windows version to Wine and all "out of sync" issues were gone - instantly - even when hamachi were used.

I've read that you must have exactly the same version of Zdoom if you want to play it in multiplayer. So, it's possible that you may be just able to set up a multiplayer game using only Windows or only Linux clients, without mixing them. If this is true, the tutorial I've written is completely misleading.

I'm not sure but I think this can likely be an issue of possible little differences between GZDoom Windows & Linux application codes. This can also be an issue of lag events that we faced with hamachi and that taking little differences between Windows & Linux clients into account it leads easily to "out of sync" situation. It is possible that "out of sync" situations would be gone if straight internet connection were used and thus no lag would exist. Unfortunately, we were unable to establish the straight connection, regardless of many attempts so we were not able to investigate this any further.

More about multiplayer with ZDoom/GZDoom:
Btw. There are GZDoom 1.8.10 and 2.0.05 source codes available on Github. You can make a deb package of those using compilation scripts provided above. Just change PKGVERSION field to
  • PKGVERSION=1.8.10 or
  • PKGVERSION=2.0.05
and compile. You don't need to download source from Github. Just change PKGVERSION and you're good to go.

Just to say: I've had none of abovementioned issues with Zandronum/Doomseeker which have a good multiplayer support even between Windows and Linux clients by default. Because I'm 100% happy with this software, I have no personal interests to investigate multiplayer possiblities with Zdoom/GZDoom anymore. If anyone is still interested to do that, just please go ahead.

Locked

Return to “GZDoom”