Compatibility
Minecraft: Java Edition
Platforms
Supported environments
90% of ad revenue goes to creators
Support creators and Modrinth ad-free with Modrinth+Details
SimplePrefixes
A plugin aiming to allow for simple player-selected prefixes that can be used in chat!
Requirements
- Paper-based Server (ie: PurpurMC)
- This plugin takes advantage of Mini-Message from Paper.
- PlaceholderAPI Plugin
Features
- Player friendly GUI for selecting nicknames.
- Does not interact with any other plugins directly.
- The plugin uses and hold prefixes in a placeholder, it will not affect permission groups / meta.
- Supports PlaceholderAPI Placeholders.
- Supports Mini-Message formatting.
- Supports multiple types of requirements:
PERMISSION
,STATISTIC
,ADVANCEMENT
,COMPARE_INT
Placeholders, Commands, and Permissions
%sp_prefix%
Placeholder for the prefix. Use this in your chat plugin.
Example Usage:
%sp_prefix% %player_displayname% » {message}
%sp_prefix_legacy%
Placeholder for the prefix. Necessary when you need the legacy (
&a
/§a
instead of<green>
) way to handle stuff.Example Usage:
%sp_prefix% %player_displayname% » {message}
/sp gui
Opens a generated GUI that organizes the prefixes by prefix-id.
/sp reset
Resets your prefix.
/sp set <prefix-id>
Sets your prefix.
/sp reload
Reloads the plugin.
Configuration
saving-type: "file"
default-prefix: "<white>[<gray>Player</gray>]</white> "
Configuration Settings
Setting | Description | Valid Values |
---|---|---|
saving-type | What type of saving system should this use? | PDC , FILE |
default-prefix | Fallback prefix, supports Placeholders. | String |
Saving Types
These are the current implementations of the saving types...
PersistentDataContainer (PDC)
The plugin will save the prefix ID of the currently equipped prefix on the Player themselves. This makes the prefix inaccessible while they are offline.
This was primarily used for initial testing of the plugin but if you don't like file systems for some reason, there.
YML File (FILE)
The plugin will save the prefix IDs of all players to a configuration YML file stored alongside the config. This allows for the prefix to be available while they are offline, but any time a player's prefix is changed, the plugin saves the prefix.
This is default.
Creating Prefixes
prefix-id:
display-name: "Prefix ID"
description:
- "This is to show an example Prefix!"
- "This is a second line of description!"
prefix: "<white>[<rainbow>Something</rainbow>]</white>"
verify-always: false
show-when-locked: true
requirements:
- "permission simpleprefix.example true"
- "statistic PLAYER_KILLS >= 10"
- "advancement nether/summon_wither true"
- "compare_int %placeholder% < 1"
prefix-id
This is the Prefix ID. Every prefix is uniquely identified by this value. This does mean you cannot have two of the same Prefix IDs.
The
prefix-id
itself is the value you change. Don't include spaces.
display-name
This is the Display Name of the prefix. It is used as basically the formatted way to display this Prefix.
Supports Placeholders from PlaceholderAPI.
prefix
This is the String representation of the prefix that will be displayed in place of %sp_prefix%.
Supports Placeholders from PlaceholderAPI.
# A prefix with the ID "example-prefix"...
example-prefix:
display-name: "The Example Prefix"
prefix: "<white>[<rainbow>Example</rainbow>]</white> "
Prefix Requirements
Requirements are things that must be held true in order to equip the prefix. These requirements come in multiple forms that will be explained here.
Note
Requirements that are incorrectly formatted or produce errors are ignored.
Requirements that cannot guarantee failure will not be checked either. To check player permissions, the player has to be online, so while the player is offline, these checks are ignored.
verify-always
will make the requirements check every time the player's prefix is requested. If the requirement check fails, the prefix saved is cleared.
Permission
Format: permission <permission.node> [false]
<permission.node>
represents a permission the player may have.
[false]
is optional and must be provided to invert the result. This means if the permission isexample.permission
, the player must NOT have this permission.Example:
permission example.permission
(Player has permission example.permission)Example:
permission example.permission false
(Player does not have permission example.permission)
Statistic
Format: statistic <statistic> <operator> <value>
<statistic>
is an enum value from this page. This represents some statistic the player has.
<operator>
is a comparison operator. Valid operators are>
,<
,>=
,<=
,==
,!=
<value>
is an integer and can be compared to the statistic.Example:
statistic ANIMALS_BRED >= 100
(Player has bred 100 or more animals).
Advancement
Format: advancement <namespace:advancement> [false]
<namespace:advancement>
is a Namespaced Key representing an Advancement.You can find vanilla advancements on this page. This represents some advancement the player can earn. Minecraft Advancements use the
minecraft
namespace.
[false]
is optional and must be provided to invert the result. This means that if the advancement isminecraft:nether/summon_wither
, the player must not have this advancement.Example:
advancement minecraft:nether/summon_wither
(Player has the Minecraft Summon Wither advancement).Example:
advancement minecraft:nether/summon_wither false
(Player does not have the Minecraft Summon Wither advancement).
Compare Int
Format: compare_int <placeholder> <operator> <value>
<placeholder>
is any PlaceholderAPI placeholder that can return a valid integer.
<operator>
is a comparison operator. Valid operators are>
,<
,>=
,<=
,==
,!=
<value>
is an integer and can be compared to the placeholder.Example:
compare_int %player_absorption% > 0
(Player has absorption value greater than 0).
Unimplemented
- Compare String, Case Sensitive
- Compare String, Case Insensitive
WIP Features
- Configurable Icons
- Compare String, Requirement Checks