[Mod] Advanced area protection [areas]
Re: [Mod] Advanced area protection [areas]
Hi ShadowNinja,
Is there a possibility to include a new feature: the admin (or the player with a specific privilege/grant) can set or select a specific area to have PVP turned off (desactivated), when in PVP servers?
(in other words, PVP is active in the world, except in those lands/claims/protectedAreas where the admin turned the flag off for PVP)
As a real (and the main reason for the request) example, there is the Spawn area in a server: the player will not be able to hurt or kill another player; and he will not be hurted or killed (no damage taken) by other player too, when in the Spawn (or in some other specific protected area when pvp flag is turned off for that protected area).
This special option in a Mod for protecting land (where admins are able to disable PvP only in protected areas) has been asked since 2012, almost 2 years ago, without success till now. :(
viewtopic.php?f=6&t=4108
Please, can you add this new feature/option?
Thank you.
Is there a possibility to include a new feature: the admin (or the player with a specific privilege/grant) can set or select a specific area to have PVP turned off (desactivated), when in PVP servers?
(in other words, PVP is active in the world, except in those lands/claims/protectedAreas where the admin turned the flag off for PVP)
As a real (and the main reason for the request) example, there is the Spawn area in a server: the player will not be able to hurt or kill another player; and he will not be hurted or killed (no damage taken) by other player too, when in the Spawn (or in some other specific protected area when pvp flag is turned off for that protected area).
This special option in a Mod for protecting land (where admins are able to disable PvP only in protected areas) has been asked since 2012, almost 2 years ago, without success till now. :(
viewtopic.php?f=6&t=4108
Please, can you add this new feature/option?
Thank you.
- ShadowNinja
- Developer
- Posts: 200
- Joined: Tue Jan 22, 2013 22:35
- GitHub: ShadowNinja
- IRC: ShadowNinja
- In-game: ShadowNinja
Re: [Mod] Advanced area protection [areas]
Yes, but:brunob.santos wrote:Could you make areas hurt players who try to violate the areas?
- This can be done much more generically with a separate mod using register_on_protection_violation
- I don't like these deterrents because they hurt legitimate players and do nothing if the player messes with a unprotected area. If the area is protected they can't touch it and damaging them is pointless.
Yes, protect the large area and each small area, then use /area_open on the small areas that you want to be public.RHR wrote:Is it possible to remove a piece of a protected area? For example if you want to protect a huge area and make some small areas unprotected.
- ShadowNinja
- Developer
- Posts: 200
- Joined: Tue Jan 22, 2013 22:35
- GitHub: ShadowNinja
- IRC: ShadowNinja
- In-game: ShadowNinja
Re: [Mod] Advanced area protection [areas]
No. The PvP setting is server-wide, and clients might cache it. However it's probably possible to fake it by overriding on_punch or a similar callback in all entities to make it check where it is before accepting damage. This would be ugly though, would probably produce incorrect client-side damage prediction, and is definitely best suited for a external mod. Areas provides an API for external mods to use.WebWolf wrote:Is it possible to have areas where PvP is enabled or disabled? [Edited for clarity and brevity]
Re: [Mod] Advanced area protection [areas]
OK. So maybe there is some kind of light (possibility) in the future (through a new Mod)..ShadowNinja wrote:No. (...) However it's probably possible to fake it by overriding on_punch or a similar callback in all entities to make it check where it is before accepting damage. This would be ugly though, would probably produce incorrect client-side damage prediction, and is definitely best suited for a external mod. Areas provides an API for external mods to use.
Thank you. :)
-
- Member
- Posts: 22
- Joined: Mon Jun 02, 2014 20:21
- GitHub: LotekHeavy
- IRC: lotek
- In-game: lotek
- Location: Switzerland
- Contact:
Re: [Mod] Advanced area protection [areas]
how could I achieve that this mod (or another) also prevent users from digging through walls and to creep into "protected" buildings?
- Krock
- Developer
- Posts: 4650
- Joined: Thu Oct 03, 2013 07:48
- GitHub: SmallJoker
- Location: Switzerland
- Contact:
Re: [Mod] Advanced area protection [areas]
Revoke them "interact" or use (almost) not breakable nodes. Lags can happen.lotek wrote:how could I achieve that this mod (or another) also prevent users from digging through walls and to creep into "protected" buildings?
Look, I programmed a bug for you. >> Mod Search Engine << - Mods by Krock - DuckDuckGo mod search bang: !mtmod <keyword here>
- ShadowNinja
- Developer
- Posts: 200
- Joined: Tue Jan 22, 2013 22:35
- GitHub: ShadowNinja
- IRC: ShadowNinja
- In-game: ShadowNinja
Re: [Mod] Advanced area protection [areas]
This is impossible. Clients will always be able to go into protected buildings, even if it takes a modified client or disconnecting a network cable to do it. However, you can use a mod like my bedrock mod to slow down less determined players though.lotek wrote:how could I achieve that this mod (or another) also prevent users from digging through walls and to creep into "protected" buildings?
Re: [Mod] Advanced area protection [areas]
I recall one mod that dealt damage to players that dug protected nodes. It wouldn't completely protect the inside, but with a high enough damage setting, players would die upon entry.
- Calinou
- Moderator
- Posts: 3169
- Joined: Mon Aug 01, 2011 14:26
- GitHub: Calinou
- IRC: Calinou
- In-game: Calinou
- Location: Troyes, France
- Contact:
Re: [Mod] Advanced area protection [areas]
It's incredibly annoying to do such a thing, because it's hard enough to see whether a node is protected or not already. The only way where it would be acceptable is where it hurts you, then your health is given back after a few seconds.ak399g wrote:I recall one mod that dealt damage to players that dug protected nodes. It wouldn't completely protect the inside, but with a high enough damage setting, players would die upon entry.
-
- Member
- Posts: 4290
- Joined: Sun Sep 09, 2012 17:31
- GitHub: Sokomine
- IRC: Sokomine
- In-game: Sokomine
Re: [Mod] Advanced area protection [areas]
That's right. It usually annoys me a lot as well. Fortionately, the Landrush landclaim mod evolved. Brandon included some code (at least on his server) so that players who have been online for some time did no longer get attacked by the mod. No damage at all would still be better (that flower standing in the wild landscape without any indication of a building miles around may be protected), but with that exception for players who have been on some time, it usually works fine.Calinou wrote: It's incredibly annoying to do such a thing, because it's hard enough to see whether a node is protected or not already.
A list of my mods can be found here.
Re: [Mod] Advanced area protection [areas]
I have created a tool but the tool can be used in protected areas. I looked at the bucket code and the door code but I don't understand how to make it work. After I registered my tool I used this code to make it do something.
Any chance you could help me out.
Code: Select all
minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
if puncher:get_wielded_item():get_name() == "staff:staff"
and node.name == "default:cobble" then
minetest.set_node(pos,{name = "default:sand"})
end
Many of my mods are now a part of Minetest-mods. A place where you know they are maintained!
A list of my mods can be found here
A list of my mods can be found here
- ShadowNinja
- Developer
- Posts: 200
- Joined: Tue Jan 22, 2013 22:35
- GitHub: ShadowNinja
- IRC: ShadowNinja
- In-game: ShadowNinja
Re: [Mod] Advanced area protection [areas]
Yes, Areas supports Minetest's built-in protection API. Use minetest.is_protected(pos, player_name) to check if an area is protected from a player. If the area is protected you should probably call minetest.record_protection_violation(pos, player_name), which will send the user a warning chat message (and with other protection mods might do other things, such as inflicting damage on the player).Don wrote:I have created a tool but the tool can be used in protected areas [whereas it shouldn't]. Any chance you could help me out?
For example:
Code: Select all
minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
if puncher:get_wielded_item():get_name() == "staff:staff"
and node.name == "default:cobble" then
local player_name = punchar:get_player_name()
if minetest.is_protected(pos, player_name) then
minetest.record_protection_violation(pos, player_name)
return
end
minetest.set_node(pos, {name = "default:sand"})
end
end
Re: [Mod] Advanced area protection [areas]
- Idea -
Seeing the stars on GitHub or the sustained motivation brings by the 'likes' on FB, I thought that players may appreciate be starred for the quality of their construction. It can be interpretated like a simple thank you, a measurable valuation that authors can check anytime, or an effective way to visit the interesting buildings by priority.
Example :
(/star for starring a protected area)
Seeing the stars on GitHub or the sustained motivation brings by the 'likes' on FB, I thought that players may appreciate be starred for the quality of their construction. It can be interpretated like a simple thank you, a measurable valuation that authors can check anytime, or an effective way to visit the interesting buildings by priority.
Example :
(/star for starring a protected area)
-
- Member
- Posts: 940
- Joined: Tue Aug 05, 2014 14:09
- GitHub: MinetestForFun
- IRC: MinetestForFun
- In-game: MinetestForFun
- Location: On earth
- Contact:
Re: [Mod] Advanced area protection [areas]
very good idea and work jp, thank you
MinetestForFun Team mods : [spidermob] [fishing]
---
Our Minetest servers :
MinetestForFun (Survival - PvP - Hardcore)[FR/EN]
MinetestForFun HUNGER GAMES
MinetestForFun SKYBLOCK
MinetestForFun CREATIVE
---
Our Minetest servers :
MinetestForFun (Survival - PvP - Hardcore)[FR/EN]
MinetestForFun HUNGER GAMES
MinetestForFun SKYBLOCK
MinetestForFun CREATIVE
-
- Member
- Posts: 4290
- Joined: Sun Sep 09, 2012 17:31
- GitHub: Sokomine
- IRC: Sokomine
- In-game: Sokomine
Re: [Mod] Advanced area protection [areas]
That would be very nice to have. I've seen many great buildings where I wanted to thank the people who had built them for doing so. The areas mod and its data structure is also a natural place that comes to mind for storing such praise.jp wrote: Seeing the stars on GitHub or the sustained motivation brings by the 'likes' on FB, I thought that players may appreciate be starred for the quality of their construction. It can be interpretated like a simple thank you, a measurable valuation that authors can check anytime, or an effective way to visit the interesting buildings by priority.
A general "thank you", "recommend this to others" and maybe "report a problem" (in case lava gone wild or something else which might require intervention) might work best. If stars are assigned, a rating of e.g. 1-5 stars comes to mind - which might not work so well as everyone might have a diffrent opinon about what ought to be ranked how, whereas a "thank you" is more neutral.
Another reason for wanting to have such an option could be to allow players to self-protect more areas if the areas they have already found the approval of other players. This might be a protection against land-grabbing.
A list of my mods can be found here.
Re: [Mod] Advanced area protection [areas]
Great idea, jp. I'll implement that on my server at some point.
There is no such thing as duty. If you know that a thing is right, you want to do it. If you don't want to do it—it isn't right. If it's right and you don't want to do it—you don't know what right is and you're not a man. -- Ayn Rand
- ShadowNinja
- Developer
- Posts: 200
- Joined: Tue Jan 22, 2013 22:35
- GitHub: ShadowNinja
- IRC: ShadowNinja
- In-game: ShadowNinja
Re: [Mod] Advanced area protection [areas]
This seems like more of a "cool" feature than a "useful" one, so I think it would be better implemented with a separate mod using the Areas API. It wouldn't be as simple as your mockup though because you can be standing in multiple areas at a time and you'd have to explicitly pass an area ID.jp wrote:Idea: Area staring.
-
- Member
- Posts: 940
- Joined: Tue Aug 05, 2014 14:09
- GitHub: MinetestForFun
- IRC: MinetestForFun
- In-game: MinetestForFun
- Location: On earth
- Contact:
Re: [Mod] Advanced area protection [areas]
@ShadowNinja
I think also, we need a separate mod for this "stars idea" :)
I think also, we need a separate mod for this "stars idea" :)
MinetestForFun Team mods : [spidermob] [fishing]
---
Our Minetest servers :
MinetestForFun (Survival - PvP - Hardcore)[FR/EN]
MinetestForFun HUNGER GAMES
MinetestForFun SKYBLOCK
MinetestForFun CREATIVE
---
Our Minetest servers :
MinetestForFun (Survival - PvP - Hardcore)[FR/EN]
MinetestForFun HUNGER GAMES
MinetestForFun SKYBLOCK
MinetestForFun CREATIVE
- Krock
- Developer
- Posts: 4650
- Joined: Thu Oct 03, 2013 07:48
- GitHub: SmallJoker
- Location: Switzerland
- Contact:
Re: [Mod] Advanced area protection [areas]
How about extending a configuration file with a setting to enable/disable this feature?Minetestforfun wrote:@ShadowNinja
I think also, we need a separate mod for this "stars idea" :)
I like the stars-idea and I hope it's not possible to give a star more than once on an area.
Look, I programmed a bug for you. >> Mod Search Engine << - Mods by Krock - DuckDuckGo mod search bang: !mtmod <keyword here>
-
- Member
- Posts: 4290
- Joined: Sun Sep 09, 2012 17:31
- GitHub: Sokomine
- IRC: Sokomine
- In-game: Sokomine
Re: [Mod] Advanced area protection [areas]
I think it could actually be useful on a server where quality is more important than quantity. On the Minecraft classic server I started getting to know this kind of game, players started on one map, and then subsequently gained access to other maps/areas where they got permission to built after their buildings where inspected by moderators and found good enough. Most Minetest servers are very diffrent in this regard. A problem they do have is that the area around spawn is limited and valuable, and that players sometimes grab too much land.ShadowNinja wrote: This seems like more of a "cool" feature than a "useful" one, so I think it would be better implemented with a separate mod using the Areas API.
My marker stone attempts to figure out - amongst other things - which area is the smallest (and thus most fitting) one at the place the stone is located. A formspec where the name of the player is listed and the thank you/approval can be given could help.ShadowNinja wrote: It wouldn't be as simple as your mockup though because you can be standing in multiple areas at a time and you'd have to explicitly pass an area ID.
A list of my mods can be found here.
Re: [Mod] Advanced area protection [areas]
sorry but it plain does not work. i was playign on a server with this mod installed, my lane was protected and people can still A: open your doors B: break anything they want on your property. i had 2 retards go onto my land, break my windows, walls, doors, steal my chicken eggs, steal diamonds out of my chests, and the list goes on. all in front of me to. sorry but a mod like this CANT have a way around it or im sorry, it may as well not exist, and no, im not going to be nice about it either. your mod stats it will keep people from breaking things built on your land and it doesn't.
Re: [Mod] Advanced area protection [areas]
I have this mod on my server. It works exactly how it is suppose to. Either you are doing something wrong or the server is not set up right.Neizi wrote:sorry but it plain does not work. i was playign on a server with this mod installed, my lane was protected and people can still A: open your doors B: break anything they want on your property. i had 2 retards go onto my land, break my windows, walls, doors, steal my chicken eggs, steal diamonds out of my chests, and the list goes on. all in front of me to. sorry but a mod like this CANT have a way around it or im sorry, it may as well not exist, and no, im not going to be nice about it either. your mod stats it will keep people from breaking things built on your land and it doesn't.
Many of my mods are now a part of Minetest-mods. A place where you know they are maintained!
A list of my mods can be found here
A list of my mods can be found here
- ShadowNinja
- Developer
- Posts: 200
- Joined: Tue Jan 22, 2013 22:35
- GitHub: ShadowNinja
- IRC: ShadowNinja
- In-game: ShadowNinja
Re: [Mod] Advanced area protection [areas]
I've had a server owner come to me with a similar complaint. The problem was that they had areas (the administration privilege) granted by default to all players.
It's quite likely that the server is mis-configured or you're misusing the mod.
If most things are protected but one or two things aren't, it's likely that a different mod is using custom digging / placing code and neglecting to check for protection with the protection API.
Doors are intentionaly still useable in protected areas, use steel doors if you want them to be protected. Likewise with chests and locked chests.
It's quite likely that the server is mis-configured or you're misusing the mod.
If most things are protected but one or two things aren't, it's likely that a different mod is using custom digging / placing code and neglecting to check for protection with the protection API.
Doors are intentionaly still useable in protected areas, use steel doors if you want them to be protected. Likewise with chests and locked chests.
-
- New member
- Posts: 4
- Joined: Sat Dec 13, 2014 03:57
Re: [Mod] Advanced area protection [areas]
Hi, chickens from mod simple_mobs lay eggs in a protected area and only the owner can remove them. Is it easily possible to add a whitelist of objects/nodes that would be exempt from protection?
- ShadowNinja
- Developer
- Posts: 200
- Joined: Tue Jan 22, 2013 22:35
- GitHub: ShadowNinja
- IRC: ShadowNinja
- In-game: ShadowNinja
Re: [Mod] Advanced area protection [areas]
This is an issue with simple_mobs.disableclouds wrote:Hi, chickens from mod simple_mobs lay eggs in a protected area and only the owner can remove them.
If eggs are entities, areas doesn't do any protection handling for entities and simple_mobs is doing this.
If eggs are nodes, simple_mobs is missing a protection check before placing the egg.
Who is online
Users browsing this forum: No registered users and 40 guests