Hi there,
I have been trying to set up a system to determine where a projectile is going to land right as it is shot (using raytracing), the problem is I have no idea how to or if it is even possible. I need the ray trace to account for the projectile drop (normal vanilla projectile drop, nothing special) and whatnot, but I do not know how to do that. Or if that is possible in the first place.
I was hoping that something like this would work:
{_Projectile}.getWorld().rayTraceBlocks({_Projectile}.getLocation(), vector of {_Projectile}, 300F, 3F, FluidCollisionMode.ALWAYS, false).getHitBlock()
But obviously, it doesn't. It just gives me none.
If someone could help me figure this out that would be greatly appreciated!
Cheers,
- Orbinfog
I have been trying to set up a system to determine where a projectile is going to land right as it is shot (using raytracing), the problem is I have no idea how to or if it is even possible. I need the ray trace to account for the projectile drop (normal vanilla projectile drop, nothing special) and whatnot, but I do not know how to do that. Or if that is possible in the first place.
I was hoping that something like this would work:
{_Projectile}.getWorld().rayTraceBlocks({_Projectile}.getLocation(), vector of {_Projectile}, 300F, 3F, FluidCollisionMode.ALWAYS, false).getHitBlock()
But obviously, it doesn't. It just gives me none.
If someone could help me figure this out that would be greatly appreciated!
Cheers,
- Orbinfog