mirror of
https://github.com/DRE2N/DungeonsXL.git
synced 2025-02-17 21:02:12 +01:00
Remove Potion Effects when switching Class
This commit is contained in:
parent
1f80c8bed9
commit
7d9c0b032b
@ -293,6 +293,11 @@ public class DPlayer {
|
|||||||
this.player.getInventory().setArmorContents(null);
|
this.player.getInventory().setArmorContents(null);
|
||||||
player.getInventory().setItemInHand(new ItemStack(0));
|
player.getInventory().setItemInHand(new ItemStack(0));
|
||||||
|
|
||||||
|
// Remove Potion Effects
|
||||||
|
for (PotionEffect effect : this.player.getActivePotionEffects()) {
|
||||||
|
this.player.removePotionEffect(effect.getType());
|
||||||
|
}
|
||||||
|
|
||||||
/* Set Inventory */
|
/* Set Inventory */
|
||||||
for (ItemStack istack : dclass.items) {
|
for (ItemStack istack : dclass.items) {
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user