@skew said in Quiet Quiet Rooms?:
Thank you, @Chime!
Anytime!
Hate to do this, but can anyone break down how to apply this patch in very, very simple terms? I can get into the console as necessary, I know what git is, I just have no idea how to apply a patch to a game. Or, well, most anything else linux-related.
Sorry for being a bit terse. I spend most of my waking hours at some sort of unix prompt (Linux or otherwise). First, you'll need several tools. If you don't have administrator (root) access, then hopefully your host has already got these installed. On deb-derived systems (Debian, Ubuntu, Mint, etc etc) you'll want something like
$ sudo apt-get update
... some lines downloading package lists ...
$ sudo apt-get install build-essential g++ make patch tar bzip2 wget git
... some lines describing additional packages it wants to install ...
... question about if that's okay (say yes, generally) ...
... many lines about downloading and installing each package ...
If the tools are already there, then you won't need to do that.
$ cd
$ mkdir mux-src
$ cd mux-src
$ wget ftp://ftp.tinymux.org/tinymux-2.12/alpha/3/mux-2.12.0.3.unix.tar.bz2
--2017-05-09 23:35:06-- ftp://ftp.tinymux.org/tinymux-2.12/alpha/3/mux-2.12.0.3.unix.tar.bz2
=> ‘mux-2.12.0.3.unix.tar.bz2’
Resolving ftp.tinymux.org (ftp.tinymux.org)... 52.34.23.255, 2600:1f14:2a0:2201:ab7d:7d:8dd3:57fc
Connecting to ftp.tinymux.org (ftp.tinymux.org)|52.34.23.255|:21... connected.
Logging in as anonymous ... Logged in!
==> SYST ... done. ==> PWD ... done.
==> TYPE I ... done. ==> CWD (1) /tinymux-2.12/alpha/3 ... done.
==> SIZE mux-2.12.0.3.unix.tar.bz2 ... 1080619
==> PASV ... done. ==> RETR mux-2.12.0.3.unix.tar.bz2 ... done.
Length: 1080619 (1.0M) (unauthoritative)
mux-2.12.0.3.unix.tar.bz2 100%[===============================================================================>] 1.03M --.-KB/s in 0.09s
2017-05-09 23:35:06 (11.6 MB/s) - ‘mux-2.12.0.3.unix.tar.bz2’ saved [1080619]
$ tar xjvf mux-2.12.0.3.unix.tar.bz2
mux2.12/
mux2.12/INSTALL
mux2.12/SGP
mux2.12/CHANGES
mux2.12/LOCAL
mux2.12/REALITY.SETUP
mux2.12/NOTES
mux2.12/src/
mux2.12/src/move.cpp
mux2.12/src/Doxyfile
mux2.12/src/autoconf.h.in
mux2.12/src/muxcli.h
... many more files unpacking ...
$ git clone https://github.com/lashtear/tinymux.git
Cloning into 'tinymux'...
remote: Counting objects: 59424, done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 59424 (delta 0), reused 0 (delta 0), pack-reused 59422
Receiving objects: 100% (59424/59424), 18.34 MiB | 17.20 MiB/s, done.
Resolving deltas: 100% (46787/46787), done.
Now, you should be in a folder called 'mux-src' right underneath your homedir, with the tar.bz2 archive of upstream tinymux from Brazil and a git checkout of my quirky version.
$ ls -laF
total 1080
drwxr-xr-x 4 lucca lucca 4096 May 10 00:01 ./
drwxr-xr-x 104 lucca lucca 12288 May 9 23:56 ../
drwxr-x--- 5 lucca lucca 4096 Feb 13 2016 mux2.12/
-rw-r--r-- 1 lucca lucca 1080619 May 9 23:35 mux-2.12.0.3.unix.tar.bz2
drwxr-xr-x 11 lucca lucca 4096 May 9 23:58 tinymux/
$ cd tinymux
$ git show 5fd6080286dc36fe7ba6673a208dbfb445a6d056 > ../blind-room.patch
$ cd ..
$ ls -laF
total 1088
drwxr-xr-x 4 lucca lucca 4096 May 10 00:03 ./
drwxr-xr-x 104 lucca lucca 12288 May 9 23:56 ../
-rw-r--r-- 1 lucca lucca 4606 May 10 00:03 blind-room.patch
drwxr-x--- 5 lucca lucca 4096 Feb 13 2016 mux2.12/
-rw-r--r-- 1 lucca lucca 1080619 May 9 23:35 mux-2.12.0.3.unix.tar.bz2
drwxr-xr-x 16 lucca lucca 4096 May 10 00:03 tinymux/
Now we have that same bit plus that blind-room.patch file. Now before you start suggesting that it'd be really handy if we kept all those patches somewhere easy to access-- that's exactly what any revision control software (like git) does. Anyway, time to apply.
$ cd mux2.12
$ patch -p2 <../blind-room.patch
patching file game/text/help.txt
patching file src/move.cpp
patching file src/netcommon.cpp
Congrats. You now have a tinymux tree from Brazil but with just that one patch of mine added. If you were instead building from his git repo, you could do this all much easier with the git cherry-pick command, but you probably aren't. If building against an archive export of his git tree, change the parameter to -p1 because of the slightly different directory structure.
This should work for most any 2.12 or 2.10 version, though if you use 2.10 the file offsets are slightly different, so you would see instead:
$ cd mux2.10
$ patch -p2 <../blind-room.patch
patching file game/text/help.txt
Hunk #1 succeeded at 5009 (offset -12 lines).
patching file src/move.cpp
patching file src/netcommon.cpp
Yes; git, patch, diff, etc are all rather clever and indispensable tools that I can't imagine getting through my day without. Game should build as normal with these changes.