Ah yes, you did that say that. I'm trying to get a sense of how the npc entity will attack (lightning?) and everything that this mod will do. I'm not sure, but it looks like you want this mod to:
- create an npc entity
- have the entity determine whether or not another entity is hostile, depending on if the non-npc entity is more than 100 feet away?
- if the non-npc entity is hostile, then it kills it
- if the non-npc entity is not hostile, it ignores it
Does that seem correct?
Some things I noticed right off the bat: your mod will need a function with the title of main, the wander goal block may not work here. If it doesn't try replacing it with a black js block containing: sidekick.getEntity().getLocation().distanceSquared(me.getLocation()) > 100