This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public static Closeable smoothInterrupt(Plugin plugin, BiConsumer<Player, Block> interruptions) { | |
| final Map<Player, BukkitTask> tasks = new HashMap<>(); | |
| PacketAdapter adapter = new PacketAdapter(plugin, BLOCK_DIG) { | |
| @Override | |
| public void onPacketReceiving(PacketEvent event) { | |
| Player player = event.getPlayer(); | |
| Block block = event.getPacket() | |
| .getBlockPositionModifier().read(0) | |
| .toLocation(player.getWorld()).getBlock(); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public static Closeable smoothInterrupt(Plugin plugin, Predicate<Block> blocks, Consumer<Block> interruptions) { | |
| return smoothInterrupt(plugin, blocks, (player, block) -> interruptions.accept(block)); | |
| } | |
| public static Closeable smoothInterrupt(Plugin plugin, Predicate<Block> blocks, BiConsumer<Player, Block> interruptions) { | |
| return smoothInterrupt(plugin, (player, block) -> blocks.test(block), interruptions); | |
| } | |
| public static Closeable smoothInterrupt(Plugin plugin, BiPredicate<Player, Block> blocks, Consumer<Block> interruptions) { | |
| return smoothInterrupt(plugin, blocks, (player, block) -> interruptions.accept(block)); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public static class Particle { | |
| private final String id; | |
| private int count = 0; | |
| private float data, x, y, z = 0; | |
| public Particle(String id) { | |
| this.id = id; | |
| } | |
| public static Particle create(String id) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public static class Particle { | |
| private final String id; | |
| private int count = 0; | |
| private float data, x, y, z = 0; | |
| public Particle(String id) { | |
| this.id = id; | |
| } | |
| public static Particle create(String id) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.penzzly.engine.core.mini; | |
| import org.bukkit.Material; | |
| import org.bukkit.entity.Player; | |
| import org.bukkit.event.EventHandler; | |
| import org.bukkit.event.Listener; | |
| import org.bukkit.event.inventory.ClickType; | |
| import org.bukkit.event.inventory.InventoryClickEvent; | |
| import org.bukkit.event.inventory.InventoryCloseEvent; | |
| import org.bukkit.event.inventory.InventoryOpenEvent; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| group = "com.mynt.test" | |
| version = "1.0-SNAPSHOT" | |
| buildscript { | |
| repositories { | |
| mavenCentral() | |
| } | |
| dependencies { | |
| classpath(kotlinModule("gradle-plugin", "1.2.21")) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| group = "com.mynt.test" | |
| version = "1.0-SNAPSHOT" | |
| buildscript { | |
| repositories { | |
| mavenCentral() | |
| } | |
| dependencies { | |
| classpath(kotlinModule("gradle-plugin", "1.2.21")) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.penzzly.engine.architecture.base; | |
| import org.jetbrains.annotations.NotNull; | |
| import java.util.ArrayList; | |
| import java.util.List; | |
| import java.util.Set; | |
| import static java.util.Arrays.asList; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| interface Buffer { | |
| fun clear(): Buffer | |
| fun flip(): Buffer | |
| fun index(): Long | |
| //Read a number of bits(or 8) from a value as a Number at the current index. | |
| fun <Type : Number> next(bits: Number = 8): Type |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ${project.name} | |
| version: ${project.version} | |
| #Might need to change this depending on your package structure, but it's standard not to. | |
| main: ${project.groupId}.${project.artifactId} |