mirror of
https://github.com/songoda/SongodaCore.git
synced 2024-11-23 18:45:34 +01:00
Merge branch 'development'
This commit is contained in:
commit
24fc39ab16
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../pom.xml</relativePath>
|
<relativePath>../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -1,5 +1,9 @@
|
|||||||
package com.songoda.core.compatibility;
|
package com.songoda.core.compatibility;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @deprecated Usage is highly discouraged – use NMSManager instead
|
||||||
|
*/
|
||||||
|
@Deprecated
|
||||||
public enum ClassMapping {
|
public enum ClassMapping {
|
||||||
BIOME_BASE("world.level.biome", "BiomeBase"),
|
BIOME_BASE("world.level.biome", "BiomeBase"),
|
||||||
BIOME_STORAGE("world.level.chunk", "BiomeStorage"),
|
BIOME_STORAGE("world.level.chunk", "BiomeStorage"),
|
||||||
|
@ -32,6 +32,12 @@ public enum CompatibleMaterial {
|
|||||||
DARK_OAK_DOOR_ITEM(431),
|
DARK_OAK_DOOR_ITEM(431),
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/* 1.19.3 */
|
||||||
|
ENDER_DRAGON_SPAWN_EGG(),
|
||||||
|
IRON_GOLEM_SPAWN_EGG(),
|
||||||
|
SNOW_GOLEM_SPAWN_EGG(),
|
||||||
|
WITHER_SPAWN_EGG(),
|
||||||
|
|
||||||
/* 1.19 */
|
/* 1.19 */
|
||||||
ACACIA_CHEST_BOAT(),
|
ACACIA_CHEST_BOAT(),
|
||||||
ALLAY_SPAWN_EGG(),
|
ALLAY_SPAWN_EGG(),
|
||||||
|
@ -5,6 +5,10 @@ import org.bukkit.inventory.ItemStack;
|
|||||||
|
|
||||||
import java.lang.reflect.Method;
|
import java.lang.reflect.Method;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @deprecated Usage is highly discouraged – use NMSManager instead
|
||||||
|
*/
|
||||||
|
@Deprecated
|
||||||
public enum MethodMapping {
|
public enum MethodMapping {
|
||||||
MC_ITEM_STACK__GET_TAG("getTag", "getTag", "s", "t", "u"),
|
MC_ITEM_STACK__GET_TAG("getTag", "getTag", "s", "t", "u"),
|
||||||
MC_ITEM_STACK__SET_TAG("setTag", "setTag", "c", "c", "c", ClassMapping.NBT_TAG_COMPOUND.getClazz()),
|
MC_ITEM_STACK__SET_TAG("setTag", "setTag", "c", "c", "c", ClassMapping.NBT_TAG_COMPOUND.getClazz()),
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../pom.xml</relativePath>
|
<relativePath>../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -55,7 +55,7 @@ public class SongodaCore {
|
|||||||
/**
|
/**
|
||||||
* @since coreRevision 6
|
* @since coreRevision 6
|
||||||
*/
|
*/
|
||||||
private final static String coreVersion = "2.6.19";
|
private final static String coreVersion = "2.6.20";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This is specific to the website api
|
* This is specific to the website api
|
||||||
|
@ -4,6 +4,7 @@ import com.songoda.core.compatibility.ClassMapping;
|
|||||||
import com.songoda.core.compatibility.CompatibleMaterial;
|
import com.songoda.core.compatibility.CompatibleMaterial;
|
||||||
import com.songoda.core.compatibility.MethodMapping;
|
import com.songoda.core.compatibility.MethodMapping;
|
||||||
import com.songoda.core.compatibility.ServerVersion;
|
import com.songoda.core.compatibility.ServerVersion;
|
||||||
|
import com.songoda.core.nms.NmsManager;
|
||||||
import org.bukkit.Effect;
|
import org.bukkit.Effect;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
@ -19,6 +20,10 @@ import java.util.Set;
|
|||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @deprecated This class will be removed in the future and replaced with a more maintainable system.
|
||||||
|
*/
|
||||||
|
@Deprecated
|
||||||
public class BlockUtils {
|
public class BlockUtils {
|
||||||
protected static final Set<Material> DOORS;
|
protected static final Set<Material> DOORS;
|
||||||
protected static final Set<Material> PRESSURE_PLATES;
|
protected static final Set<Material> PRESSURE_PLATES;
|
||||||
@ -337,7 +342,10 @@ public class BlockUtils {
|
|||||||
* Manually trigger the updateAdjacentComparators method for containers
|
* Manually trigger the updateAdjacentComparators method for containers
|
||||||
*
|
*
|
||||||
* @param loc The Location of the container
|
* @param loc The Location of the container
|
||||||
|
*
|
||||||
|
* @deprecated Broken in/since Spigot 1.19.4! Use {@link com.songoda.core.nms.world.WorldCore#updateAdjacentComparators(Block)} on {@link NmsManager#getWorld()} instead
|
||||||
*/
|
*/
|
||||||
|
@Deprecated
|
||||||
public static void updateAdjacentComparators(Location loc) {
|
public static void updateAdjacentComparators(Location loc) {
|
||||||
if (loc == null || loc.getWorld() == null) {
|
if (loc == null || loc.getWorld() == null) {
|
||||||
return;
|
return;
|
||||||
|
@ -22,6 +22,10 @@ import java.lang.reflect.Method;
|
|||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @deprecated This class will be removed in the future and replaced with a more maintainable system.
|
||||||
|
*/
|
||||||
|
@Deprecated
|
||||||
public class BlockUtilsModern {
|
public class BlockUtilsModern {
|
||||||
protected static void _updatePressurePlateModern(Block plate, int power) {
|
protected static void _updatePressurePlateModern(Block plate, int power) {
|
||||||
BlockData blockData = plate.getBlockData();
|
BlockData blockData = plate.getBlockData();
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -3,12 +3,11 @@ package com.songoda.core.nms.world;
|
|||||||
import org.bukkit.Chunk;
|
import org.bukkit.Chunk;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.BlockState;
|
import org.bukkit.block.BlockState;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
import java.lang.reflect.InvocationTargetException;
|
|
||||||
|
|
||||||
public interface WorldCore {
|
public interface WorldCore {
|
||||||
SSpawner getSpawner(CreatureSpawner spawner);
|
SSpawner getSpawner(CreatureSpawner spawner);
|
||||||
|
|
||||||
@ -30,6 +29,8 @@ public interface WorldCore {
|
|||||||
*/
|
*/
|
||||||
void randomTickChunk(Chunk bukkitChunk, int tickAmount) throws ReflectiveOperationException;
|
void randomTickChunk(Chunk bukkitChunk, int tickAmount) throws ReflectiveOperationException;
|
||||||
|
|
||||||
|
void updateAdjacentComparators(Block bukkitBlock);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Ticks all inactive spawners in a specific chunk ignoring the minimum required players within a specific range.<br>
|
* Ticks all inactive spawners in a specific chunk ignoring the minimum required players within a specific range.<br>
|
||||||
* A spawner is deemed inactive if no player is within its activation range.
|
* A spawner is deemed inactive if no player is within its activation range.
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,6 +18,8 @@ import org.bukkit.Location;
|
|||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_10_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_10_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_10_R1.block.CraftBlock;
|
||||||
|
import org.bukkit.craftbukkit.v1_10_R1.util.CraftMagicNumbers;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -85,4 +87,14 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(org.bukkit.block.Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
net.minecraft.server.v1_10_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
|
||||||
|
BlockPosition blockPosition = new BlockPosition(craftBlock.getX(), craftBlock.getY(), craftBlock.getZ());
|
||||||
|
nmsWorld.updateAdjacentComparators(blockPosition, CraftMagicNumbers.getBlock(craftBlock));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,6 +18,8 @@ import org.bukkit.Location;
|
|||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_11_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_11_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_11_R1.block.CraftBlock;
|
||||||
|
import org.bukkit.craftbukkit.v1_11_R1.util.CraftMagicNumbers;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -85,4 +87,14 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(org.bukkit.block.Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
net.minecraft.server.v1_11_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
|
||||||
|
BlockPosition blockPosition = new BlockPosition(craftBlock.getX(), craftBlock.getY(), craftBlock.getZ());
|
||||||
|
nmsWorld.updateAdjacentComparators(blockPosition, CraftMagicNumbers.getBlock(craftBlock));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,6 +18,8 @@ import org.bukkit.Location;
|
|||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_12_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_12_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_12_R1.block.CraftBlock;
|
||||||
|
import org.bukkit.craftbukkit.v1_12_R1.util.CraftMagicNumbers;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -85,4 +87,14 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(org.bukkit.block.Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
net.minecraft.server.v1_12_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
|
||||||
|
BlockPosition blockPosition = new BlockPosition(craftBlock.getX(), craftBlock.getY(), craftBlock.getZ());
|
||||||
|
nmsWorld.updateAdjacentComparators(blockPosition, CraftMagicNumbers.getBlock(craftBlock));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -16,8 +16,10 @@ import net.minecraft.server.v1_13_R1.MobSpawnerAbstract;
|
|||||||
import net.minecraft.server.v1_13_R1.WorldServer;
|
import net.minecraft.server.v1_13_R1.WorldServer;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_13_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_13_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_13_R1.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -89,4 +91,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
net.minecraft.server.v1_13_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
nmsWorld.updateAdjacentComparators(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -16,8 +16,10 @@ import net.minecraft.server.v1_13_R2.MobSpawnerAbstract;
|
|||||||
import net.minecraft.server.v1_13_R2.WorldServer;
|
import net.minecraft.server.v1_13_R2.WorldServer;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_13_R2.CraftChunk;
|
import org.bukkit.craftbukkit.v1_13_R2.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_13_R2.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -96,4 +98,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
chunk.world.methodProfiler.exit();
|
chunk.world.methodProfiler.exit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
net.minecraft.server.v1_13_R2.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
nmsWorld.updateAdjacentComparators(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.server.v1_14_R1.MobSpawnerAbstract;
|
|||||||
import net.minecraft.server.v1_14_R1.WorldServer;
|
import net.minecraft.server.v1_14_R1.WorldServer;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_14_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_14_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_14_R1.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -93,4 +95,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
profiler.exit();
|
profiler.exit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
net.minecraft.server.v1_14_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
nmsWorld.updateAdjacentComparators(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.server.v1_15_R1.MobSpawnerAbstract;
|
|||||||
import net.minecraft.server.v1_15_R1.WorldServer;
|
import net.minecraft.server.v1_15_R1.WorldServer;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_15_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_15_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_15_R1.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -96,4 +98,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
profiler.exit();
|
profiler.exit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
net.minecraft.server.v1_15_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
nmsWorld.updateAdjacentComparators(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.server.v1_16_R1.MobSpawnerAbstract;
|
|||||||
import net.minecraft.server.v1_16_R1.WorldServer;
|
import net.minecraft.server.v1_16_R1.WorldServer;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_16_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_16_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_16_R1.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -97,4 +99,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
profiler.exit();
|
profiler.exit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
net.minecraft.server.v1_16_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
nmsWorld.updateAdjacentComparators(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.server.v1_16_R2.MobSpawnerAbstract;
|
|||||||
import net.minecraft.server.v1_16_R2.WorldServer;
|
import net.minecraft.server.v1_16_R2.WorldServer;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_16_R2.CraftChunk;
|
import org.bukkit.craftbukkit.v1_16_R2.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_16_R2.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -97,4 +99,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
profiler.exit();
|
profiler.exit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
net.minecraft.server.v1_16_R2.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
nmsWorld.updateAdjacentComparators(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.server.v1_16_R3.MobSpawnerAbstract;
|
|||||||
import net.minecraft.server.v1_16_R3.WorldServer;
|
import net.minecraft.server.v1_16_R3.WorldServer;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_16_R3.CraftChunk;
|
import org.bukkit.craftbukkit.v1_16_R3.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_16_R3.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -98,4 +100,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
profiler.exit();
|
profiler.exit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
net.minecraft.server.v1_16_R3.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
nmsWorld.updateAdjacentComparators(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.world.level.chunk.ChunkSection;
|
|||||||
import net.minecraft.world.level.material.Fluid;
|
import net.minecraft.world.level.material.Fluid;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_17_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_17_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_17_R1.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -96,4 +98,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
profiler.exit();
|
profiler.exit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
net.minecraft.world.level.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
nmsWorld.updateAdjacentComparators(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -19,7 +19,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.world.level.chunk.ChunkSection;
|
|||||||
import net.minecraft.world.level.material.Fluid;
|
import net.minecraft.world.level.material.Fluid;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_18_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_18_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_18_R1.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -93,4 +95,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
gameprofilerfiller.c();
|
gameprofilerfiller.c();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
WorldServer nmsWorld = craftChunk.getHandle().q;
|
||||||
|
nmsWorld.c(craftBlock.getPosition(), craftBlock.getNMS().b());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -60,7 +60,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.world.level.chunk.LevelChunkSection;
|
|||||||
import net.minecraft.world.level.material.FluidState;
|
import net.minecraft.world.level.material.FluidState;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_18_R2.CraftChunk;
|
import org.bukkit.craftbukkit.v1_18_R2.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_18_R2.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -92,4 +94,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
|
|
||||||
gameProfilerFiller.pop();
|
gameProfilerFiller.pop();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
ServerLevel nmsWorld = craftChunk.getHandle().q;
|
||||||
|
nmsWorld.updateNeighbourForOutputSignal(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -60,7 +60,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.world.level.chunk.LevelChunkSection;
|
|||||||
import net.minecraft.world.level.material.FluidState;
|
import net.minecraft.world.level.material.FluidState;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_19_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_19_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_19_R1.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -90,4 +92,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
ServerLevel nmsWorld = craftChunk.getHandle().q;
|
||||||
|
nmsWorld.updateNeighbourForOutputSignal(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -60,7 +60,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.world.level.chunk.LevelChunkSection;
|
|||||||
import net.minecraft.world.level.material.FluidState;
|
import net.minecraft.world.level.material.FluidState;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_19_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_19_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_19_R1.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -90,4 +92,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
ServerLevel nmsWorld = craftChunk.getHandle().q;
|
||||||
|
nmsWorld.updateNeighbourForOutputSignal(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -60,7 +60,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,8 +18,10 @@ import net.minecraft.world.level.chunk.LevelChunkSection;
|
|||||||
import net.minecraft.world.level.material.FluidState;
|
import net.minecraft.world.level.material.FluidState;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_19_R2.CraftChunk;
|
import org.bukkit.craftbukkit.v1_19_R2.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_19_R2.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -90,4 +92,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
|
||||||
|
ServerLevel nmsWorld = craftChunk.getHandle().q;
|
||||||
|
nmsWorld.updateNeighbourForOutputSignal(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -60,7 +60,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -19,8 +19,10 @@ import net.minecraft.world.level.chunk.LevelChunkSection;
|
|||||||
import net.minecraft.world.level.material.FluidState;
|
import net.minecraft.world.level.material.FluidState;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
|
import org.bukkit.block.Block;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_19_R3.CraftChunk;
|
import org.bukkit.craftbukkit.v1_19_R3.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_19_R3.block.CraftBlock;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -91,4 +93,13 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
LevelChunk nmsChunk = (LevelChunk) craftChunk.getHandle(ChunkStatus.FULL);
|
||||||
|
|
||||||
|
nmsChunk.q.updateNeighbourForOutputSignal(craftBlock.getPosition(), craftBlock.getNMS().getBlock());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,6 +18,8 @@ import org.bukkit.Location;
|
|||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_8_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_8_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_8_R1.block.CraftBlock;
|
||||||
|
import org.bukkit.craftbukkit.v1_8_R1.util.CraftMagicNumbers;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -87,4 +89,14 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(org.bukkit.block.Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
net.minecraft.server.v1_8_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
|
||||||
|
BlockPosition blockPosition = new BlockPosition(craftBlock.getX(), craftBlock.getY(), craftBlock.getZ());
|
||||||
|
nmsWorld.updateAdjacentComparators(blockPosition, CraftMagicNumbers.getBlock(craftBlock));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,6 +18,8 @@ import org.bukkit.Location;
|
|||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_8_R2.CraftChunk;
|
import org.bukkit.craftbukkit.v1_8_R2.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_8_R2.block.CraftBlock;
|
||||||
|
import org.bukkit.craftbukkit.v1_8_R2.util.CraftMagicNumbers;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -87,4 +89,14 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(org.bukkit.block.Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
net.minecraft.server.v1_8_R2.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
|
||||||
|
BlockPosition blockPosition = new BlockPosition(craftBlock.getX(), craftBlock.getY(), craftBlock.getZ());
|
||||||
|
nmsWorld.updateAdjacentComparators(blockPosition, CraftMagicNumbers.getBlock(craftBlock));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,6 +18,8 @@ import org.bukkit.Location;
|
|||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_8_R3.CraftChunk;
|
import org.bukkit.craftbukkit.v1_8_R3.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_8_R3.block.CraftBlock;
|
||||||
|
import org.bukkit.craftbukkit.v1_8_R3.util.CraftMagicNumbers;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -86,4 +88,14 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(org.bukkit.block.Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
net.minecraft.server.v1_8_R3.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
|
||||||
|
BlockPosition blockPosition = new BlockPosition(craftBlock.getX(), craftBlock.getY(), craftBlock.getZ());
|
||||||
|
nmsWorld.updateAdjacentComparators(blockPosition, CraftMagicNumbers.getBlock(craftBlock));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,6 +18,8 @@ import org.bukkit.Location;
|
|||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_9_R1.CraftChunk;
|
import org.bukkit.craftbukkit.v1_9_R1.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_9_R1.block.CraftBlock;
|
||||||
|
import org.bukkit.craftbukkit.v1_9_R1.util.CraftMagicNumbers;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -86,4 +88,14 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(org.bukkit.block.Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
net.minecraft.server.v1_9_R1.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
|
||||||
|
BlockPosition blockPosition = new BlockPosition(craftBlock.getX(), craftBlock.getY(), craftBlock.getZ());
|
||||||
|
nmsWorld.updateAdjacentComparators(blockPosition, CraftMagicNumbers.getBlock(craftBlock));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
@ -18,6 +18,8 @@ import org.bukkit.Location;
|
|||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.block.CreatureSpawner;
|
import org.bukkit.block.CreatureSpawner;
|
||||||
import org.bukkit.craftbukkit.v1_9_R2.CraftChunk;
|
import org.bukkit.craftbukkit.v1_9_R2.CraftChunk;
|
||||||
|
import org.bukkit.craftbukkit.v1_9_R2.block.CraftBlock;
|
||||||
|
import org.bukkit.craftbukkit.v1_9_R2.util.CraftMagicNumbers;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
public class WorldCoreImpl implements WorldCore {
|
public class WorldCoreImpl implements WorldCore {
|
||||||
@ -85,4 +87,14 @@ public class WorldCoreImpl implements WorldCore {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAdjacentComparators(org.bukkit.block.Block bukkitBlock) {
|
||||||
|
CraftBlock craftBlock = (CraftBlock) bukkitBlock;
|
||||||
|
CraftChunk craftChunk = (CraftChunk) bukkitBlock.getChunk();
|
||||||
|
net.minecraft.server.v1_9_R2.World nmsWorld = craftChunk.getHandle().getWorld();
|
||||||
|
|
||||||
|
BlockPosition blockPosition = new BlockPosition(craftBlock.getX(), craftBlock.getY(), craftBlock.getZ());
|
||||||
|
nmsWorld.updateAdjacentComparators(blockPosition, CraftMagicNumbers.getBlock(craftBlock));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
2
pom.xml
2
pom.xml
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>com.songoda</groupId>
|
<groupId>com.songoda</groupId>
|
||||||
<artifactId>SongodaCore-Modules</artifactId>
|
<artifactId>SongodaCore-Modules</artifactId>
|
||||||
<version>2.6.19</version>
|
<version>2.6.20</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
<!-- Run 'mvn versions:set -DgenerateBackupPoms=false -DnewVersion=X.Y.Z' to update version recursively -->
|
<!-- Run 'mvn versions:set -DgenerateBackupPoms=false -DnewVersion=X.Y.Z' to update version recursively -->
|
||||||
|
Loading…
Reference in New Issue
Block a user