This doesn't completely eliminate the issue but it does mitigate it significantly
This commit is contained in:
yrsegal@gmail.com 2022-09-30 20:31:25 -04:00
parent 9d34fcf1b7
commit 44c96f1ee0
3 changed files with 6 additions and 0 deletions

View file

@ -14,6 +14,8 @@ object OpBlockAxisRaycast : ConstManaOperator {
val origin: Vec3 = args.getChecked(0, argc) val origin: Vec3 = args.getChecked(0, argc)
val look: Vec3 = args.getChecked(1, argc) val look: Vec3 = args.getChecked(1, argc)
ctx.assertVecInRange(origin)
val blockHitResult = ctx.world.clip( val blockHitResult = ctx.world.clip(
ClipContext( ClipContext(
origin, origin,

View file

@ -14,6 +14,8 @@ object OpBlockRaycast : ConstManaOperator {
val origin: Vec3 = args.getChecked(0, argc) val origin: Vec3 = args.getChecked(0, argc)
val look: Vec3 = args.getChecked(1, argc) val look: Vec3 = args.getChecked(1, argc)
ctx.assertVecInRange(origin)
val blockHitResult = ctx.world.clip( val blockHitResult = ctx.world.clip(
ClipContext( ClipContext(
origin, origin,

View file

@ -15,6 +15,8 @@ object OpEntityRaycast : ConstManaOperator {
val look: Vec3 = args.getChecked(1, argc) val look: Vec3 = args.getChecked(1, argc)
val endp = Operator.raycastEnd(origin, look) val endp = Operator.raycastEnd(origin, look)
ctx.assertVecInRange(origin)
val entityHitResult = ProjectileUtil.getEntityHitResult( val entityHitResult = ProjectileUtil.getEntityHitResult(
ctx.caster, ctx.caster,
origin, origin,