@@ -151,7 +151,7 @@ public enum CraftParticle {
|
||||
}
|
||||
|
||||
public static Particle toBukkit(net.minecraft.server.ParticleParam nms) {
|
||||
return toBukkit(nms.b());
|
||||
return toBukkit(nms.getParticle());
|
||||
}
|
||||
|
||||
public static Particle toBukkit(net.minecraft.server.Particle nms) {
|
||||
|
||||
@@ -306,7 +306,7 @@ public final class CraftServer implements Server {
|
||||
ambientSpawn = configuration.getInt("spawn-limits.ambient");
|
||||
console.autosavePeriod = configuration.getInt("ticks-per.autosave");
|
||||
warningState = WarningState.value(configuration.getString("settings.deprecated-verbose"));
|
||||
TicketType.PLUGIN.setLoadPeriod(configuration.getInt("chunk-gc.period-in-ticks"));
|
||||
TicketType.PLUGIN.loadPeriod = configuration.getInt("chunk-gc.period-in-ticks");
|
||||
minimumAPI = configuration.getString("settings.minimum-api");
|
||||
loadIcon();
|
||||
}
|
||||
@@ -717,7 +717,7 @@ public final class CraftServer implements Server {
|
||||
waterAnimalSpawn = configuration.getInt("spawn-limits.water-animals");
|
||||
ambientSpawn = configuration.getInt("spawn-limits.ambient");
|
||||
warningState = WarningState.value(configuration.getString("settings.deprecated-verbose"));
|
||||
TicketType.PLUGIN.setLoadPeriod(configuration.getInt("chunk-gc.period-in-ticks"));
|
||||
TicketType.PLUGIN.loadPeriod = configuration.getInt("chunk-gc.period-in-ticks");
|
||||
minimumAPI = configuration.getString("settings.minimum-api");
|
||||
printSaveWarning = false;
|
||||
console.autosavePeriod = configuration.getInt("ticks-per.autosave");
|
||||
@@ -1826,11 +1826,11 @@ public final class CraftServer implements Server {
|
||||
case org.bukkit.Tag.REGISTRY_BLOCKS:
|
||||
Preconditions.checkArgument(clazz == org.bukkit.Material.class, "Block namespace must have material type");
|
||||
|
||||
return (org.bukkit.Tag<T>) new CraftBlockTag(console.getTagRegistry().a(), key);
|
||||
return (org.bukkit.Tag<T>) new CraftBlockTag(console.getTagRegistry().getBlockTags(), key);
|
||||
case org.bukkit.Tag.REGISTRY_ITEMS:
|
||||
Preconditions.checkArgument(clazz == org.bukkit.Material.class, "Item namespace must have material type");
|
||||
|
||||
return (org.bukkit.Tag<T>) new CraftItemTag(console.getTagRegistry().b(), key);
|
||||
return (org.bukkit.Tag<T>) new CraftItemTag(console.getTagRegistry().getItemTags(), key);
|
||||
default:
|
||||
throw new IllegalArgumentException();
|
||||
}
|
||||
@@ -1843,12 +1843,12 @@ public final class CraftServer implements Server {
|
||||
case org.bukkit.Tag.REGISTRY_BLOCKS:
|
||||
Preconditions.checkArgument(clazz == org.bukkit.Material.class, "Block namespace must have material type");
|
||||
|
||||
TagsServer<Block> blockTags = console.getTagRegistry().a(); // PAIL: getBlockTags
|
||||
TagsServer<Block> blockTags = console.getTagRegistry().getBlockTags();
|
||||
return blockTags.b().keySet().stream().map(key -> (org.bukkit.Tag<T>) new CraftBlockTag(blockTags, key)).collect(ImmutableList.toImmutableList());
|
||||
case org.bukkit.Tag.REGISTRY_ITEMS:
|
||||
Preconditions.checkArgument(clazz == org.bukkit.Material.class, "Item namespace must have material type");
|
||||
|
||||
TagsServer<Item> itemTags = console.getTagRegistry().b(); // PAIL: getItemTags
|
||||
TagsServer<Item> itemTags = console.getTagRegistry().getItemTags();
|
||||
return itemTags.b().keySet().stream().map(key -> (org.bukkit.Tag<T>) new CraftItemTag(itemTags, key)).collect(ImmutableList.toImmutableList());
|
||||
default:
|
||||
throw new IllegalArgumentException();
|
||||
|
||||
@@ -113,8 +113,8 @@ public enum CraftStatistic {
|
||||
}
|
||||
|
||||
public static org.bukkit.Statistic getBukkitStatistic(net.minecraft.server.Statistic<?> statistic) {
|
||||
IRegistry statRegistry = statistic.a().a();
|
||||
MinecraftKey nmsKey = IRegistry.STATS.getKey(statistic.a());
|
||||
IRegistry statRegistry = statistic.getWrapper().getRegistry();
|
||||
MinecraftKey nmsKey = IRegistry.STATS.getKey(statistic.getWrapper());
|
||||
|
||||
if (statRegistry == IRegistry.CUSTOM_STAT) {
|
||||
nmsKey = (MinecraftKey) statistic.b();
|
||||
|
||||
@@ -482,7 +482,7 @@ public class CraftWorld implements World {
|
||||
Preconditions.checkArgument(plugin != null, "null plugin");
|
||||
Preconditions.checkArgument(plugin.isEnabled(), "plugin is not enabled");
|
||||
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.u;
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.chunkDistanceManager;
|
||||
|
||||
if (chunkDistanceManager.addTicketAtLevel(TicketType.PLUGIN_TICKET, new ChunkCoordIntPair(x, z), 31, plugin)) { // keep in-line with force loading, add at level 31
|
||||
this.getChunkAt(x, z); // ensure loaded
|
||||
@@ -496,7 +496,7 @@ public class CraftWorld implements World {
|
||||
public boolean removePluginChunkTicket(int x, int z, Plugin plugin) {
|
||||
Preconditions.checkNotNull(plugin, "null plugin");
|
||||
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.u;
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.chunkDistanceManager;
|
||||
return chunkDistanceManager.removeTicketAtLevel(TicketType.PLUGIN_TICKET, new ChunkCoordIntPair(x, z), 31, plugin); // keep in-line with force loading, remove at level 31
|
||||
}
|
||||
|
||||
@@ -504,13 +504,13 @@ public class CraftWorld implements World {
|
||||
public void removePluginChunkTickets(Plugin plugin) {
|
||||
Preconditions.checkNotNull(plugin, "null plugin");
|
||||
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.u;
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.chunkDistanceManager;
|
||||
chunkDistanceManager.removeAllTicketsFor(TicketType.PLUGIN_TICKET, 31, plugin); // keep in-line with force loading, remove at level 31
|
||||
}
|
||||
|
||||
@Override
|
||||
public Collection<Plugin> getPluginChunkTickets(int x, int z) {
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.u;
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.chunkDistanceManager;
|
||||
ObjectSortedSet<Ticket<?>> tickets = chunkDistanceManager.tickets.get(ChunkCoordIntPair.pair(x, z));
|
||||
|
||||
if (tickets == null) {
|
||||
@@ -520,7 +520,7 @@ public class CraftWorld implements World {
|
||||
ImmutableList.Builder<Plugin> ret = ImmutableList.builder();
|
||||
for (Ticket<?> ticket : tickets) {
|
||||
if (ticket.getTicketType() == TicketType.PLUGIN_TICKET) {
|
||||
ret.add((Plugin) ticket.c);
|
||||
ret.add((Plugin) ticket.identifier);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -530,7 +530,7 @@ public class CraftWorld implements World {
|
||||
@Override
|
||||
public Map<Plugin, Collection<Chunk>> getPluginChunkTickets() {
|
||||
Map<Plugin, ImmutableList.Builder<Chunk>> ret = new HashMap<>();
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.u;
|
||||
ChunkMapDistance chunkDistanceManager = this.world.getChunkProvider().playerChunkMap.chunkDistanceManager;
|
||||
|
||||
for (Long2ObjectMap.Entry<ObjectSortedSet<Ticket<?>>> chunkTickets : chunkDistanceManager.tickets.long2ObjectEntrySet()) {
|
||||
long chunkKey = chunkTickets.getLongKey();
|
||||
@@ -546,7 +546,7 @@ public class CraftWorld implements World {
|
||||
chunk = this.getChunkAt(ChunkCoordIntPair.getX(chunkKey), ChunkCoordIntPair.getZ(chunkKey));
|
||||
}
|
||||
|
||||
ret.computeIfAbsent((Plugin) ticket.c, (key) -> ImmutableList.builder()).add(chunk);
|
||||
ret.computeIfAbsent((Plugin) ticket.identifier, (key) -> ImmutableList.builder()).add(chunk);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1923,7 +1923,7 @@ public class CraftWorld implements World {
|
||||
double y = loc.getY();
|
||||
double z = loc.getZ();
|
||||
|
||||
getHandle().a(null, x, y, z, CraftSound.getSoundEffect(CraftSound.getSound(sound)), SoundCategory.valueOf(category.name()), volume, pitch); // PAIL: rename
|
||||
getHandle().playSound(null, x, y, z, CraftSound.getSoundEffect(CraftSound.getSound(sound)), SoundCategory.valueOf(category.name()), volume, pitch);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1992,7 +1992,7 @@ public class CraftWorld implements World {
|
||||
|
||||
GameRules.GameRuleValue<?> handle = getHandle().getGameRules().get(getGameRulesNMS().get(rule));
|
||||
handle.setValue(value);
|
||||
handle.a(getHandle().getMinecraftServer());
|
||||
handle.onChange(getHandle().getMinecraftServer());
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -2016,7 +2016,7 @@ public class CraftWorld implements World {
|
||||
@Override
|
||||
public <T> T getGameRuleDefault(GameRule<T> rule) {
|
||||
Validate.notNull(rule, "GameRule cannot be null");
|
||||
return convert(rule, getGameRuleDefinitions().get(rule.getName()).a());
|
||||
return convert(rule, getGameRuleDefinitions().get(rule.getName()).getValue());
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -2028,7 +2028,7 @@ public class CraftWorld implements World {
|
||||
|
||||
GameRules.GameRuleValue<?> handle = getHandle().getGameRules().get(getGameRulesNMS().get(rule.getName()));
|
||||
handle.setValue(newValue.toString());
|
||||
handle.a(getHandle().getMinecraftServer());
|
||||
handle.onChange(getHandle().getMinecraftServer());
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -177,7 +177,7 @@ public class Main {
|
||||
useConsole = false;
|
||||
}
|
||||
|
||||
if (false && Main.class.getPackage().getImplementationVendor() != null && System.getProperty("IReallyKnowWhatIAmDoingISwear") == null) {
|
||||
if (Main.class.getPackage().getImplementationVendor() != null && System.getProperty("IReallyKnowWhatIAmDoingISwear") == null) {
|
||||
Date buildDate = new SimpleDateFormat("yyyyMMdd-HHmm").parse(Main.class.getPackage().getImplementationVendor());
|
||||
|
||||
Calendar deadline = Calendar.getInstance();
|
||||
|
||||
@@ -25,7 +25,7 @@ public class CraftAttributeInstance implements AttributeInstance {
|
||||
|
||||
@Override
|
||||
public double getBaseValue() {
|
||||
return handle.b();
|
||||
return handle.getBaseValue();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -36,7 +36,7 @@ public class CraftAttributeInstance implements AttributeInstance {
|
||||
@Override
|
||||
public Collection<AttributeModifier> getModifiers() {
|
||||
List<AttributeModifier> result = new ArrayList<AttributeModifier>();
|
||||
for (net.minecraft.server.AttributeModifier nms : handle.c()) {
|
||||
for (net.minecraft.server.AttributeModifier nms : handle.getModifiers()) {
|
||||
result.add(convert(nms));
|
||||
}
|
||||
|
||||
@@ -46,13 +46,13 @@ public class CraftAttributeInstance implements AttributeInstance {
|
||||
@Override
|
||||
public void addModifier(AttributeModifier modifier) {
|
||||
Preconditions.checkArgument(modifier != null, "modifier");
|
||||
handle.b(convert(modifier));
|
||||
handle.addModifier(convert(modifier));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void removeModifier(AttributeModifier modifier) {
|
||||
Preconditions.checkArgument(modifier != null, "modifier");
|
||||
handle.c(convert(modifier));
|
||||
handle.removeModifier(convert(modifier));
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -70,6 +70,6 @@ public class CraftAttributeInstance implements AttributeInstance {
|
||||
}
|
||||
|
||||
public static AttributeModifier convert(net.minecraft.server.AttributeModifier nms) {
|
||||
return new AttributeModifier(nms.a(), nms.b(), nms.d(), AttributeModifier.Operation.values()[nms.c().ordinal()]);
|
||||
return new AttributeModifier(nms.getUniqueId(), nms.getName(), nms.getAmount(), AttributeModifier.Operation.values()[nms.getOperation().ordinal()]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ public class CraftBanner extends CraftBlockEntityState<TileEntityBanner> impleme
|
||||
public void load(TileEntityBanner banner) {
|
||||
super.load(banner);
|
||||
|
||||
base = DyeColor.getByWoolData((byte) ((BlockBannerAbstract) this.data.getBlock()).b().getColorIndex()); // PAIL
|
||||
base = DyeColor.getByWoolData((byte) ((BlockBannerAbstract) this.data.getBlock()).getColor().getColorIndex());
|
||||
patterns = new ArrayList<Pattern>();
|
||||
|
||||
if (banner.patterns != null) {
|
||||
|
||||
@@ -76,7 +76,7 @@ public class CraftBlockData implements BlockData {
|
||||
protected <B extends Enum<B>> Set<B> getValues(BlockStateEnum<?> nms, Class<B> bukkit) {
|
||||
ImmutableSet.Builder<B> values = ImmutableSet.builder();
|
||||
|
||||
for (Enum<?> e : nms.d()) {
|
||||
for (Enum<?> e : nms.getValues()) {
|
||||
values.add(toBukkit(e, bukkit));
|
||||
}
|
||||
|
||||
|
||||
@@ -74,7 +74,7 @@ public final class VanillaCommandWrapper extends BukkitCommand {
|
||||
return ((EntityMinecartCommandBlock) ((CraftMinecartCommand) sender).getHandle()).getCommandBlock().getWrapper();
|
||||
}
|
||||
if (sender instanceof RemoteConsoleCommandSender) {
|
||||
return ((DedicatedServer) MinecraftServer.getServer()).remoteControlCommandListener.f();
|
||||
return ((DedicatedServer) MinecraftServer.getServer()).remoteControlCommandListener.getWrapper();
|
||||
}
|
||||
if (sender instanceof ConsoleCommandSender) {
|
||||
return ((CraftServer) sender.getServer()).getServer().getServerCommandListener();
|
||||
|
||||
@@ -183,7 +183,7 @@ public class CraftEnchantment extends Enchantment {
|
||||
return false;
|
||||
}
|
||||
CraftEnchantment ench = (CraftEnchantment) other;
|
||||
return !target.b(ench.target);
|
||||
return !target.isCompatible(ench.target);
|
||||
}
|
||||
|
||||
public net.minecraft.server.Enchantment getHandle() {
|
||||
|
||||
@@ -151,7 +151,7 @@ public class CraftAreaEffectCloud extends CraftEntity implements AreaEffectCloud
|
||||
}
|
||||
getHandle().effects.remove(existing);
|
||||
}
|
||||
getHandle().a(CraftPotionUtil.fromBukkit(effect));
|
||||
getHandle().addEffect(CraftPotionUtil.fromBukkit(effect));
|
||||
getHandle().refreshEffects();
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -41,14 +41,14 @@ public class CraftArrow extends AbstractProjectile implements AbstractArrow {
|
||||
|
||||
@Override
|
||||
public int getPierceLevel() {
|
||||
return getHandle().s(); // PAIL: rename
|
||||
return getHandle().getPierceLevel();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setPierceLevel(int pierceLevel) {
|
||||
Preconditions.checkArgument(0 <= pierceLevel && pierceLevel <= Byte.MAX_VALUE, "Pierce level out of range, expected 0 < level < 127");
|
||||
|
||||
getHandle().b((byte) pierceLevel); // PAIL: rename
|
||||
getHandle().setPierceLevel((byte) pierceLevel);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -645,7 +645,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
||||
public boolean hasCooldown(Material material) {
|
||||
Preconditions.checkArgument(material != null, "material");
|
||||
|
||||
return getHandle().getCooldownTracker().a(CraftMagicNumbers.getItem(material));
|
||||
return getHandle().getCooldownTracker().hasCooldown(CraftMagicNumbers.getItem(material));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1656,7 +1656,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
|
||||
ItemStack hand = getInventory().getItemInMainHand();
|
||||
getInventory().setItemInMainHand(book);
|
||||
getHandle().a(org.bukkit.craftbukkit.inventory.CraftItemStack.asNMSCopy(book), net.minecraft.server.EnumHand.MAIN_HAND); // PAIL rename openBook
|
||||
getHandle().openBook(org.bukkit.craftbukkit.inventory.CraftItemStack.asNMSCopy(book), net.minecraft.server.EnumHand.MAIN_HAND);
|
||||
getInventory().setItemInMainHand(hand);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ public class CraftTippedArrow extends CraftArrow implements Arrow {
|
||||
}
|
||||
getHandle().effects.remove(existing);
|
||||
}
|
||||
getHandle().a(CraftPotionUtil.fromBukkit(effect));
|
||||
getHandle().addEffect(CraftPotionUtil.fromBukkit(effect));
|
||||
getHandle().refreshEffects();
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -1232,7 +1232,7 @@ public class CraftEventFactory {
|
||||
c.setChatModifier(modi);
|
||||
if (c instanceof ChatMessage) {
|
||||
ChatMessage cm = (ChatMessage) c;
|
||||
Object[] oo = cm.l();
|
||||
Object[] oo = cm.getArgs();
|
||||
for (int i = 0; i < oo.length; i++) {
|
||||
Object o = oo[i];
|
||||
if (o instanceof IChatBaseComponent) {
|
||||
@@ -1240,7 +1240,7 @@ public class CraftEventFactory {
|
||||
}
|
||||
}
|
||||
}
|
||||
List<IChatBaseComponent> ls = c.a();
|
||||
List<IChatBaseComponent> ls = c.getSiblings();
|
||||
if (ls != null) {
|
||||
for (int i = 0; i < ls.size(); i++) {
|
||||
ls.set(i, stripEvents(ls.get(i)));
|
||||
|
||||
@@ -19,6 +19,7 @@ import net.minecraft.server.MobSpawnerPhantom;
|
||||
import net.minecraft.server.RegionLimitedWorldAccess;
|
||||
import net.minecraft.server.StructureGenerator;
|
||||
import net.minecraft.server.TileEntity;
|
||||
import net.minecraft.server.VillageSiege;
|
||||
import net.minecraft.server.World;
|
||||
import net.minecraft.server.WorldGenFeatureConfiguration;
|
||||
import net.minecraft.server.WorldGenStage;
|
||||
@@ -39,6 +40,7 @@ public class CustomChunkGenerator extends InternalChunkGenerator<GeneratorSettin
|
||||
private final MobSpawnerPhantom mobSpawnerPhantom = new MobSpawnerPhantom();
|
||||
private final MobSpawnerPatrol mobSpawnerPatrol = new MobSpawnerPatrol();
|
||||
private final MobSpawnerCat mobSpawnerCat = new MobSpawnerCat();
|
||||
private final VillageSiege villageSiege = new VillageSiege();
|
||||
|
||||
private static class CustomBiomeGrid implements BiomeGrid {
|
||||
BiomeBase[] biome;
|
||||
@@ -160,6 +162,7 @@ public class CustomChunkGenerator extends InternalChunkGenerator<GeneratorSettin
|
||||
this.mobSpawnerPhantom.a(worldserver, flag, flag1);
|
||||
this.mobSpawnerPatrol.a(worldserver, flag, flag1);
|
||||
this.mobSpawnerCat.a(worldserver, flag, flag1);
|
||||
this.villageSiege.a(worldserver, flag, flag1);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -29,12 +29,12 @@ public class CraftInventoryAnvil extends CraftResultInventory implements AnvilIn
|
||||
|
||||
@Override
|
||||
public int getRepairCost() {
|
||||
return container.levelCost.b();
|
||||
return container.levelCost.get();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setRepairCost(int i) {
|
||||
container.levelCost.a(i);
|
||||
container.levelCost.set(i);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -94,12 +94,12 @@ public class CraftMerchantCustom extends CraftMerchant {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean eb() {
|
||||
public boolean ea() {
|
||||
return false; // is-regular-villager flag (hides some gui elements: xp bar, name suffix)
|
||||
}
|
||||
|
||||
@Override
|
||||
public SoundEffect ec() {
|
||||
public SoundEffect eb() {
|
||||
return SoundEffects.ENTITY_VILLAGER_YES;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -42,7 +42,7 @@ public class CraftMapRenderer extends MapRenderer {
|
||||
}
|
||||
|
||||
MapIcon decoration = (MapIcon) worldMap.decorations.get(key);
|
||||
cursors.addCursor(decoration.getX(), decoration.getY(), (byte) (decoration.getRotation() & 15), decoration.b().a(), true, CraftChatMessage.fromComponent(decoration.g()));
|
||||
cursors.addCursor(decoration.getX(), decoration.getY(), (byte) (decoration.getRotation() & 15), decoration.getType().a(), true, CraftChatMessage.fromComponent(decoration.getName()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -69,7 +69,7 @@ public class CraftBlockProjectileSource implements BlockProjectileSource {
|
||||
SourceBlock isourceblock = new SourceBlock(dispenserBlock.getWorld(), dispenserBlock.getPosition());
|
||||
// Copied from DispenseBehaviorProjectile
|
||||
IPosition iposition = BlockDispenser.a(isourceblock);
|
||||
EnumDirection enumdirection = (EnumDirection) isourceblock.e().get(BlockDispenser.FACING);
|
||||
EnumDirection enumdirection = (EnumDirection) isourceblock.getBlockData().get(BlockDispenser.FACING);
|
||||
net.minecraft.server.World world = dispenserBlock.getWorld();
|
||||
net.minecraft.server.Entity launch = null;
|
||||
|
||||
|
||||
@@ -210,7 +210,7 @@ public final class CraftChatMessage {
|
||||
ChatModifier modifier = text.getChatModifier() != null ?
|
||||
text.getChatModifier() : new ChatModifier();
|
||||
List<IChatBaseComponent> extras = new ArrayList<IChatBaseComponent>();
|
||||
List<IChatBaseComponent> extrasOld = new ArrayList<IChatBaseComponent>(text.a());
|
||||
List<IChatBaseComponent> extrasOld = new ArrayList<IChatBaseComponent>(text.getSiblings());
|
||||
component = text = new ChatComponentText("");
|
||||
|
||||
int pos = 0;
|
||||
@@ -245,21 +245,21 @@ public final class CraftChatMessage {
|
||||
}
|
||||
}
|
||||
|
||||
List extras = component.a();
|
||||
List<IChatBaseComponent> extras = component.getSiblings();
|
||||
for (int i = 0; i < extras.size(); i++) {
|
||||
IChatBaseComponent comp = (IChatBaseComponent) extras.get(i);
|
||||
if (comp.getChatModifier() != null && comp.getChatModifier().h() == null) {
|
||||
IChatBaseComponent comp = extras.get(i);
|
||||
if (comp.getChatModifier() != null && comp.getChatModifier().getClickEvent() == null) {
|
||||
extras.set(i, fixComponent(comp, matcher));
|
||||
}
|
||||
}
|
||||
|
||||
if (component instanceof ChatMessage) {
|
||||
Object[] subs = ((ChatMessage) component).l();
|
||||
Object[] subs = ((ChatMessage) component).getArgs();
|
||||
for (int i = 0; i < subs.length; i++) {
|
||||
Object comp = subs[i];
|
||||
if (comp instanceof IChatBaseComponent) {
|
||||
IChatBaseComponent c = (IChatBaseComponent) comp;
|
||||
if (c.getChatModifier() != null && c.getChatModifier().h() == null) {
|
||||
if (c.getChatModifier() != null && c.getChatModifier().getClickEvent() == null) {
|
||||
subs[i] = fixComponent(c, matcher);
|
||||
}
|
||||
} else if (comp instanceof String && matcher.reset((String)comp).find()) {
|
||||
|
||||
@@ -188,7 +188,7 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
||||
* @return string
|
||||
*/
|
||||
public String getMappingsVersion() {
|
||||
return "a69acbca3007d2ae1b4b69881f0ab9ad";
|
||||
return "11ae498d9cf909730659b6357e7c2afa";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -21,7 +21,7 @@ public final class CraftNamespacedKey {
|
||||
}
|
||||
|
||||
public static NamespacedKey fromMinecraft(MinecraftKey minecraft) {
|
||||
return new NamespacedKey(minecraft.b(), minecraft.getKey());
|
||||
return new NamespacedKey(minecraft.getNamespace(), minecraft.getKey());
|
||||
}
|
||||
|
||||
public static MinecraftKey toMinecraft(NamespacedKey key) {
|
||||
|
||||
@@ -11,7 +11,6 @@ import net.minecraft.server.ChunkStatus;
|
||||
import net.minecraft.server.DifficultyDamageScaler;
|
||||
import net.minecraft.server.Entity;
|
||||
import net.minecraft.server.EntityHuman;
|
||||
import net.minecraft.server.EnumDirection;
|
||||
import net.minecraft.server.EnumSkyBlock;
|
||||
import net.minecraft.server.Fluid;
|
||||
import net.minecraft.server.FluidType;
|
||||
@@ -83,7 +82,7 @@ public class DummyGeneratorAccess implements GeneratorAccess {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void a(EntityHuman eh, BlockPosition bp, SoundEffect se, SoundCategory sc, float f, float f1) {
|
||||
public void playSound(EntityHuman eh, BlockPosition bp, SoundEffect se, SoundCategory sc, float f, float f1) {
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user