(SOLVED) need help with making areas like with the servers protections

Started by @Zyrex on

Topic category: Help with Minecraft modding (Java Edition)

Joined Sep 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
(SOLVED) need help with making areas like with the servers protections
Tue, 12/30/2025 - 01:55 (edited)

I'm making a factions mod and i need to make blocks that aren't entity blocks taggeable or something similar so i can designate areas as "diferent dungeons".

My first idea is to make some kind of beacon and that anything in that beacon thing's area of effect is (example) dungeon1 and if a mob enters in there it will be followed by the guards of the dungeon or that the dungeon mobs know where is safe and where is dangerous.

My second idea is to make my mod in a modpack instead combining it with a protections pluggin/mod to make the areas.

My third idea is making a special floor block (no entity block)  for every dungeon variation and make it so the entities (all of them) recognise the dungeon floor and from what dungeon is it from.

There might be other ways to do this but i can't imagine them with my current knowledge.

sorry if my english is bad (is not my home language) and thanks to anyone reading this and trying to help.

Edited by @Zyrex on Tue, 12/30/2025 - 01:55
Joined Sep 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
i just realized that there…
Wed, 12/31/2025 - 01:47

i just realized that there are forums like this that say (SOLVED), but doesn't say how it was solved.

I'll explain it in case it can be of help to someone in the future.

Here is the process in steps:

 

1- I made 2 effects: in (name) dungeon territory and in (name) dungeon base (the factions in my mod are called Dungeons)

 

2- i made all the dungeon entities detect if these effects are active in them. 

 

3- i made the main block of the dungeon emit the "in (name) dungeon territory" effect like a beacon in a big squared radius.

 

4 - I made some dungeon blocks called "room cores" that detect when they are placed if the nearest player has the effect "in (name) dungeon territory" to change their team to the same as the effect name and to give the effect "in (name of their team) dungeon base" to entities in a certain square radius.

5- EXTREMELY IMPORTANT: In advanced options of the blocks that give effects ACTIVE block entity and set the tick update to 2000 so it can active the effects with the command:

/effect give @a[distance=..(square radius in blocks)] (id of the mod):(name of the effect) (Duration in seconds) (amplifier)

That is the example, here is a template you can copy/paste and edit:

/effect give @a[distance=..15] minecraft:strenght 10 2

 

and thats all. i hope this can be of help to someone.