Disable entity collision

Started by Rotmax on

Topic category: Help with modding (Java Edition)

Last seen on 09:51, 9. Feb 2024
Joined Nov 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Disable entity collision

I want to make an entity which can't move. So i deleted the Mob Ai (Walking) and i figured out that an entity doesn't get knockback if you hit it.

The problem is that if you are close to the hitbox of the mob, you push it away. How can i disable to push it away?

Last seen on 00:30, 24. Aug 2023
Joined May 2014
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Maybe you can just make the…
Wed, 11/06/2019 - 21:45

Maybe you can just make the hitbox EXTREMELY small so there's just a low chance of the player moving it? Maybe if you set it to 0 you can remove it outright.

Last seen on 09:51, 9. Feb 2024
Joined Nov 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
But i want to make the mod…
Thu, 11/07/2019 - 12:18

But i want to make the mod hitable...

Last seen on 00:30, 24. Aug 2023
Joined May 2014
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Well there is one more way…
Thu, 11/07/2019 - 20:01

Well there is one more way to do this without coding but it's not foolproof or recommended: You could use commands within procedures to put the mob of choice on a /scoreboard team that has collisionRule disabled, then put the player on that same team.

Like I said, it's full of holes but I'm not much of a coder without looking for hours online, which you could do yourself.

Last seen on 09:51, 9. Feb 2024
Joined Nov 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Thank you, i will try it👍👍
Thu, 11/07/2019 - 20:49

Thank you, i will try it👍👍

Last seen on 09:11, 23. Mar 2024
Joined Jan 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
On initial entity spawn:…
Thu, 08/31/2023 - 12:09

On initial entity spawn:

save the x, y and z position in three NBT tags.

On entity tick update:

make entity move to that position.