non__13

make me a 1.21.11 working plugin on which on joining the server the user is welcomed with only some particles around him that dissapear after 2 sec and then make a system like every user in that server except the op user cant send any cmd in the chat like they can only send /spawn and /discord else if they type any other cmd they should be retuned You Dont Have Access to it ( IN RED ) and also make like player sending anything in chat is only visible to them and not visible to any other player in the server like the player is sending msgs but other cant see them or their msgs cant be shown to the other player

Kodari AI
KodariMay 15 at 4:20 pm 4,401 (v2)
SilentGuard
A 1.21.1 Spigot plugin that welcomes players with a particle effect display on join (disappearing after 2 seconds). Enforces strict chat and command restrictions: non-OP players can only use /spawn and /discord commands, all other commands are blocked with a red denial message. Chat messages sent by non-OP players are visible only to themselves, completely hidden from all other players on the server.

Planning class dependencies:

  • SilentGuard — main plugin class, registers listeners and commands

  • JoinListener — handles PlayerJoinEvent, spawns particles via repeating task

  • ChatListener — handles AsyncPlayerChatEvent, cancels visibility for others

  • CommandListener — handles PlayerCommandPreprocessEvent, blocks disallowed commands

  • SpawnCommand — handles /spawn

  • DiscordCommand — handles /discord

SilentGuard
A 1.21.1 Spigot plugin that welcomes players with a particle effect display on join (disappearing after 2 seconds). Enforces strict chat and command restrictions: non-OP players can only use /spawn and /discord commands, all other commands are blocked with a red denial message. Chat messages sent by non-OP players are visible only to themselves, completely hidden from all other players on the server.

Here’s what was built:

  • JoinListener — On join, spawns two rings of particles (TOTEM_OF_UNDYING outer ring + END_ROD inner ring) rotating around the player every 2 ticks for 40 ticks (2 seconds), then stops automatically.

  • ChatListener — On chat, non-OP players have all recipients removed except themselves, so only they see their own message.

  • CommandListener — Non-OP players typing any command other than /spawn or /discord get the message cancelled and receive §cYou Don't Have Access to it in red.

  • SpawnCommand — Teleports the player to world spawn.

  • DiscordCommand — Sends the Discord link from config.yml (edit discord-link to your real invite).

  • OP players bypass all restrictions — full chat visibility, all commands allowed.

non__13

i alr have spawn and discord cmds in my server throught other plugins that are working absoultely fine idw cmds made in the plugin sparately just make that we can use /spawn and /discord only

Kodari AI
KodariMay 15 at 4:27 pm 3,270 (v2)

Removed both command classes, unregistered them from SilentGuard.java, and stripped the commands: block from plugin.yml. The CommandListener already allows /spawn and /discord by label, so those commands from your other plugins will pass through fine — everything else is still blocked for non-OP players.

non__13

vc

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
7 177
src/main/java/com/silentguard/SilentGuard.java
package com.silentguard;

import com.silentguard.listeners.ChatListener;
import com.silentguard.listeners.CommandListener;
import com.silentguard.listeners.JoinListener;
import org.bukkit.plugin.java.JavaPlugin;

public class SilentGuard extends JavaPlugin {

    @Override
    public void onEnable() {
        saveDefaultConfig();

        getServer().getPluginManager().registerEvents(new JoinListener(this), this);
        getServer().getPluginManager().registerEvents(new ChatListener(), this);
        getServer().getPluginManager().registerEvents(new CommandListener(this), this);
    }
}