Mirror von
https://github.com/GeyserMC/Geyser.git
synchronisiert 2024-11-20 06:50:09 +01:00
Fix compiling probably
Dieser Commit ist enthalten in:
Ursprung
11c277481f
Commit
05a88f7693
@ -134,7 +134,6 @@ public class CustomItemRegistryPopulator {
|
||||
.stackSize(customItemData.stackSize())
|
||||
.maxDamage(customItemData.maxDamage());
|
||||
Item item = new Item(customIdentifier, itemBuilder) {
|
||||
// TODO ?
|
||||
@Override
|
||||
public boolean isValidRepairItem(Item other) {
|
||||
return repairMaterials != null && repairMaterials.contains(other.javaIdentifier());
|
||||
|
@ -368,7 +368,7 @@ public final class Scoreboard {
|
||||
}
|
||||
|
||||
@Contract("-> new")
|
||||
public LinkedHashMap<String, Set<CommandEnumConstraint>> getTeamNames() {
|
||||
public Map<String, Set<CommandEnumConstraint>> getTeamNames() {
|
||||
return teams.keySet().stream()
|
||||
.collect(Collectors.toMap(Function.identity(), o -> EnumSet.noneOf(CommandEnumConstraint.class),
|
||||
(o1, o2) -> o1, LinkedHashMap::new));
|
||||
|
@ -84,7 +84,6 @@ import org.cloudburstmc.math.vector.*;
|
||||
import org.cloudburstmc.nbt.NbtMap;
|
||||
import org.cloudburstmc.protocol.bedrock.BedrockServerSession;
|
||||
import org.cloudburstmc.protocol.bedrock.data.*;
|
||||
import org.cloudburstmc.protocol.bedrock.data.command.CommandEnumConstraint;
|
||||
import org.cloudburstmc.protocol.bedrock.data.command.CommandEnumData;
|
||||
import org.cloudburstmc.protocol.bedrock.data.command.CommandPermission;
|
||||
import org.cloudburstmc.protocol.bedrock.data.command.SoftEnumUpdateType;
|
||||
@ -1932,8 +1931,7 @@ public class GeyserSession implements GeyserConnection, GeyserCommandSource {
|
||||
private void softEnumPacket(String name, SoftEnumUpdateType type, String enums) {
|
||||
UpdateSoftEnumPacket packet = new UpdateSoftEnumPacket();
|
||||
packet.setType(type);
|
||||
// TODO
|
||||
packet.setSoftEnum(new CommandEnumData(name, new LinkedHashMap<>(Collections.singletonMap(enums, EnumSet.noneOf(CommandEnumConstraint.class))), true));
|
||||
packet.setSoftEnum(new CommandEnumData(name, Collections.singletonMap(enums, Collections.emptySet()), true));
|
||||
sendUpstreamPacket(packet);
|
||||
}
|
||||
}
|
||||
|
@ -390,7 +390,7 @@ public class JavaCommandsTranslator extends PacketTranslator<ClientboundCommands
|
||||
// String[] enumOptions = Arrays.copyOf(enumParamInfo.getParamData().getEnumData().getValues(), enumParamInfo.getParamData().getEnumData().getValues().size() + 1);
|
||||
// enumOptions[enumOptions.length - 1] = paramNode.getName();
|
||||
|
||||
LinkedHashMap<String, Set<CommandEnumConstraint>> values = (LinkedHashMap<String, Set<CommandEnumConstraint>>) enumParamInfo.getParamData().getEnumData().getValues().clone();
|
||||
Map<String, Set<CommandEnumConstraint>> values = new LinkedHashMap<>(enumParamInfo.getParamData().getEnumData().getValues());
|
||||
values.put(paramNode.getName(), Set.of());
|
||||
|
||||
// Re-create the command using the updated values
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren