feat: lootable
This commit is contained in:
parent
3b3920a939
commit
72db8b9673
|
@ -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;
|
||||
|
|
Loading…
Reference in New Issue
Block a user