Poikilos / EnlivenMinetest

Minetest engine server management tools and ENLIVEN game installer/updater
Other
3 stars 0 forks source link

Add or Create Environment Privileges Mod #225

Open Poikilos opened 5 years ago

Poikilos commented 5 years ago

This is distinct from privilegeares which only affects players (?). Allow player with (new) area_env_privs to grant or revoke the environment's priveleges in an area (including world scope). Related player privs to add:

Priveleges in this context are for the environment itself.

Related to player stats but still given to environment:

Suggested comments: other privileges.

slopsbucket commented 5 years ago

I'm really not sure what is being asked for here, sorry.

I can see two different ways of reading that message. Is the message originator checking to make sure that no mod can do all these things? Making sure that someone isn't making the world's greatest griefing tool? Or is that the ultimate wishlist?

With full admin privs you can do all of these things anyway, is it an admin gui they're asking for?

Poikilos commented 5 years ago

@slopsbucket, Ill give an example then rephrase the question in that context: I want to create a minigame where there are fire traps, but fire cannot spread, and a residence where players cannot dump lava onto it by building a bridge high enough to avoid protection. I also dont want them to fill the entire thing with sand on it from up there. I also may want players to place fire in only certain areas for a different minigame. Can I do all that with a mod, or do I have to change the Bucket_Game mods' ABM code and other code?

Poikilos commented 5 years ago

The question mark in parenthesis was regarding whether privelegeareas can grant/revoke environment privs or just player privs.

slopsbucket commented 5 years ago

I think the "areas" mod only affects player privs. As far as I know fire can only be enabled or disabled for the entire map, not for individual areas.

A simple solution that might be of help though, using the areas mod there's no reason you can't set an area 31000 nodes high.

Poikilos commented 5 years ago

I think the "areas" mod only affects player privs. As far as I know fire can only be enabled or disabled for the entire map, not for individual areas.

Ok Thanks.

A simple solution that might be of help though, using the areas mod there's no reason you can't set an area 31000 nodes high.

This enhancement would also be for player residences which should be limited in size, and having lava or water flow in from the side would remain possible.

Poikilos commented 5 years ago

More information from the wontfix issue above (pasting myself, then providing new information learned later):

Making some type of multiplayer arena that isn't breakable is really hard right now. I don't know if protection works better in the git version, but I do know that at least up to 0.4.16 people can eventually dig horizontally or downward through things protected by protector redo or even advanced area protection when there is any amount of lag. Even if that is fixed (if player mining and movement no longer occurs in the milliseconds preceding the protector or advanced area protection taking effect), more priveleges would allow a proper protection mods to be made. The solution below explains what I mean by a "proper" protection mod. This is possibly easy to implement (?) but could improve the ability to make minigames or quests drastically.

Make separate priveleges for "build", "mine", "node_use", and "inventory_use", and "attack"

SOLVED: check wield item on punch callback (in addition, interact and build are now separate in minetest.org releases).

imagine an arena where the doors are automatically opened and closed but players can't break them or break the minigame by opening or closing the door or using the teleporter manually, because they have "attack" and "inventory_use" but not "node_use" (only other solution is to create a custom non-interactive door node or regular block such as cobblestone as a door and protect the area which hasn't been reliable in lag scenarios)

SOLVED: handle on_rightclick for door, remove digging group (requires custom automatic door, but that's ok--build can now be disabled while allowing interact, so player could open regular doors but not this one, and couldn't place a button or other mechanism to open it)

Someone could make a minigame or subgame where attacking by hand could be disabled via disabling the "attack" privelege, but some kind of laser tag type of weapon or paint grenade could still be used via the "inventory_use" privelege, and you could trigger traps or elevators with a separate "node_use" privelege

SOLVED (needs confirmation): check wield item on punch callback

imagine a minigame or subgame where swords, punching, and remaking the world or minigame arena is prevented by having no "attack", "build", or "mine" privilege, but some kind of grappling hook, or item with supernatural powers or building powers can still be used via a "inventory_use" privilege, you can open doors and pull levers with a "node_use" privelege, but you can only complete your task or quest by using those methods (only current solution seems to be to make entire area out of blocks that aren't breakable by hand and to deny the player a pick and any items for making a pick, and to not provide them with any items that can be used as nodes).

SOLVED: interact and build are now separate in minetest.org releases

Poikilos commented 4 years ago

Most important:

(See also others in issue body above, which also has suggested variable naming)