# Creating Custom Ranks

| Method                                            |
| ------------------------------------------------- |
| [Editing Existing Ranks](#editing-existing-ranks) |
| [Creating New Ranks](#creating-new-ranks)         |
| [Viewing Your Changes](#seeing-your-changes)      |

#### Downloading the pack

Download the resourcepack from the skript file. To find the download link, scroll down past the options and find the following text. (It's just after the huge block of text stating the following is code!)\\

```csharp
on join:
	wait 1 tick
	if {@enabled} is true:
		send resource pack "https://www.dropbox.com/s/examplecharacters/chat-ehancer.zip?dl=1" to player
		updateTag(player)
```

Copy the link on the fourth line from **your skript file**. The one above will not work.\
Once you've downloaded the resourcepack, create a new folder called "**chatenhancer**" inside your Minecraft resourcepacks folder and extract it there.\
\&#xNAN;*To find the resource pack folder, in Minecraft, press ESC, click "Options", click "Resource Packs" and then click "Open Resource Pack Folder"*

#### Editing Existing Ranks

Editing an existing rank is the easiest way to customise the pack, and we'll go over that first. Now that you've extracted the pack within a folder you created, open the "assets" folder. Then open "minecraft", "textures", "custom", "ranks" and you'll be presented with seven png images.\
\
For the sake of this tutorial, we're going to be changing **PRO** to **MVP**, as thats the rank I want on my server instead. You have a couple of options before editing. You can open the image with an image editing software, or copy and paste it in. I've copied my **PRO**.png into the image editing software [paint.net](https://www.getpaint.net/).\\

![My paint.net screen after pasting the image into the software.](https://3141317333-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MaOHhJNwBCDKNSOmlSL%2F-Mf2jyW2wJ-w6GICKmfb%2F-Mf2pB6q2-OBHPjD1c0Z%2Fimage.png?alt=media\&token=25ca4c2e-5ba3-4cce-bb5c-50f19a1ef76d)

**Keeping the rank greyscale is important**. If we we're to add any colors, if you change the rank colour in game its going to mix. If we keep it greyscale, it means that using color codes in Minecraft such as \&c, \&b, &2 and &5 will color the rank correctly.\
In the above image, on the left I have selected the **color picker** tool. I've selected a lightly colored square. I'm now going to select the **pencil tool** (just to the left of the currently selected one), and color **all but one** of the darker colored squares that spell out **PRO**. Im now left with the following.

![](https://3141317333-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MaOHhJNwBCDKNSOmlSL%2F-Mf2jyW2wJ-w6GICKmfb%2F-Mf2pdwelqSk8xHUEoLb%2Fimage.png?alt=media\&token=f02277f8-a193-479c-b47c-4b457aed937e)

![Using the color wheel, I've pressed the little blue arrow (left) to switch color.](https://3141317333-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MaOHhJNwBCDKNSOmlSL%2F-Mf2jyW2wJ-w6GICKmfb%2F-Mf2prvzvhgOKlG5gBXu%2Fimage.png?alt=media\&token=9269dfa3-ae04-4d80-9a91-c9a01631df08)

On the colors panel, press the little blue arrow or press "X" to change the selected color. Now, using the same **color picker** tool as before, select the last darker square. Then, switch back to the lighter color and draw over it using the **pencil** tool.

Now we need to create the letters for our rank. Switch back to the darker color and begin writing! Use the entire light box if you can (5 boxes per letter).

![](https://3141317333-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MaOHhJNwBCDKNSOmlSL%2F-Mf2jyW2wJ-w6GICKmfb%2F-Mf2qd6CF2U8klmznWw1%2Fimage.png?alt=media\&token=448f6290-015f-4670-a386-d8b59e00e845)

I've now drawn in my rank. Now, we need to save the image. If you opened the image with the software, click CTRL + S. If you copied the image into the software like me, you have a little more work to do.\
You can also click CTRL + S and a window will appear. In the navigation bar at the top of this window, you need to type **%appdata%**. Then, click Enter.

![](https://3141317333-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MaOHhJNwBCDKNSOmlSL%2F-Mf2jyW2wJ-w6GICKmfb%2F-Mf2r4UggWMGCWXeIqAq%2Fimage.png?alt=media\&token=f9b9d705-4851-4715-a62a-99b5c4c5c613)

Then, click ".minecraft", "resourcepacks", "chatenhancer", "assets", "minecraft", "textures", "custom", "ranks". Then, click on **PRO** (or whatever rank you changed) and click Save (at the bottom).\
\
→ Jump to [Seeing Your Changes](#seeing-your-changes)

#### Creating New Ranks

Creating a new rank is simple. We'll use our MVP rank as an example, but instead of editing it we'll just create it from scratch.\
\
We have our image created and saved as "MVP.png". We want to find the "default.json" file in the "font" folder of the resourcepack, which can be found in the following directory.\\

![](https://3141317333-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MaOHhJNwBCDKNSOmlSL%2Fuploads%2FhkBepvYfB0tBwq4HIm5e%2Fimage.png?alt=media\&token=8e6e9476-1158-4af3-8ba6-a7bc97942cc6)

Inside this file, we'll find a number of different things. You need to copy any of the similar code blocks to this. You can use the example below if you want to.

```json
        {
            "type": "bitmap",
            "file": "minecraft:custom/ranks/[FILENAME].png",
            "ascent": 7,
            "height": 7,
            "chars": ["[UNICODE]"]
        },
```

Paste your copy of this into the json file.\
Replace `[FILENAME]`with the name of your rank. In our example, our rank was saved as "MVP.png", so in the box we would type "MVP".\
Replace `[UNICODE]` with a unicode character of your choice. Please make sure the character you pick is not something already being used in this file.\
\
We now need to go the skript file saved on our server or desktop.\
The first thing we want to look for is the "colors" information. This will determine the color of our rank.

```csharp
# Colors - Select what colors each thing should use
	# Can either be standard codes (&-) or hex codes (<##------>)
	# Note; these colors are just examples. They don't all have to be different code forms. For example, you could have all of them specified as hex codes.
	owner: <##FF541E>
	ect...
```

Create a new line and add your ranks name. Ensure that it has the same indentation and spacing as all of the other ranks in the list. Add a color that you wish your rank to be. It can be hex, as in the example above, or a regular Minecraft color code.\
\
We then want to find the `on chat:` event. You're looking for a large block of code with something like this near the end.

```csharp
replace all "㊠" in chat format with "ᴅᴇꜰᴀᴜʟᴛ <##717171>●{@default}"
```

Copy this line and paste it into the code.\
Replace the existing unicode character with the one you selected and used in the "default.json" file.\
Replace "ᴅᴇꜰᴀᴜʟᴛ" and "{@default}" with the rank name. You can generate the small text [<mark style="color:purple;">here</mark>](https://lingojam.com/SmallTextGenerator).

{% hint style="warning" %}
Please ensure that you do not remove the "@" or "{}" when changing "{@default}".
{% endhint %}

Finally, in the function at the bottom of the script, you need to copy and paste two lines in and make similar changes as you have before.

```cshtml
	if {_p} has permission "rank.[RANK]":
		set {_p}'s display name to "{@[RANK]}[UNICODE] %{_p}%"
```

Replace `[RANK]` with the name of your rank (in our example, MVP).\
Replace `[UNICODE]` with the unicode character you selected and used in the "default.json" file.

You're all done! Learn to apply your changes in the "seeing your changes" section.\
→ Jump to [Seeing Your Changes](#seeing-your-changes).

#### Seeing Your Changes

Open Minecraft and join your server that has the script installed. You have 2 options. As the script checks for the server resourcepack being loaded, your version of the pack will not work.\
You can:\
• Upload your version of the pack to dropbox and insert a new link, changing dl=0 to dl=1.\
• Open the skript file, then find and remove the following code. (All of it, not just what's displayed below). Make sure to remove **ONE INDENT** from the code after **else:**

```csharp
				if loop-player does not have a resource pack loaded:
					replace all "㊰" in chat format with "ᴏᴡɴᴇʀ <##717171>●{@owner}"
					#REMOVE ALL ABOVE TO ALL BELOW
					send formatted "%chat format%" to loop-player
				else:
```

Then, reload the skript.\
As you're likely an operator, you'll still have the OWNER rank. If this is the one you changed, perfect. If not, you need to give yourself the permission **rank.\<rank you changed>**. Because I changed **PRO**, I need to give myself permission **rank.pro**. Then, I need to remove my OP perms.\
And just like that! My rank now displays as **MVP**.

![Our rank updated successfully!](https://3141317333-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MaOHhJNwBCDKNSOmlSL%2F-Mf2jyW2wJ-w6GICKmfb%2F-Mf2vNZdBVxX5ztJWTTg%2Fimage.png?alt=media\&token=f3cc1686-8e35-49dd-b3a9-6f218143d0ff)

If we want to change the permission from **rank.pro** to **rank.mvp**, its quite easy. Scroll to the bottom of the skript file and find "else if {\_p} has permission "rank.pro". Simply just change "pro" to "mvp" on this line. You'll need to change your in game permission if you do this, though.

#### Uploading your new textures to the server

To upload the changes you make to the server-side, you need to upload the pack with your changes to a service like [dropbox](https://dropbox.com). To do this, sign up, make the pack a zip folder and upload it. Grab the URL from the top of the page and upload it to the skript file in the specified section, as displayed at the top of the page.&#x20;

{% hint style="info" %}
Make sure to change the **dl=0** at the end of the link to **dl=1**
{% endhint %}
