Skip to content

Commit 8a6b26b

Browse files
committed
fix
1 parent da5cba7 commit 8a6b26b

1 file changed

Lines changed: 3 additions & 5 deletions

File tree

src/lib/region/index.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ import {
88
world,
99
} from '@minecraft/server'
1010
import { MinecraftEntityTypes, MinecraftItemTypes } from '@minecraft/vanilla-data'
11+
import { CustomEntityTypes } from 'lib/assets/custom-entity-types'
12+
import { Items } from 'lib/assets/custom-items'
1113
import { PlayerEvents, PlayerProperties } from 'lib/assets/player-json'
1214
import { ActionbarPriority } from 'lib/extensions/on-screen-display'
1315
import { i18n, noI18n } from 'lib/i18n/text'
@@ -68,7 +70,6 @@ export enum ActionGuardOrder {
6870
// Limits
6971
Permission = 7,
7072
Lowest = 6,
71-
DefaultAllowAll = 5,
7273
}
7374

7475
export const regionTypesThatIgnoreIsBuildingGuard: (typeof Region)[] = []
@@ -107,14 +108,11 @@ actionGuard((player, region, context) => {
107108
if (typeId === MinecraftItemTypes.EnderPearl) return ent.includes(MinecraftEntityTypes.EnderPearl)
108109
if (typeId === MinecraftItemTypes.WindCharge) return ent.includes(MinecraftEntityTypes.WindChargeProjectile)
109110
if (typeId === MinecraftItemTypes.Snowball) return ent.includes(MinecraftEntityTypes.Snowball)
111+
if (typeId === Items.Fireball) return ent.includes(CustomEntityTypes.Fireball)
110112
}
111113
}
112114
}, ActionGuardOrder.ProjectileUsePrevent)
113115

114-
actionGuard(() => {
115-
return true
116-
}, ActionGuardOrder.DefaultAllowAll)
117-
118116
const permdebugLogger = createLogger('region-perm')
119117

120118
const allowed: InteractionAllowed = (player, region, context, regions) => {

0 commit comments

Comments
 (0)