Merge pull request #4 from psxlover/Fixes
NPE fix and build.bat improvements.
This commit is contained in:
commit
dcd076728e
2 changed files with 22 additions and 20 deletions
24
build.bat
24
build.bat
|
@ -4,16 +4,16 @@ rmdir /S /Q ..\src
|
|||
mkdir ..\src
|
||||
xcopy /Y /E ..\src_work\* ..\src\
|
||||
|
||||
xcopy /Y /E buildcraft_client\src\net\* ..\src\minecraft\net
|
||||
xcopy /Y /E buildcraft_server\src\net\* ..\src\minecraft_server\net
|
||||
xcopy /Y /E buildcraft_client\net\* ..\src\minecraft\net\
|
||||
xcopy /Y /E buildcraft_server\net\* ..\src\minecraft_server\net\
|
||||
|
||||
xcopy /Y /E common\net\* ..\src\minecraft\net
|
||||
xcopy /Y /E common\net\* ..\src\minecraft_server\net
|
||||
xcopy /Y /E common\net\* ..\src\minecraft\net\
|
||||
xcopy /Y /E common\net\* ..\src\minecraft_server\net\
|
||||
|
||||
xcopy /Y /E ..\forge\forge_client\src\net\* ..\src\minecraft\net
|
||||
xcopy /Y /E ..\forge\forge_client\src\net\* ..\src\minecraft\net\
|
||||
|
||||
xcopy /Y /E ..\forge\forge_common\net\* ..\src\minecraft\net
|
||||
xcopy /Y /E ..\forge\forge_common\net\* ..\src\minecraft_server\net
|
||||
xcopy /Y /E ..\forge\forge_common\net\* ..\src\minecraft\net\
|
||||
xcopy /Y /E ..\forge\forge_common\net\* ..\src\minecraft_server\net\
|
||||
|
||||
cd ..
|
||||
cmd /C recompile.bat
|
||||
|
@ -25,8 +25,8 @@ mkdir ..\bin\minecraft\net\minecraft\src\buildcraft\transport\gui
|
|||
mkdir ..\bin\minecraft\net\minecraft\src\buildcraft\builders\gui
|
||||
mkdir ..\bin\minecraft\net\minecraft\src\buildcraft\energy\gui
|
||||
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\core\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\core\gui
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\factory\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\factory\gui
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\transport\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\transport\gui
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\builders\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\builders\gui
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\energy\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\energy\gui
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\core\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\core\gui\
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\factory\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\factory\gui\
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\transport\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\transport\gui\
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\builders\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\builders\gui\
|
||||
xcopy /Y /E common\net\minecraft\src\buildcraft\energy\gui\*.png ..\bin\minecraft\net\minecraft\src\buildcraft\energy\gui\
|
||||
|
|
|
@ -14,6 +14,7 @@ import java.util.LinkedList;
|
|||
|
||||
import net.minecraft.src.IInventory;
|
||||
import net.minecraft.src.ItemStack;
|
||||
import net.minecraft.src.buildcraft.api.APIProxy;
|
||||
import net.minecraft.src.buildcraft.core.AssemblyRecipe;
|
||||
import net.minecraft.src.buildcraft.core.CoreProxy;
|
||||
import net.minecraft.src.buildcraft.core.GuiAdvancedInterface;
|
||||
|
@ -148,15 +149,16 @@ public class GuiAssemblyTable extends GuiAdvancedInterface {
|
|||
|
||||
ContainerAssemblyTable container = (ContainerAssemblyTable)inventorySlots;
|
||||
|
||||
PacketPayload payload = TileAssemblyTable.selectionMessageWrapper
|
||||
.toPayload(container.x, container.y,
|
||||
container.z, message);
|
||||
if(APIProxy.isRemote()) {
|
||||
PacketPayload payload = TileAssemblyTable.selectionMessageWrapper.toPayload(container.x, container.y,container.z, message);
|
||||
|
||||
PacketUpdate packet = new PacketUpdate(PacketIds.SELECTION_ASSEMBLY, payload);
|
||||
packet.posX = container.x;
|
||||
packet.posY = container.y;
|
||||
packet.posZ = container.z;
|
||||
CoreProxy.sendToServer(packet.getPacket());
|
||||
PacketUpdate packet = new PacketUpdate(PacketIds.SELECTION_ASSEMBLY, payload);
|
||||
packet.posX = container.x;
|
||||
packet.posY = container.y;
|
||||
packet.posZ = container.z;
|
||||
|
||||
CoreProxy.sendToServer(packet.getPacket());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue