reference other mods' mobs + specific mobs in a radius

Started by ikazilb on

Topic category: Help with Minecraft modding (Java Edition)

Joined Sep 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
reference other mods' mobs + specific mobs in a radius

For Forge 1.20.2

I am trying to create an item that when held, inflicts specific nearby mobs with a potion effect.

I was wondering if it is possible to specify mobs from other mods to be affected by it.


Additionally, if it is possible to inflict all of a specific mob in a radius around you, rather than just the closest one, that would be helpful to know too.

Thank you.

Joined Dec 2014
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Using the "On player tickā€¦
Tue, 10/01/2024 - 01:11

Using the "On player tick update" additional trigger on a global trigger procedure element. Something like the "For each entity as ... at x: ... y: ... z: ... in square cube with size ..." world procedure block, which should make it possible to affect all mobs in range.

 

For checking entities which should be affected you should make an entity tag in the "Element tags" tab in your workspace.