package protocolsupport.protocol.transformer.middlepacket.clientbound.play;

import java.io.IOException;

import net.minecraft.server.v1_9_R1.BlockPosition;
import protocolsupport.protocol.PacketDataSerializer;
import protocolsupport.protocol.transformer.middlepacket.ClientBoundMiddlePacket;

public abstract class MiddleSpawnPainting<T> extends ClientBoundMiddlePacket<T> {

	protected int entityId;
	protected String type;
	protected BlockPosition position;
	protected int direction;

	@Override
	public void readFromServerData(PacketDataSerializer serializer) throws IOException {
		entityId = serializer.readVarInt();
		type = serializer.readString(13);
		position = serializer.readPosition();
		direction = serializer.readByte();
	}

}

@@ -97,16 +97,39 @@
 ception;
+%0Aimport java.util.UUID;
 %0A%0Aimport
@@ -418,16 +418,38 @@
 tityId;%0A
+%09protected UUID uuid;%0A
 %09protect
@@ -661,16 +661,48 @@
 rInt();%0A
+%09%09uuid = serializer.readUUID();%0A
 %09%09type =
@@ -769,16 +769,16 @@
 tion();%0A
-
 %09%09direct
@@ -798,16 +798,24 @@
 zer.read
+Unsigned
 Byte();%0A

Fix spawn painting packet reading