Posted June 25, 20223 yr Is it possible to make a block that monsters will be able to see through? Ideally a monster would be able to target a player on the other side of this block and then pathfind directly through it rather than around.
June 25, 20223 yr Author They don't try to walk through them, though. Trapdoors are the opposite situation: mobs treat them as full blocks when they're not, whereas I want mobs to treat my blocks as though they're not there. Simply overriding isPathfindable() isn't sufficient for my situation.
June 25, 20223 yr Author The trick is making the block be of a material that's nonSolid(). Because you unfortunately can't make your own materials, I'm using Materials.PORTAL and then overriding the block's getCollisionShape() method so it remains collidable.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.