fixed bug that prevented plants from resetting age
This commit is contained in:
parent
6ac6455f2d
commit
d9cfdb218e
@ -36,9 +36,12 @@ public class replanting {
|
|||||||
target.getLocation().getWorld().dropItem(loc, new ItemStack(item[0]));
|
target.getLocation().getWorld().dropItem(loc, new ItemStack(item[0]));
|
||||||
}
|
}
|
||||||
|
|
||||||
for(int i = 0; i < amount[1]; i++) {
|
if (amount.length > 1) {
|
||||||
target.getLocation().getWorld().dropItem(loc, new ItemStack(item[1]));
|
for (int i = 0; i < amount[1]; i++) {
|
||||||
|
target.getLocation().getWorld().dropItem(loc, new ItemStack(item[1]));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
crop.setAge(0);
|
crop.setAge(0);
|
||||||
target.setBlockData(crop);
|
target.setBlockData(crop);
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
package de.steev.bm.Listener;
|
package de.steev.bm.Listener;
|
||||||
|
|
||||||
import de.steev.bm.BetterMinecraft;
|
|
||||||
import de.steev.bm.Manager.GameManager;
|
import de.steev.bm.Manager.GameManager;
|
||||||
import org.bukkit.Bukkit;
|
import org.bukkit.Bukkit;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
@ -49,5 +48,4 @@ public class BedListener implements Listener {
|
|||||||
this.gameManager.getPlugin().playerInBed = 0;
|
this.gameManager.getPlugin().playerInBed = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user