Interface DestructEntityEvent.Death

    • Method Detail

      • setKeepInventory

        void setKeepInventory​(boolean keepInventory)
        Applies the GameRules.KEEP_INVENTORY gamerule to this entity alone.

        This only works for players

        Parameters:
        keepInventory - Whether to keep the inventory on death
      • keepInventory

        boolean keepInventory()
        Returns whether the inventory is kept after death.

        By default this is the same as the GameRules.KEEP_INVENTORY gamerule.

        Returns:
        Whether the inventory is kept after death.