feat: lootable

This commit is contained in:
cha0s 2022-05-04 14:54:55 -05:00
parent 3b3920a939
commit 72db8b9673

View File

@ -41,6 +41,9 @@ export default () => class Lootable extends decorate(Trait) {
}
emitLoot() {
if (!this.entity.lootable) {
return true;
}
const jsons = this.calculateLoot();
if (0 === jsons.length) {
return true;