1
0
mirror of https://github.com/Zrips/Jobs.git synced 2025-02-21 14:51:19 +01:00

Fix melon not works on newest and old versions

There was a problem when using the melon_block material on the older version (1.12) for the Break action, it did not detect even if a simple melon was specified. But on the other hand, it worked on the latest (1.15) versions.

So now the correct way is using the legacy_melon_block when using oldest mc versions.
This commit is contained in:
montlikadani 2020-05-31 21:50:40 +02:00
parent 101bd5656f
commit 2608362250
2 changed files with 2 additions and 4 deletions

View File

@ -509,7 +509,7 @@ public enum CMIMaterial {
MAGMA_CREAM(378, 0, 25097, "Magma Cream"),
MAGMA_CUBE_SPAWN_EGG(383, 62, 26638, "Magma Cube Spawn Egg", "Spawn Magma Cube"),
MAP(395, 0, 21655, "Empty Map"),
MELON(103, 0, 25172, "Melon", "Melon_Block"),
MELON(103, 0, 25172, "Melon Block"),
MELON_SEEDS(362, 0, 18340, "Melon Seeds"),
MELON_SLICE(360, 0, 5347, "Melon Slice"),
MELON_STEM(105, 0, 8247, "Melon Stem"),
@ -1018,6 +1018,7 @@ public enum CMIMaterial {
LEGACY_DIODE_BLOCK_OFF(93, 0, null, "Diode Block Off"),
LEGACY_DIODE_BLOCK_ON(94, 0, null, "Diode Block On"),
LEGACY_BREWING_STAND(117, null, null, "LEGACY_BREWING_STAND"),
LEGACY_MELON_BLOCK(103, 0, null, "Melon Block"),
// LEGACY_CAULDRON(118, 0, null, "LEGACY_CAULDRON", ""),
// LEGACY_REDSTONE_LAMP_ON(124, null, null, "LEGACY_REDSTONE_LAMP_ON", ""),

View File

@ -1269,9 +1269,6 @@ public class JobsPaymentListener implements Listener {
return;
List<JobProgression> jobs = jPlayer.getJobProgression();
if (jobs == null)
return;
for (JobProgression job : jobs) {
Jobs.action(jDamager, new CustomKillInfo(job.getJob().getName(), ActionType.CUSTOMKILL), pDamager, lVictim);
}