silphius/app/ecs-components/controlled.js
2024-06-29 07:27:40 -05:00

18 lines
411 B
JavaScript

import Component from '@/ecs/component.js';
export default class Controlled extends Component {
instanceFromSchema() {
return class ControlledInstance extends super.instanceFromSchema() {
toJSON() {
return {};
}
}
}
static properties = {
moveUp: {type: 'float32'},
moveRight: {type: 'float32'},
moveDown: {type: 'float32'},
moveLeft: {type: 'float32'},
};
}