Ultra Customizer Guides
  • 👋Welcome
  • ❔Basics
    • Getting started
    • Elements details
    • Manage folders
      • Global management
      • Import export
  • 💻GUI's
    • How to open your GUI
    • Custom buttons
      • Custom button icon
      • Player head (Opening the GUI)
    • Button Lores
      • Players placeholders
    • Unlockable Buttons
  • ⚙️Simple systems
  • Creating a mute chat script
    • Creating the /mutechat command
    • Creating the /unmutechat command
    • Creating the script
  • Text message replacement
    • Creating the script
  • ---------------------------
    • Changelog
Powered by GitBook
On this page

Was this helpful?

  1. Creating a mute chat script

Creating the /mutechat command

In this step, we'll write the command for the mute chat script.

PreviousCreating a mute chat scriptNextCreating the /unmutechat command

Last updated 3 years ago

Was this helpful?

To begin, we must create the command to mute the chat. This command can be anything you want, but for this tutorial, we'll use /mutechat.

/customizer >> commands >> new command

When you've finished creating the command, we'll check to see if it's a staff member or a regular player. We'll use the "Has Permission" element for this.

Permission can be anything you want it to be! I've decided on the name "mutechat.admin."

We must now set up the true and false statements. To make things easier, I've separated the true and false statements into separate tabs.

When he has the permission, we will allow him to lock the chat. To accomplish this, we'll use the "Store Variable (String)" element to save a variable.

As the variable name, I've used "mutechat-status." The value of "mutechat-status" is "ON."

You can select different values, but you must remember them because they are required by the mute-chat script.

Once we've created the save variable, we'll send a message indicating that the chat is locked to the person in question. The message can be whatever you want it to be.

Following that, we will send a message to all of the players on the server.

We want to make it so that people with the bypass permission get a message saying that the chat has been muted by... but also that you have the bypass permission and can still talk. We will take the following steps to accomplish this.

  1. Get Player Name (From the command sender)

  2. Send Player Message (To every player)

  3. Has Permission

True

False

Using the "Send Player Message" element, we will send a message to the people who have that permission (Screenshot down below)

In the false statement, do nothing.

After sending the "Chat has been muted" message, you could add a sound notification using play sound.

When the player has no permission to mute the chat we want him to send a message that he has no permission using the "Send Player Message" element.

After you've completed both the True and False statements, you can move on to creating the /unmute command.

Creating the /unmutechat command