SteamWar/FightSystem
Archiviert
13
1

Fixing NBTTagList

Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Lixfel 2020-01-01 20:03:28 +01:00
Ursprung ebefab135a
Commit 0de2dd0d41

Datei anzeigen

@ -6,7 +6,6 @@ import com.comphenix.protocol.events.PacketAdapter;
import com.comphenix.protocol.events.PacketContainer;
import com.comphenix.protocol.events.PacketEvent;
import com.comphenix.protocol.reflect.StructureModifier;
import com.comphenix.protocol.wrappers.nbt.NbtBase;
import com.comphenix.protocol.wrappers.nbt.NbtCompound;
import com.comphenix.protocol.wrappers.nbt.NbtFactory;
import de.steamwar.fightsystem.Config;
@ -56,8 +55,8 @@ public class TechHider_14 {
cached = packet.deepClone();
ITechHider.packetCache.put(packet, cached);
e.setPacket(cached);
StructureModifier<List<NbtBase<?>>> list = cached.getListNbtModifier();
List<NbtBase<?>> nmsTags = list.read(0);
StructureModifier<List> list = cached.getSpecificModifier(List.class);
List nmsTags = list.read(0);
boolean changed = false;
for(int i = nmsTags.size() - 1; i >= 0; i--){
NbtCompound nbt = NbtFactory.fromNMSCompound(nmsTags.get(i));