HumanBreak/public/project/plugin/chase.js
2023-04-29 11:25:18 +08:00

24 lines
596 B
JavaScript

export function chaseInit1() {
const ids = ['MT13', 'MT14', 'MT15'];
const toRemove = [];
ids.forEach(v => {
core.status.maps[v].cannotMoveDirectly = true;
core.extractBlocks(v);
core.status.maps[v].blocks.forEach(vv => {
if (
['animates', 'items'].includes(vv.event.cls) &&
!vv.event.id.endsWith('Portal')
) {
toRemove.push([vv.x, vv.y, v]);
}
});
});
toRemove.forEach(v => {
core.removeBlock(...v);
});
}
core.plugin.chase = {
chaseInit1
};