mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-18 22:06:04 +01:00
games/supermariowar: Added (Super Mario multiplayer game).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
parent
43f99ca5f1
commit
ad7c9ab70a
12 changed files with 235 additions and 0 deletions
14
games/supermariowar/README
Normal file
14
games/supermariowar/README
Normal file
|
@ -0,0 +1,14 @@
|
|||
supermariowar (Super Mario multiplayer game)
|
||||
|
||||
Super Mario War is a fan-made multiplayer Super Mario Bros. style
|
||||
deathmatch game in which players try to beat one another in a variety of
|
||||
gameplay modes. You can play on teams, design your own levels, design your
|
||||
own worlds, and much more! The goal is to stomp as many other Marios as
|
||||
possible to win the game. It's a tribute to Nintendo and the game Mario
|
||||
War by Samuele Poletto.
|
||||
|
||||
Notes:
|
||||
|
||||
- The game executable is called "smw".
|
||||
- Single player games against bots are supported.
|
||||
- Only 640x480 windowed and fullscreen video modes are supported.
|
67
games/supermariowar/compilefixes.diff
Normal file
67
games/supermariowar/compilefixes.diff
Normal file
|
@ -0,0 +1,67 @@
|
|||
diff -Naur supermariowar-r16/Makefile supermariowar-r16.patched/Makefile
|
||||
--- supermariowar-r16/Makefile 2014-04-08 14:07:20.000000000 -0400
|
||||
+++ supermariowar-r16.patched/Makefile 2014-04-08 14:09:00.000000000 -0400
|
||||
@@ -8,9 +8,9 @@
|
||||
build/savepng.o build/sfx.o
|
||||
SMW_OBJS:= build/HashTable.o build/ai.o build/gamemodes.o build/main.o \
|
||||
build/map.o build/menu.o build/object.o build/player.o \
|
||||
- build/splash.o build/uicontrol.o build/uimenu.o build/world.o
|
||||
+ build/splash.o build/uicontrol.o build/uimenu.o build/world.o build/objecthazard.o build/objectgame.o build/modeoptionsmenu.o build/uicustomcontrol.o
|
||||
LEVELEDIT_OBJS:=build/leveleditor.o
|
||||
-WORLDEDIT_OBJS:=build/sfx.o build/world.o build/worldeditor.o
|
||||
+WORLDEDIT_OBJS:=build/dirlist.o build/eyecandy.o build/FileIO.o build/FileList.o build/global.o build/input.o build/map.o build/MapList.o build/modeoptionsmenu.o build/movingplatform.o build/object.o build/objecthazard.o build/path.o build/savepng.o build/TilesetManager.o build/uicontrol.o build/uimenu.o build/world.o build/worldeditor.o build/gfx.o build/SFont.o build/sfx.o build/linfunc.o
|
||||
|
||||
include configuration
|
||||
#here because of one .c file among a .cpp project (o_O)
|
||||
@@ -24,7 +24,7 @@
|
||||
leveledit : $(COMMON_OBJS) $(LEVELEDIT_OBJS)
|
||||
$(CXX) $(CFLAGS) $^ $(LDFLAGS) -o $@
|
||||
|
||||
-worldedit : $(COMMON_OBJS) $(WORLDEDIT_OBJS)
|
||||
+worldedit : $(WORLDEDIT_OBJS)
|
||||
$(CXX) $(CFLAGS) $^ $(LDFLAGS) -o $@
|
||||
|
||||
build/SFont.o : _src/SFont.c
|
||||
diff -Naur supermariowar-r16/_src/FileList.cpp supermariowar-r16.patched/_src/FileList.cpp
|
||||
--- supermariowar-r16/_src/FileList.cpp 2010-01-06 14:33:55.000000000 -0500
|
||||
+++ supermariowar-r16.patched/_src/FileList.cpp 2014-03-27 15:06:03.000000000 -0400
|
||||
@@ -16,6 +16,7 @@
|
||||
#include "dirlist.h"
|
||||
#include <ctype.h>
|
||||
#include <iostream>
|
||||
+#include <algorithm>
|
||||
using std::cout;
|
||||
using std::endl;
|
||||
using std::string;
|
||||
diff -Naur supermariowar-r16/_src/ai.cpp supermariowar-r16.patched/_src/ai.cpp
|
||||
--- supermariowar-r16/_src/ai.cpp 2010-01-06 14:33:55.000000000 -0500
|
||||
+++ supermariowar-r16.patched/_src/ai.cpp 2014-03-27 15:43:02.000000000 -0400
|
||||
@@ -345,7 +345,8 @@
|
||||
{
|
||||
delete itr->second;
|
||||
|
||||
- itr = attentionObjects.erase(itr);
|
||||
+ attentionObjects.erase(itr);
|
||||
+ itr = attentionObjects.begin();
|
||||
lim = attentionObjects.end();
|
||||
}
|
||||
}
|
||||
diff -Naur supermariowar-r16/_src/path.cpp supermariowar-r16.patched/_src/path.cpp
|
||||
--- supermariowar-r16/_src/path.cpp 2010-01-06 14:33:55.000000000 -0500
|
||||
+++ supermariowar-r16.patched/_src/path.cpp 2014-03-27 15:07:56.000000000 -0400
|
||||
@@ -1,3 +1,4 @@
|
||||
+#include <string.h>
|
||||
#include <string>
|
||||
#include <iostream>
|
||||
#include <sys/stat.h>
|
||||
diff -Naur supermariowar-r16/_src/uicontrol.cpp supermariowar-r16.patched/_src/uicontrol.cpp
|
||||
--- supermariowar-r16/_src/uicontrol.cpp 2010-01-06 14:33:55.000000000 -0500
|
||||
+++ supermariowar-r16.patched/_src/uicontrol.cpp 2014-03-27 15:45:58.000000000 -0400
|
||||
@@ -2,6 +2,7 @@
|
||||
#include <math.h>
|
||||
|
||||
extern void LoadCurrentMapBackground();
|
||||
+extern void LoadMapHazards(bool fPreview);
|
||||
|
||||
UI_Control::UI_Control(short x, short y)
|
||||
{
|
7
games/supermariowar/desktop/smw-leveledit.desktop
Normal file
7
games/supermariowar/desktop/smw-leveledit.desktop
Normal file
|
@ -0,0 +1,7 @@
|
|||
[Desktop Entry]
|
||||
Name=Super Mario War Level Editor
|
||||
Exec=smw-leveleditor
|
||||
Icon=smw-leveleditor
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=Game;ActionGame;
|
7
games/supermariowar/desktop/smw-worldedit.desktop
Normal file
7
games/supermariowar/desktop/smw-worldedit.desktop
Normal file
|
@ -0,0 +1,7 @@
|
|||
[Desktop Entry]
|
||||
Name=Super Mario War World Editor
|
||||
Exec=smw-worldeditor
|
||||
Icon=smw-worldeditor
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=Game;ActionGame;
|
8
games/supermariowar/desktop/smw.desktop
Normal file
8
games/supermariowar/desktop/smw.desktop
Normal file
|
@ -0,0 +1,8 @@
|
|||
[Desktop Entry]
|
||||
Name=Super Mario War
|
||||
Comment=Super Mario multiplayer game
|
||||
Exec=smw
|
||||
Icon=smw
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=Game;ActionGame;
|
3
games/supermariowar/doinst.sh
Normal file
3
games/supermariowar/doinst.sh
Normal file
|
@ -0,0 +1,3 @@
|
|||
if [ -x /usr/bin/update-desktop-database ]; then
|
||||
/usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
|
||||
fi
|
BIN
games/supermariowar/icons/smw-leveledit.png
Normal file
BIN
games/supermariowar/icons/smw-leveledit.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 613 B |
BIN
games/supermariowar/icons/smw-worldedit.png
Normal file
BIN
games/supermariowar/icons/smw-worldedit.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 607 B |
BIN
games/supermariowar/icons/smw.png
Normal file
BIN
games/supermariowar/icons/smw.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 678 B |
19
games/supermariowar/slack-desc
Normal file
19
games/supermariowar/slack-desc
Normal file
|
@ -0,0 +1,19 @@
|
|||
# HOW TO EDIT THIS FILE:
|
||||
# The "handy ruler" below makes it easier to edit a package description.
|
||||
# Line up the first '|' above the ':' following the base package name, and
|
||||
# the '|' on the right side marks the last column you can put a character in.
|
||||
# You must make exactly 11 lines for the formatting to be correct. It's also
|
||||
# customary to leave one space after the ':' except on otherwise blank lines.
|
||||
|
||||
|-----handy-ruler------------------------------------------------------|
|
||||
supermariowar: supermariowar (Super Mario multiplayer game)
|
||||
supermariowar:
|
||||
supermariowar: Super Mario War is a fan-made multiplayer Super Mario Bros. style
|
||||
supermariowar: deathmatch game in which players try to beat one another in a variety
|
||||
supermariowar: of gameplay modes. You can play on teams, design your own levels,
|
||||
supermariowar: design your own worlds, and much more! The goal is to stomp as many
|
||||
supermariowar: other Marios as possible to win the game. It's a tribute to Nintendo
|
||||
supermariowar: and the game Mario War by Samuele Poletto.
|
||||
supermariowar:
|
||||
supermariowar:
|
||||
supermariowar:
|
100
games/supermariowar/supermariowar.SlackBuild
Normal file
100
games/supermariowar/supermariowar.SlackBuild
Normal file
|
@ -0,0 +1,100 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Slackware build script for supermariowar
|
||||
|
||||
# Written by B. Watson (yalhcru@gmail.com)
|
||||
|
||||
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
|
||||
|
||||
PRGNAM=supermariowar
|
||||
VERSION=${VERSION:-r16}
|
||||
BUILD=${BUILD:-1}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
||||
if [ -z "$ARCH" ]; then
|
||||
case "$( uname -m )" in
|
||||
i?86) ARCH=i486 ;;
|
||||
arm*) ARCH=arm ;;
|
||||
*) ARCH=$( uname -m ) ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
CWD=$(pwd)
|
||||
TMP=${TMP:-/tmp/SBo}
|
||||
PKG=$TMP/package-$PRGNAM
|
||||
OUTPUT=${OUTPUT:-/tmp}
|
||||
|
||||
if [ "$ARCH" = "i486" ]; then
|
||||
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
|
||||
LIBDIRSUFFIX=""
|
||||
elif [ "$ARCH" = "i686" ]; then
|
||||
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
|
||||
LIBDIRSUFFIX=""
|
||||
elif [ "$ARCH" = "x86_64" ]; then
|
||||
SLKCFLAGS="-O2 -fPIC"
|
||||
LIBDIRSUFFIX="64"
|
||||
else
|
||||
SLKCFLAGS="-O2"
|
||||
LIBDIRSUFFIX=""
|
||||
fi
|
||||
|
||||
set -e
|
||||
|
||||
rm -rf $PKG
|
||||
mkdir -p $TMP $PKG $OUTPUT
|
||||
cd $TMP
|
||||
rm -rf $PRGNAM-$VERSION
|
||||
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
|
||||
cd $PRGNAM-$VERSION
|
||||
chown -R root:root .
|
||||
find -L . \
|
||||
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
|
||||
-o -perm 511 \) -exec chmod 755 {} \; -o \
|
||||
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
|
||||
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
|
||||
|
||||
# C++ is a fast-moving target, code from 2009, compiler from 2014 or so.
|
||||
# Also, the code got refactored and the VC++ projects updated, but the
|
||||
# Makefile hadn't been (so I had to parse the VC++ project file, ugh).
|
||||
patch -p1 < $CWD/compilefixes.diff
|
||||
|
||||
# the configure script isn't autoconf (yay), but it has CRLFs (boo)
|
||||
sed -i 's,\r,,g' configure
|
||||
sh configure
|
||||
sed -i "/^CFLAGS/s,$, $SLKCFLAGS -fpermissive," configuration
|
||||
|
||||
make
|
||||
|
||||
# 'make install' installs maps/worlds a+w, don't want. We use
|
||||
# setgid games executables instead.
|
||||
mkdir -p $PKG/usr/games $PKG/usr/share/games/smw/
|
||||
install -s -m0755 smw $PKG/usr/games
|
||||
install -s -m2755 -g games leveledit $PKG/usr/games/smw-leveledit
|
||||
install -s -m2755 -g games worldedit $PKG/usr/games/smw-worldedit
|
||||
cp -r gfx maps music sfx tours worlds $PKG/usr/share/games/smw
|
||||
chown -R root:games $PKG/usr/share/games/smw
|
||||
chmod -R 0775 $PKG/usr/share/games/smw
|
||||
|
||||
# icons extracted from _src/icons/*.ico with icotool.
|
||||
# .desktop files written for this build.
|
||||
# No man pages, since none of the executables take any options.
|
||||
mkdir -p $PKG/usr/share/applications $PKG/usr/share/pixmaps
|
||||
for i in $PKG/usr/games/*; do
|
||||
exe=$(basename $i)
|
||||
cat $CWD/icons/$exe.png > $PKG/usr/share/pixmaps/$exe.png
|
||||
cat $CWD/desktop/$exe.desktop > $PKG/usr/share/applications/$exe.desktop
|
||||
done
|
||||
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
# get rid of the CRLFs in the docs
|
||||
for i in *.html *.html *.txt; do
|
||||
sed 's,\r,,g' "$i" > $PKG/usr/doc/$PRGNAM-$VERSION/"$i"
|
||||
done
|
||||
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
|
||||
|
||||
mkdir -p $PKG/install
|
||||
cat $CWD/slack-desc > $PKG/install/slack-desc
|
||||
cat $CWD/doinst.sh > $PKG/install/doinst.sh
|
||||
|
||||
cd $PKG
|
||||
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
|
10
games/supermariowar/supermariowar.info
Normal file
10
games/supermariowar/supermariowar.info
Normal file
|
@ -0,0 +1,10 @@
|
|||
PRGNAM="supermariowar"
|
||||
VERSION="r16"
|
||||
HOMEPAGE="https://code.google.com/p/supermariowar/"
|
||||
DOWNLOAD="http://urchlay.naptime.net/~urchlay/src/supermariowar-r16.tar.gz"
|
||||
MD5SUM="f64f5471b1d8811265ebbf799915ac76"
|
||||
DOWNLOAD_x86_64=""
|
||||
MD5SUM_x86_64=""
|
||||
REQUIRES=""
|
||||
MAINTAINER="B. Watson"
|
||||
EMAIL="yalhcru@gmail.com"
|
Loading…
Reference in a new issue