Skip to content
This repository was archived by the owner on Jul 7, 2023. It is now read-only.

Commit 6a3b4db

Browse files
author
Svenja Reissaus
committed
Added config to allow vanished players to hide particles for moderation purposes
1 parent cbb7d47 commit 6a3b4db

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

src/main/java/com/massivecraft/factions/cmd/CmdFly.java

+8
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,14 @@ public void run() {
5858
continue;
5959
}
6060

61+
if (FPlayers.getInstance().getByPlayer(player).isVanished()) {
62+
// Actually, vanished players (such as admins) should not display particles to prevent others from knowing their vanished assistance for moderation.
63+
// But we can keep it as a config.
64+
if (P.p.getConfig().getBoolean("ffly.Particles.Enable-While-Vanished")) {
65+
return;
66+
}
67+
continue;
68+
}
6169
if (P.p.useNonPacketParticles) {
6270
// 1.9+ based servers will use the built in particleAPI instead of packet based.
6371
// any particle amount higher than 0 made them go everywhere, and the offset at 0 was not working.

src/main/resources/config.yml

+1
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ enable-faction-flight: true
6565
ffly:
6666
Particles:
6767
Enabled: true
68+
Enable-While-Vanished: true
6869
AutoEnable: true #If set to true, fly will automatically enable when walking into your own chunk.
6970

7071

0 commit comments

Comments
 (0)