luk3yx / minetest-cloaking

Allows players to go invisible in Minetest!
MIT License
4 stars 3 forks source link

Hide the "cloaking" privilege. #3

Open fluxionary opened 5 years ago

fluxionary commented 5 years ago

A player on BlS just suggested this idea, and it's not so dumb. Would it be possible to hide the fact that a player has the "cloaking" priv when someone issues /privs PLAYERNAME?

luk3yx commented 5 years ago

It is possible, however it seems more annoying (for admins) than it would be useful.

fluxionary commented 5 years ago

I admit it's not gonna be too useful in practice, but if you want players to have less ability to tell that someone is watching them, it'd be useful to hide that certain players have a "cloaking" priv, or even see that the mod is installed at all (/mods).

The way I'm thinking this could be implemented, it wouldn't be too hard to check to see if the command-issuer has the admin priv (or the cloaking priv itself) and show them the truth.

It's too late for me to tackle this tonight, but perhaps I'll submit a PR tomorrow or the next day.

luk3yx commented 5 years ago

A "stealth mode" seems useful (where /cloak and /uncloak are hidden).

fluxionary commented 5 years ago

I haven't yet gotten around to testing things with IRC, but if you want to review what i've got so far:

https://github.com/luk3yx/minetest-cloaking/compare/master...obl3pplifp:master

I've tested this on a BlS-like local server, using an admin player and a regular player, on 0.4.17.1. and 5.0.1, and it seems to work well enough.

I'll try to get the IRC stuff running tomorrow to see if commands still work as expected over IRC, but I can't see any obvious reason why they wouldn't.

fluxionary commented 5 years ago

Ah, i should probably list the features:

For players with the admin or cloaking privilege, everything should appear as normal.

For players without either priv:

luk3yx commented 5 years ago

Can you open a pull request?