Skip to content

Commit

Permalink
So many changes. :)
Browse files Browse the repository at this point in the history
  • Loading branch information
theZiz committed Jul 23, 2014
1 parent 3956c79 commit 8280275
Show file tree
Hide file tree
Showing 12 changed files with 156 additions and 93 deletions.
2 changes: 0 additions & 2 deletions README.md

This file was deleted.

9 changes: 9 additions & 0 deletions build/gcw/default.gcw0.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[Desktop Entry]
Name=Hase Prototype
Comment=A game about bunnies in space
Exec=hase.sh
Terminal=false
Type=Application
StartupNotify=true
Icon=hase_prototype
Categories=games;
3 changes: 3 additions & 0 deletions build/gcw/hase.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh
cd hase
LD_LIBRARY_PATH=. ./lobby
Binary file added build/gcw/hase_prototype.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
128 changes: 62 additions & 66 deletions build/pandora/hase/PXML.xml
Original file line number Diff line number Diff line change
@@ -1,67 +1,63 @@
<?xml version="1.0" encoding="UTF-8"?>
<PXML xmlns="http://openpandora.org/namespaces/PXML" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="PXML_schema.xsd">
<package id="hase_prototype-hase_prototype-12345">
<version major="1" minor="0" release="3" build="2"/>
<author name="Ziz" website="http://ziz.openhandhelds.org"/>
<titles>
<title lang="en_US">
Hase Prototype
</title>
</titles>
<title lang="en_US">
Hase Prototype
</title>
<descriptions>
<description lang="en_US">
A prototype of a 2D worms like game with gravitation and stuff...
Entry for the crap game competition 2013.
</description>
</descriptions>
<description lang="en_US">
A prototype of a 2D worms like game with gravitation and stuff...
Entry for the crap game competition 2013.
</description>
<icon src="./hase_prototype.png"/>
</package>
<application id="hase_prototype-hase_prototype-12345" appdata="hase_prototype">
<exec command="./hase.sh"/>
<title lang="en_US">Hase Prototype against Player</title>
<author name="Ziz" website="http://ziz.openhandhelds.org"/>
<version major="1" minor="0" release="3" build="2"/>
<osversion major="1" minor="0" release="0" build="0"/>
<description lang="en_US">A game about bunnies in space</description>
<icon src="./hase_prototype.png"/>
<previewpics>
<pic src="previews/screenshot1.png"/>
</previewpics>
<licenses>
<license name="GPLv2+" url="http://www.gnu.org/licenses/gpl-2.0.html" sourcecodeurl="https://github.com/theZiz/hase"/>
</licenses>
<categories>
<category name="Game">
<subcategory name="ActionGame"/>
</category>
</categories>
</application>
<application id="hase_prototype-hase_ai_prototype-12345" appdata="hase_prototype">
<exec command="./hase_ai.sh"/>
<title lang="en_US">Hase Prototype against AI</title>
<author name="Ziz" website="http://ziz.openhandhelds.org"/>
<version major="1" minor="0" release="3" build="2"/>
<osversion major="1" minor="0" release="0" build="0"/>
<description lang="en_US">A game about bunnies in space</description>
<icon src="./hase_prototype.png"/>
<previewpics>
<pic src="previews/screenshot2.png"/>
<pic src="previews/screenshot1.png"/>
</previewpics>
<licenses>
<license name="GPLv2+" url="http://www.gnu.org/licenses/gpl-2.0.html" sourcecodeurl="https://github.com/theZiz/hase"/>
</licenses>
<categories>
<category name="Game">
<subcategory name="ActionGame"/>
</category>
</categories>
</application>
<!-- This is a sample PXML.xml file making use of many different things.-->
<PXML xmlns="http://openpandora.org/namespaces/PXML">
<package id="hase_prototype-hase_prototype-12345">
<version major="1" minor="1" release="0" build="0"/>
<author name="Ziz" website="http://ziz.openhandhelds.org"/>
<titles>
<title lang="en_US">
Hase Prototype 2
</title>
</titles>
<descriptions>
<description lang="en_US">
A prototype of a 2D worms like game with gravitation and stuff...
Version 2: Now with network support!
</description>
</descriptions>
<icon src="./hase_prototype.png"/>
</package>
<application id="hase_prototype-hase_prototype-12345" appdata="hase_prototype">
<exec command="./hase.sh"/>
<version major="1" minor="1" release="0" build="0" type="release"/>
<!--This program's version-->
<osversion major="1" minor="0" release="0" build="0"/>
<!--The minimum OS version required-->
<author name="Ziz" website="http://ziz.openhandhelds.org"/>
<!--Optional email and website, name required-->
<titles>
<title lang="en_US">
Hase Prototype 2
</title>
</titles>
<title lang="en_US">
Hase Prototype 2
</title>
<!--Extra <title> block for compatibility with OS versions before HF6-->
<descriptions>
<description lang="en_US">
A prototype of a 2D worms like game with gravitation and stuff...
Version 2: Now with network support!
</description>
</descriptions>
<description lang="en_US">
A prototype of a 2D worms like game with gravitation and stuff...
Version 2: Now with network support!
</description>
<!--Extra <description> block for compatibility with OS versions before HF6-->
<icon src="./hase_prototype.png"/>
<licenses>
<license name="GPLv2+" url="http://www.gnu.org/licenses/gpl-2.0.html" sourcecodeurl="https://github.com/theZiz/hase"/>
<!--Optional url and sourcecodeurl, mandatory name-->
</licenses>
<previewpics>
<pic src="previews/screenshot1.png"/>
</previewpics>
<info name="Readme" type="text/x-markdown" src="hase.md"/>
<!--the categories has to conform to the FDO categories, those will be enforced by the schema and libpnd!-->
<categories>
<category name="Game">
<subcategory name="ActionGame"/>
</category>
</categories>
</application>
</PXML>
2 changes: 1 addition & 1 deletion build/pandora/hase/hase.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ cat /proc/pandora/nub1/mode > /tmp/nub1mode_before_hase
echo absolute > /proc/pandora/nub0/mode
echo absolute > /proc/pandora/nub1/mode

LD_LIBRARY_PATH=. ./hase $*
LD_LIBRARY_PATH=. ./lobby $*

cat /tmp/nub0mode_before_hase > /proc/pandora/nub0/mode
cat /tmp/nub1mode_before_hase > /proc/pandora/nub1/mode
Expand Down
21 changes: 0 additions & 21 deletions build/pandora/hase/hase_ai.sh

This file was deleted.

2 changes: 1 addition & 1 deletion build/pandora/make_package.sh
Original file line number Diff line number Diff line change
@@ -1 +1 @@
/opt/pandora-sebt/scripts/pnd_make -p ../../../hase_prototype.pnd -d . -x ./PXML.xml -i ./hase_prototype.png
/opt/pandora/sdk_utils/pnd_make.sh -c -p ../../../hase.pnd -d . -x ./PXML.xml -i ./hase_prototype.png
4 changes: 4 additions & 0 deletions hase.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Hase
====

To do. :P
4 changes: 2 additions & 2 deletions lobby.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ void resize( Uint16 w, Uint16 h )
spFontAddButton( font, 's', SP_BUTTON_DOWN_NAME, 65535, spGetRGB(127,127,127) ); // s == down button
spFontMulWidth(font,spFloatToFixed(0.9f));

spSetVirtualKeyboard(SP_VIRTUAL_KEYBOARD_IF_NEEDED,0,h-w*48/320,w,w*48/320,spLoadSurface("./data/keyboard320.png"),spLoadSurface("./data/keyboardShift320.png"));
spSetVirtualKeyboard(SP_VIRTUAL_KEYBOARD_ALWAYS,0,h-w*48/320,w,w*48/320,spLoadSurface("./data/keyboard320.png"),spLoadSurface("./data/keyboardShift320.png"));
}

int main(int argc, char **argv)
{
spSetRand(time(NULL));
spSetDefaultWindowSize( 640, 480 );
spSetDefaultWindowSize( 320, 240 );
spInitCore();
spInitNet();
screen = spCreateDefaultWindow();
Expand Down
20 changes: 20 additions & 0 deletions make_every_target.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#!/bin/sh
# Change the folder to YOUR sparrow3d folder!
cd ../sparrow3d
FILES=./target-files/*
echo "Compiling for all targets..."
for f in $FILES
do
cd ../hase
TARGET=`echo "$f" | cut -d/ -f3 | cut -d. -f1`
make clean > /dev/null
make TARGET=$TARGET > /dev/null
if [ $? -ne 0 ]; then
echo "Error compiling for \033[1;31m$TARGET\033[0m!"
else
echo "Everything fine with \033[1;32m$TARGET\033[0m!"
fi
done
echo "Compiling for default..."
make clean > /dev/null
make > /dev/null
54 changes: 54 additions & 0 deletions make_release_packages.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
#!/bin/sh
PROGRAM="hase"
VERSION="1.1.0.0"
DEST=./build/*
echo "<html>" > index.htm
echo "<head>" >> index.htm
echo "</head>" >> index.htm
echo "<body>" >> index.htm
TIME=`date -u +"%d.%m.%Y %R"`
echo "Updated at the $TIME." >> index.htm
echo "<h1>$PROGRAM download links:</h1>" >> index.htm
for f in $DEST
do
if [ -e "$f/$PROGRAM/lobby" ]; then
NAME=`echo "$f" | cut -d/ -f3 | cut -d. -f1`
echo "$NAME:"
echo "--> Copy temporary folders"
cp -r data "$f/$PROGRAM"
cp -r textures "$f/$PROGRAM"
cp hase.md "$f/$PROGRAM"
cd $f
echo "--> Create archive"
if [ $NAME = "pandora" ]; then
cd $PROGRAM
../make_package.sh
cd ..
echo "<a href=$PROGRAM.pnd>$NAME</a></br>" >> ../../index.htm
else
if [ $NAME = "i386" ]; then
tar cfvz "$PROGRAM-$NAME-$VERSION.tar.gz" * > /dev/null
mv "$PROGRAM-$NAME-$VERSION.tar.gz" ../..
echo "<a href=$PROGRAM-$NAME-$VERSION.tar.gz>$NAME</a></br>" >> ../../index.htm
else
if [ $NAME = "gcw" ]; then
mksquashfs * "$PROGRAM.opk" -all-root -noappend -no-exports -no-xattrs
mv "$PROGRAM.opk" ../..
echo "<a href=$PROGRAM.opk type=\"application/x-opk+squashfs\">$NAME</a></br>" >> ../../index.htm
else
zip -r "$PROGRAM-$NAME-$VERSION.zip" * > /dev/null
mv "$PROGRAM-$NAME-$VERSION.zip" ../..
echo "<a href=$PROGRAM-$NAME-$VERSION.zip>$NAME</a></br>" >> ../../index.htm
fi
fi
fi
echo "--> Remove temporary folders"
rm -r $PROGRAM/data
rm -r $PROGRAM/textures
rm $PROGRAM/hase.md
cd ..
cd ..
fi
done
echo "</body>" >> index.htm
echo "</html>" >> index.htm

0 comments on commit 8280275

Please sign in to comment.