Fixed linux scripts, fixed TE bug.
This commit is contained in:
parent
56c165800b
commit
7c66376a3b
6 changed files with 27 additions and 14 deletions
|
@ -11,10 +11,10 @@ cp -a forge/forge_server/src/net/* src_forge/minecraft_server/net/
|
|||
cp -a forge/forge_common/net/* src_forge/minecraft/net/
|
||||
cp -a forge/forge_common/net/* src_forge/minecraft_server/net/
|
||||
|
||||
cd forge
|
||||
./inject_version.sh ../src_forge/minecraft/net/minecraft/src/forge/ForgeHooks.java
|
||||
./inject_version.sh ../src_forge/minecraft_server/net/minecraft/src/forge/ForgeHooks.java
|
||||
cd ..
|
||||
pushd forge > /dev/null
|
||||
./inject_version.sh $OLDPWD/src_forge/minecraft/net/minecraft/src/forge/ForgeHooks.java
|
||||
./inject_version.sh $OLDPWD/src_forge/minecraft_server/net/minecraft/src/forge/ForgeHooks.java
|
||||
popd > /dev/null
|
||||
|
||||
cp -a src_forge src
|
||||
|
||||
|
|
0
forge/inject_version.sh
Normal file → Executable file
0
forge/inject_version.sh
Normal file → Executable file
|
@ -5,7 +5,7 @@
|
|||
Block.blocksList[l1].onBlockRemoval(worldObj, i2, j, j2);
|
||||
}
|
||||
- else if ((Block.blocksList[l1] instanceof BlockContainer) && l1 != l)
|
||||
+ else if (Block.blocksList[l1] != null && Block.blocksList[l1].hasTileEntity(getBlockMetadata(i, j, k)) && l1 != l)
|
||||
+ else if (Block.blocksList[l1] != null && Block.blocksList[l1].hasTileEntity(getBlockMetadata(i, j, k)))
|
||||
{
|
||||
worldObj.removeBlockTileEntity(i2, j, j2);
|
||||
}
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
Block.blocksList[l1].onBlockRemoval(worldObj, i2, j, j2);
|
||||
}
|
||||
- else if ((Block.blocksList[l1] instanceof BlockContainer) && l1 != l)
|
||||
+ else if (Block.blocksList[l1] != null && Block.blocksList[l1].hasTileEntity(getBlockMetadata(i, j, k)) && l1 != l)
|
||||
+ else if (Block.blocksList[l1] != null && Block.blocksList[l1].hasTileEntity(getBlockMetadata(i, j, k)))
|
||||
{
|
||||
worldObj.removeBlockTileEntity(i2, j, j2);
|
||||
}
|
||||
|
|
|
@ -46,6 +46,12 @@ cp -a src_work src_forge
|
|||
cp -a forge/forge_client/src/net/* src_forge/minecraft/net/
|
||||
cp -a forge/forge_common/net/* src_forge/minecraft/net/
|
||||
cp -a forge/forge_common/net/* src_forge/minecraft_server/net/
|
||||
cp -a forge/forge_server/src/net/* src_forge/minecraft_server/net/
|
||||
|
||||
pushd forge > /dev/null
|
||||
./inject_version.sh $OLDPWD/src_forge/minecraft/net/minecraft/src/forge/ForgeHooks.java
|
||||
./inject_version.sh $OLDPWD/src_forge/minecraft_server/net/minecraft/src/forge/ForgeHooks.java
|
||||
popd > /dev/null
|
||||
|
||||
cp -a src_forge src
|
||||
|
||||
|
|
23
forge/update_patches.sh
Normal file → Executable file
23
forge/update_patches.sh
Normal file → Executable file
|
@ -1,34 +1,41 @@
|
|||
echo Creating directories
|
||||
|
||||
for i in `find ../src_work -type d`
|
||||
fdir=$PWD
|
||||
cd ..
|
||||
|
||||
for i in `find src_work -type d`
|
||||
do
|
||||
mkdir --parents "./patches${i:11}"
|
||||
mkdir --parents "$fdir/patches${i##src_work}"
|
||||
done
|
||||
|
||||
echo Creating patches
|
||||
|
||||
cd src_work
|
||||
for i in `find ../src_work -type f`
|
||||
do
|
||||
diff -u ../src_base${i:11} $i -r --strip-trailing-cr --new-file | sed -e "1,2s/[0-9-]* [0-9:\.]* [+-][0-9]*\b/0000-00-00 00:00:00.000000000 -0000/" | tr -d '\r' > ./patches${i:11}.patch
|
||||
ibase=${i##../src_work}
|
||||
diff -u ../src_base$ibase $i -r --strip-trailing-cr --new-file | sed -e "1,2s/[0-9-]* [0-9:\.]* [+-][0-9]*\b/0000-00-00 00:00:00.000000000 -0000/" | tr -d '\r' > $fdir/patches$ibase.patch
|
||||
done
|
||||
cd ..
|
||||
|
||||
echo Removing empty patches
|
||||
find patches -size 0 -type f -name \*.patch -delete
|
||||
for i in `find patches -depth -empty -type d | grep -a -v "svn"`
|
||||
find $fdir/patches -size 0 -type f -name \*.patch -delete
|
||||
for i in `find $fdir/patches -depth -empty -type d | grep -a -v "svn"`
|
||||
do
|
||||
rmdir "$i"
|
||||
done
|
||||
|
||||
echo Grabbing copy of conf folder
|
||||
for i in `find conf -type f | grep -a -v "svn"`
|
||||
for i in `find $fdir/conf -type f | grep -a -v "svn"`
|
||||
do
|
||||
rm $i
|
||||
done
|
||||
for i in `find conf -depth -empty -type d | grep -a -v "svn"`
|
||||
for i in `find $fdir/conf -depth -empty -type d | grep -a -v "svn"`
|
||||
do
|
||||
rmdir "$i"
|
||||
done
|
||||
|
||||
cp -r ../conf/* conf
|
||||
mkdir -p $fdir/conf
|
||||
cp -r conf/* $fdir/conf
|
||||
|
||||
echo Finished
|
||||
|
|
Loading…
Reference in a new issue