Collide with entity procedure

Started by SquidkingInc on

Topic category: Help with modding (Java Edition)

Last seen on 01:11, 18. Nov 2022
Joined Sep 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Collide with entity procedure

There is a collide with player proc but I need it to activate when any living entity touches it, how can I do this???
I don't mind coding it.

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

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Well if you don't mind…
Sat, 04/18/2020 - 06:05

Well if you don't mind coding, then, there's a void method called "collideWithEntity" that fires every tick if the entity is touching another entity. The syntax is:

public void collideWithEntity(Entity ent) 
{
	//Custom code here. "ent" represents the any entities your entity is colliding with
}

 

Last seen on 15:42, 2. Sep 2021
Joined Jun 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
hi rmsandegs, can zou help…
Tue, 09/08/2020 - 15:25

hi rmsandegs, can zou help me with this?