Fallout 1 has arrived

This commit is contained in:
grepwood 2020-04-18 20:01:31 +02:00
parent 68da7f9f5b
commit 3c1bcc8b9e
6 changed files with 235 additions and 0 deletions

View File

@ -0,0 +1,3 @@
DIST HMIDET.386 81990 BLAKE2B e3dde0b948f11ec8e61417fd9d5c9d93d20626e003fa5daf5c2d94f8e14cb7982729cc8220ef68fb3a7661086c82e43173bd311808732ba37b0407fd53e681bf SHA512 f6a1d01edda1934258cce7172beac3d8257a6e8d29f235c59e5bba9f39832622d28a9222c4d629f7145930417e39338f6b08a7281053c565dc6831bae97d6a34
DIST HMIDRV.386 261425 BLAKE2B 1b3229f2af8bc9b618ce4bee4434472bd2728d5cb3921dce3079c687e9ac6fb55fc1202a17721aac23baacff445238ac2233bd7414260511935b7aa37d1452c6 SHA512 3c47694269ce72b9aac3a30241aca002aaee39d47a1d10d4d196ec4f16d0f64d7e01ef3f3cc0a637c69fcb4e9a42629ba2e8b1c02af08e95d82c52af2faa4b18
DIST fallup1d.zip 659033 BLAKE2B 68d3731e763c7f614d8ab2a63fc8677c975fbdc131a0fb9e7c10dcf1ad3f723749199a72917e320d66b4a729411e10c2a323f7910fc7032f0ae53eb95e663c8e SHA512 44b328c72226de562ae69fdf0dd4893dc4c17af801060e70c2e1ab9142018af8edf645b1a21c72b22dbc636885f43ce82bd76613fadb73412dc0ba4fafdcb35c

View File

@ -0,0 +1,75 @@
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit gog
DESCRIPTION="Post-apocalyptic role-playing game."
HOMEPAGE=""
LICENSE+=" FALLOUT1_EULA"
SLOT="0"
KEYWORDS="~amd64 ~x86 ~ppc64 ~arm"
SRC_URI="
dos? ( https://archive.org/download/fallout1_dos/fallup1d.zip
https://archive.org/download/fallout1_dos/HMIDET.386
https://archive.org/download/fallout1_dos/HMIDRV.386 )
"
IUSE="-dos -wine"
GOG_GAME_NAME="fallout_classic"
GOG_GAME_L10N="en"
GOG_GAME_PLATFORM="w"
GOG_GAME_INSTALLER="setup_fallout_2.1.0.18.exe"
BDEPEND="${BDEPEND}
media-gfx/icoutils
media-gfx/imagemagick
dos? ( app-arch/unzip )
"
RDEPEND="
dos? ( games-emulation/dosbox
app-emulation/dos32a )
wine? ( app-emulation/wine-vanilla[abi_x86_32] )
"
DEPEND="${RDEPEND}"
S=${WORKDIR}
src_unpack() {
gog_initialize
FALLOUT_EXE="fallout1_wine"
gog_download_installer
innoextract -I app -e ${GOG_GAME_NAME}/${GOG_GAME_INSTALLER}
wrestool -x -t14 -o . app/falloutw.exe
convert falloutw.exe_14_99_0.ico fallout1.png
mv fallout1-4.png fallout1.png
if use dos; then
cp ${DISTDIR}/HMID*.386 app
unzip ${DISTDIR}/fallup1d.zip FALL11.ZIP
unzip FALL11.ZIP FALLOUT.EXE
mv FALLOUT.EXE app
ln -s /usr/share/dos32a/dos32a.exe app/dos4gw.exe
cp ${FILESDIR}/dosbox.conf app
FALLOUT_EXE="fallout1_dos"
fi
mv app fallout1
cp ${FILESDIR}/${FALLOUT_EXE} fallout1_exe
}
src_install() {
insinto /usr/share/games
doins -r fallout1
rm -rf fallout1
mv fallout1_exe fallout1
insinto /usr/share/pixmaps
doins fallout1.png
insinto /usr/share/applications
doins "${FILESDIR}/fallout1.desktop"
dobin fallout1
}

View File

@ -0,0 +1,95 @@
[sdl]
fullscreen=true
fulldouble=false
fullresolution=original
windowresolution=original
output=surface
autolock=true
sensitivity=100
waitonerror=true
priority=higher,normal
mapperfile=mapper-0.74-3.map
usescancodes=true
[dosbox]
language=
machine=svga_s3
captures=capture
memsize=16
[render]
frameskip=0
aspect=false
scaler=normal2x
[cpu]
core=auto
cputype=auto
cycles=max
cycleup=10
cycledown=20
[mixer]
nosound=false
rate=22050
blocksize=8192
prebuffer=10
[midi]
mpu401=none
mididevice=none
midiconfig=
[sblaster]
sbtype=sb1
sbbase=220
irq=7
dma=1
hdma=5
sbmixer=false
oplmode=none
oplemu=fast
oplrate=22050
[gus]
gus=false
gusrate=22050
gusbase=240
gusirq=5
gusdma=3
ultradir=C:\ULTRASND
[speaker]
pcspeaker=none
pcrate=22050
tandy=off
tandyrate=22050
disney=false
[joystick]
joysticktype=none
timed=true
autofire=false
swap34=false
buttonwrap=false
[serial]
serial1=disabled
serial2=disabled
serial3=disabled
serial4=disabled
[dos]
xms=true
ems=true
umb=true
keyboardlayout=auto
[ipx]
ipx=false
[autoexec]
mount D ~/.local/share/Fallout1
D:
FALLOUT.EXE
EXIT

View File

@ -0,0 +1,8 @@
[Desktop Entry]
Version=1.0
Type=Application
Name=Fallout
Comment=Post-apocalyptic role-playing game.
Exec=fallout1
Icon=fallout1
Categories=Game;RolePlaying;

View File

@ -0,0 +1,28 @@
#!/usr/bin/env bash
set -xeuo pipefail
if [ ! -d ~/.local/share/Fallout1 ]; then
mkdir -p ~/.local/share/Fallout1
pushd ~/.local/share/Fallout1
for i in $(ls /usr/share/games/fallout1 | grep -vE '^fallout\.cfg$|^DATA$|^dosbox\.conf$'); do
ln -s /usr/share/games/fallout1/$i $i
done
cp /usr/share/games/fallout1/dosbox.conf .
sed 's/^art_cache_size=.*$/art_cache_size=5/;s/^device=.*$/device=57344/;s/^dma=.*$/dma=1/;s/^irq=.*$/irq=7/;s/^port=.*$/port=544/' /usr/share/games/fallout1/fallout.cfg > fallout.cfg
mkdir DATA
pushd DATA
for i in $(ls /usr/share/games/fallout1/DATA | grep -vE '^SAVEGAME$|^MAPS$'); do
ln -s /usr/share/games/fallout1/DATA/$i $i
done
mkdir SAVEGAME
mkdir MAPS
pushd MAPS
for i in $(ls /usr/share/games/fallout1/DATA/MAPS); do
ln -s /usr/share/games/fallout1/DATA/MAPS/$i $i
done
popd
popd
popd
fi
dosbox -conf ~/.local/share/Fallout1/dosbox.conf

View File

@ -0,0 +1,26 @@
#!/usr/bin/env bash
set -xeuo pipefail
WINEPREFIX=~/.wine_fallout1
WINEARCH=win32
if [ ! -d ~/.local/share/Fallout1 ]; then
mkdir -p ~/.local/share/Fallout1
pushd ~/.local/share/Fallout1
for i in $(ls /usr/share/games/fallout1 | grep -vE '^fallout\.cfg$|^DATA$'); do
ln -s /usr/share/games/fallout1/$i $i
done
cp /usr/share/games/fallout1/fallout.cfg .
mkdir DATA
pushd DATA
for i in $(ls /usr/share/games/fallout1/DATA | grep -v ^SAVEGAME$); do
ln -s /usr/share/games/fallout1/DATA/$i $i
done
mkdir SAVEGAME
popd
popd
fi
pushd ~/.local/share/Fallout1
wine falloutw.exe
popd