Skip to content

Enhanced Loot Table support #2423

@ejm

Description

@ejm

Major SpongeAPI version

8

Is this likely to be a breaking change?

Yes

What are you requesting?

Currently, Sponge supports some concept of Loot tables through the LootTable class and related weighted table utility classes, but there's (seemingly) no way to get the loot table of an entity or block entity nor is there any way to set a custom loot table for an entity with the Data API.

Other mod APIs support such operations, such as the Bukkit (Spigot?) API and Forge API, notably using the concept of a LootContext which contains data used by the Vanilla server to calculate drops (the amount of luck the roller has, etc.).

It would be helpful to have such API support in Sponge for use in minigames and utility plugins like "mob stackers." Chances are, this would require changes to the existing weighted table classes to support a LootContext-like object, so this change would likely be breaking.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: needs triageThis label is automatically applied to new issues and pull requests to indicate they require triage

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions