mirror of
https://github.com/SparklyPower/SparklyPaper.git
synced 2025-12-21 07:59:31 +00:00
Useful if you want to actually control what the player is moving, because VehicleMoveEvent does not let you cancel nor change the location. Also useful to detect BoatFly hacks.
62 lines
2.6 KiB
Diff
62 lines
2.6 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: MrPowerGamerBR <git@mrpowergamerbr.com>
|
|
Date: Wed, 12 Jun 2024 11:53:27 -0300
|
|
Subject: [PATCH] SPARKLYPOWER Add custom blocks
|
|
|
|
|
|
diff --git a/src/main/java/com/destroystokyo/paper/MaterialTags.java b/src/main/java/com/destroystokyo/paper/MaterialTags.java
|
|
index 41eaa8159f8c028faa118300e95f6a0fb9cfe989..5b5ddb19b39d5201da422f9b10e2491ab9334925 100644
|
|
--- a/src/main/java/com/destroystokyo/paper/MaterialTags.java
|
|
+++ b/src/main/java/com/destroystokyo/paper/MaterialTags.java
|
|
@@ -83,6 +83,7 @@ public class MaterialTags {
|
|
*/
|
|
public static final MaterialSetTag CONCRETES = new MaterialSetTag(keyFor("concretes"))
|
|
.endsWith("_CONCRETE")
|
|
+ .notStartsWith("SPARKLYPOWER_") // SparklyPaper - custom blocks
|
|
.ensureSize("CONCRETES", 16).lock();
|
|
|
|
/**
|
|
@@ -161,6 +162,7 @@ public class MaterialTags {
|
|
.endsWith("TERRACOTTA")
|
|
.not(Material.TERRACOTTA)
|
|
.notEndsWith("GLAZED_TERRACOTTA")
|
|
+ .notStartsWith("SPARKLYPOWER_") // SparklyPaper - custom blocks
|
|
.ensureSize("STAINED_TERRACOTTA", 16).lock();
|
|
|
|
/**
|
|
@@ -168,6 +170,7 @@ public class MaterialTags {
|
|
*/
|
|
public static final MaterialSetTag TERRACOTTA = new MaterialSetTag(keyFor("terracotta"))
|
|
.endsWith("TERRACOTTA")
|
|
+ .notStartsWith("SPARKLYPOWER_") // SparklyPaper - custom blocks
|
|
.ensureSize("TERRACOTTA", 33).lock();
|
|
|
|
/**
|
|
diff --git a/src/main/java/org/bukkit/Material.java b/src/main/java/org/bukkit/Material.java
|
|
index 028ac35df6c4d044d07b3869751736d418c1eb0e..dd9795e0725275b0fe5a3f4ecfd4d587a23f963f 100644
|
|
--- a/src/main/java/org/bukkit/Material.java
|
|
+++ b/src/main/java/org/bukkit/Material.java
|
|
@@ -3843,6 +3843,22 @@ public enum Material implements Keyed, Translatable, net.kyori.adventure.transla
|
|
BIG_DRIPLEAF_STEM(13167, Dripleaf.class),
|
|
POTTED_AZALEA_BUSH(20430),
|
|
POTTED_FLOWERING_AZALEA_BUSH(10609),
|
|
+ // SparklyPaper start - SparklyPower Survival custom blocks
|
|
+ // The IDs themselves doesn't have any correlation with anything, Spigot invented that for backwards compatibility
|
|
+ SPARKLYPOWER_RAINBOW_WOOL(13003),
|
|
+ SPARKLYPOWER_RAINBOW_CONCRETE(13004),
|
|
+ SPARKLYPOWER_RAINBOW_TERRACOTTA(13005),
|
|
+ SPARKLYPOWER_ASPHALT_SERVER(13006),
|
|
+ /**
|
|
+ * BlockData: {@link Slab}
|
|
+ */
|
|
+ SPARKLYPOWER_ASPHALT_SERVER_SLAB(13007, Slab.class),
|
|
+ SPARKLYPOWER_ASPHALT_PLAYER(13008),
|
|
+ /**
|
|
+ * BlockData: {@link Slab}
|
|
+ */
|
|
+ SPARKLYPOWER_ASPHALT_PLAYER_SLAB(13009, Slab.class),
|
|
+ // SparklyPaper end
|
|
// ----- Legacy Separator -----
|
|
@Deprecated(since = "1.13")
|
|
LEGACY_AIR(0, 0),
|