noob entity

ok so i need your help to create a minecraft plugin that can help us to create a youtube video their are three role first blind,deaf and mute. These Three role are very important You have to create the mute and deaf with the help of simple voice chat plugin and blind with giving a blindness effect or make all the roles in different commands like /blind /mute /deaf ok

Kodari AI
KodariAug 29 at 7:08 am 2
RoleChallenge
RoleChallenge is a Minecraft plugin that assigns players one of three challenge roles for YouTube videos: Blind, Deaf, or Mute. The Blind role applies a permanent blindness effect to the player. The Deaf role uses the Simple Voice Chat plugin API to disable the player's voice chat audio output, preventing them from hearing others. The Mute role also integrates with Simple Voice Chat to disable the player's microphone input, preventing them from speaking. Each role is activated via dedicated commands: /blind, /deaf, and /mute. The plugin tracks active roles per player, allows toggling roles on and off, and provides clear chat feedback when a role is applied or removed. It also supports removing all roles with a single command for easy reset during video recording sessions.
  1. Create the Gradle project and plugin metadata.

  2. Implement /blind, /deaf, and /mute with target-player, duration, clear, and status handling.

  3. Integrate Simple Voice Chat so deaf/mute affect voice communication, while blind applies a blindness effect.

  4. Add configuration/messages and permissions.

Created the ChallengeRoles Minecraft plugin with:

  • /blind <player> [seconds|off]

    • Applies and maintains the Blindness effect.

  • /mute <player> [seconds|off]

    • Blocks the player’s Simple Voice Chat microphone packets.

  • /deaf <player> [seconds|off]

    • Prevents Simple Voice Chat audio packets from reaching the player.

  • Permanent roles when no duration is supplied.

  • Duration-based roles with automatic expiration.

  • Join handling to restore blindness.

  • Permissions:

    • challengeroles.blind

    • challengeroles.mute

    • challengeroles.deaf

  • Simple Voice Chat declared as a required dependency.

  • Configurable messages and prefix in config.yml.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
manifest.kod
settings.gradle
Code
11 488
src/main/java/com/kodari/challengeroles/ChallengeRolesPlugin.java
package com.kodari.challengeroles;

import de.maxhenkel.voicechat.api.BukkitVoicechatService;
import org.bukkit.plugin.java.JavaPlugin;

public final class ChallengeRolesPlugin extends JavaPlugin {
    private RoleManager roleManager;

    @Override
    public void onEnable() {
        saveDefaultConfig();
        roleManager = new RoleManager(this);
        roleManager.start();

        RoleCommand roleCommand = new RoleCommand(this, roleManager);
        getCommand("blind").setExecutor(roleCommand);
        getCommand("mute").setExecutor(roleCommand);
        getCommand("deaf").setExecutor(roleCommand);
        getServer().getPluginManager().registerEvents(new RoleListener(roleManager), this);

        BukkitVoicechatService service = getServer().getServicesManager().load(BukkitVoicechatService.class);
        if (service == null) {
            getLogger().warning(color(getConfig().getString("messages.voicechat-unavailable", "Simple Voice Chat is unavailable.")));
            return;
        }
        service.registerPlugin(new VoicechatIntegration(roleManager));
    }

    @Override
    public void onDisable() {
        if (roleManager != null) {
            roleManager.shutdown();
        }
    }

    private String color(String message) {
        return org.bukkit.ChatColor.translateAlternateColorCodes('&', message);
    }
}