[fix] Add patch to allow entering world 2

This commit is contained in:
Carsten Teibes 2014-07-17 04:33:09 +02:00
parent b50d8d70bf
commit 15c4c0dce4
3 changed files with 30 additions and 2 deletions

View file

@ -18,8 +18,10 @@ pkgbase = smc-git
conflicts = smc
source = smc::git+https://github.com/FluXy/SMC.git
source = smc.desktop
source = smc-get-to-world2.patch
sha256sums = SKIP
sha256sums = 291fca2243262c24cf086bec60ae77fd53f58bc42e876b224d58e96a5a35d79a
sha256sums = 04d2b8850005fea4cf8a66be48f2f3ffc3848851dabdc8d2294b6e65e021bca0
pkgname = smc-git

View file

@ -12,15 +12,22 @@ depends=('sdl_image' 'sdl_ttf' 'sdl_mixer' 'cegui-0.7' 'boost-libs' 'libgl')
makedepends=('boost' 'git')
conflicts=('smc')
provides=('smc')
source=(smc::"git+https://github.com/FluXy/SMC.git" "smc.desktop")
source=(smc::"git+https://github.com/FluXy/SMC.git"
"smc.desktop"
"smc-get-to-world2.patch")
sha256sums=('SKIP'
'291fca2243262c24cf086bec60ae77fd53f58bc42e876b224d58e96a5a35d79a')
'291fca2243262c24cf086bec60ae77fd53f58bc42e876b224d58e96a5a35d79a'
'04d2b8850005fea4cf8a66be48f2f3ffc3848851dabdc8d2294b6e65e021bca0')
pkgver() {
cd smc
echo $(git rev-list --count master).$(git rev-parse --short master)
}
prepare() {
patch -Np1 < smc-get-to-world2.patch
}
build() {
cd smc/smc

19
smc-get-to-world2.patch Normal file
View file

@ -0,0 +1,19 @@
--- a/smc/smc/src/overworld/world_manager.cpp 2014-07-13 17:11:53.337301000 +0200
+++ b/smc/smc/src/overworld/world_manager.cpp 2014-07-13 17:32:06.634548009 +0200
@@ -204,6 +204,16 @@
{
return obj;
}
+ else if(obj->m_description->m_path.at(0) == '/')
+ {
+ std::string newPath ( obj->m_description->m_path );
+ newPath.erase(0,1);
+ if(newPath.compare( path ) == 0)
+ {
+ return obj;
+ }
+ }
+
}
return NULL;