Interface NicknameModule

All Superinterfaces:
org.incendo.cloud.execution.CommandExecutionHandler<FPlayer>, ModuleCommand, ModuleLocalization, ModuleSimple

public interface NicknameModule extends ModuleCommand
The /nickname command, which changes the name a player is shown under.
  • Method Details

    • executeOther

      void executeOther(FPlayer fPlayer, org.incendo.cloud.context.CommandContext<FPlayer> commandContext)
      Runs the form of the command that changes someone else's nickname.
      Parameters:
      fPlayer - who ran it
      commandContext - the parsed arguments
    • config

      Description copied from interface: ModuleCommand
      The config section for this command, which also holds its aliases.
      Specified by:
      config in interface ModuleCommand
      Specified by:
      config in interface ModuleSimple
      Returns:
      the command settings
    • permission

      Description copied from interface: ModuleSimple
      The permission that gates this module.
      Specified by:
      permission in interface ModuleSimple
      Returns:
      the permission
    • localization

      Localization.Command.Nickname localization(FPlayer fPlayer)
      Description copied from interface: ModuleLocalization
      The localization section for a player, picked from their chosen language.
      Specified by:
      localization in interface ModuleLocalization
      Parameters:
      fPlayer - the player the text is for
      Returns:
      the localization settings
    • changeName

      void changeName(FPlayer fPlayer, FPlayer fTarget, String nickname)
      Changes a player's nickname and announces it.
      Parameters:
      fPlayer - who made the change
      fTarget - whose nickname changed
      nickname - the new nickname
    • sendMessageWithUpdatedNickname

      void sendMessageWithUpdatedNickname(FEntity fPlayer, String nickname, UUID metadataUUID)
      Announces a nickname change.
      Parameters:
      fPlayer - whose nickname changed
      nickname - the new nickname
      metadataUUID - the shared message id
    • addTag

      MessageContext addTag(MessageContext messageContext)
      Registers the tag that renders a player's nickname.
      Parameters:
      messageContext - the message being formatted
      Returns:
      the context with the tag added