Get all entities with custom effect

Started by zerosevenine on

Topic category: Help with modding (Java Edition)

Last seen on 17:56, 9. Nov 2022
Joined Dec 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Get all entities with custom effect
Tue, 01/25/2022 - 21:55 (edited)

Hello!

I'm making a mod including cool, battle-used tools and weapons.
I'd like to make a weapon which would give a specific custom effect (which i already have, lets call it *) upon hitting an entity.
This effect wouldn't do anything on it's own, but here comes the twist - rightclicking this weapon will briefly weaken and slow everyone having this specific effect and noone else, not dependant on reach or such.

So in conclusion, the only thing i need to know, is if there is a way to get ALL entities having the effect * - and only better, if it would be possible to have these entities as sort of a variable or a tag.

Thanks beforehand.

Edited by zerosevenine on Tue, 01/25/2022 - 21:55
Last seen on 23:12, 13. Aug 2023
Joined Nov 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
this works but you NEED to…
Wed, 01/26/2022 - 03:53

this works but you NEED to right click on an entityImage

Last seen on 23:12, 13. Aug 2023
Joined Nov 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
any entity not just one with…
Wed, 01/26/2022 - 03:54

any entity not just one with the effect

Last seen on 17:56, 9. Nov 2022
Joined Dec 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
And isn't it possible to…
Wed, 01/26/2022 - 12:49

And isn't it possible to make it straight the way of "get all entities with effect"? Isn't there some sort of mod or procedure addon for this?

 

Last seen on 11:41, 31. Mar 2024
Joined Aug 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
You can do it with the…
Wed, 03/02/2022 - 14:12

You can do it with the global trigger "On entity tick" or something like that. The procedure will be executed for every entity.