chore: tidy
This commit is contained in:
parent
1a8cefd325
commit
6ff824ace6
|
@ -3,8 +3,7 @@ import Component from '@/ecs/component.js';
|
||||||
export default class Wielder extends Component {
|
export default class Wielder extends Component {
|
||||||
instanceFromSchema() {
|
instanceFromSchema() {
|
||||||
const {ecs} = this;
|
const {ecs} = this;
|
||||||
const Instance = super.instanceFromSchema();
|
return class WielderInstance extends super.instanceFromSchema() {
|
||||||
return class WielderInstance extends Instance {
|
|
||||||
activeItem() {
|
activeItem() {
|
||||||
const {Inventory, Wielder} = ecs.get(this.entity);
|
const {Inventory, Wielder} = ecs.get(this.entity);
|
||||||
return Inventory.item(Wielder.activeSlot + 1);
|
return Inventory.item(Wielder.activeSlot + 1);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user