58 lines
No EOL
935 B
JavaScript
58 lines
No EOL
935 B
JavaScript
const itemBlacklist = [
|
|
// "minecraft:stone"
|
|
]
|
|
|
|
ServerEvents.recipes(event => {
|
|
for (let item of itemBlacklist) {
|
|
event.remove({ output: item })
|
|
}
|
|
})
|
|
|
|
ItemEvents.rightClicked(event => {
|
|
for (let item of itemBlacklist) {
|
|
if (event.item.id == item) {
|
|
event.cancel()
|
|
}
|
|
}
|
|
})
|
|
|
|
ItemEvents.pickedUp(event => {
|
|
for (let item of itemBlacklist) {
|
|
if (event.item.id == item) {
|
|
event.cancel()
|
|
}
|
|
}
|
|
})
|
|
|
|
ItemEvents.dropped(event => {
|
|
for (let item of itemBlacklist) {
|
|
if (event.item.id == item) {
|
|
event.cancel()
|
|
}
|
|
}
|
|
})
|
|
|
|
// Block events
|
|
BlockEvents.broken(event => {
|
|
for (let item of itemBlacklist) {
|
|
if (event.block.id == item) {
|
|
event.cancel()
|
|
}
|
|
}
|
|
})
|
|
|
|
BlockEvents.placed(event => {
|
|
for (let item of itemBlacklist) {
|
|
if (event.block.id == item) {
|
|
event.cancel()
|
|
}
|
|
}
|
|
})
|
|
|
|
BlockEvents.rightClicked(event => {
|
|
for (let item of itemBlacklist) {
|
|
if (event.block.id == item) {
|
|
event.cancel()
|
|
}
|
|
}
|
|
}) |