(Abandonned) Hats (Dropable and Wearable hats) ! [1.8 - 1.14] 1.0.5

Reproduction as a plugin of the mod Hats of iChunUtil, allows you to use and creates hats !

  1. GreenTree0
    Native Minecraft Version:
    1.14
    Tested Minecraft Versions:
    • 1.8
    • 1.9
    • 1.10
    • 1.11
    • 1.12
    • 1.13
    • 1.14
    Languages Supported:
    English
    This project is abandonned, which means I will no longer repair bugs, or update it, the reason for that is because I increased my programming and knowledge skills, and this program isn't optimised at all, I would have to rewrite it, and he's performance destructor as well, I do not recommend it!

    [​IMG]

    [​IMG]
    This project is a reproduction as a plugin of the mod Hats of iChunUtil, here are some pictures :

    [​IMG]
    This plugin works with ArmorStands, it simply makes them invisible, gives them an object, and a program will control their positions actualized every tick of the game !

    [​IMG]
    You will be able to drop hats on mobs, each time a mob spawn, he have a chance to get a hat (that chance is changeable in the config, default : 1/5), if you kill this mob you get his hat !
    The plugin starts with 15 hats, but the better aspect of this plugin is that you can easily create your own hats and add them to the game ! (More information at the end of the page)

    [​IMG]
    The commands are very simple, and intuitive :
    - /hats #Allows you to see your hats -- permission : Hats.collection
    - /hats equip {hat} #Allows you to equip one of your hats, put 'none' to unequip your actual hat -- permission : Hats.equip
    - /hats {player} #Allows you to see a player's hats -- permission : Hats.collection.others
    - /hats give {player} {hat} #Allows you to give hats to players, put 'all' to give all hats -- permission : Hats.give
    - /hats remove{player} {hat} #Allows you to remove hats from players, put 'all' to remove all hats -- permission : Hats.remove
    - /hats debug #Will remove and unequip all loaded hats -- permission : OP

    Here is a list of the actual available hats :
    - Dragonhead - Danger - Musical - Painful - PoorMiner - Miner - RichMiner - FishOn - GiantTree - Jewel - SauronEyes - FrenchFlag - MobileBank - Ritual

    [​IMG]
    ArmorStands can be very laggy !
    ArmorStands are considered as entities, and some hats of the game are made ouf of 9 armor stands !
    So if 10 players have an hat with 9 armor stands at the same time, it may cause fps loss, it's why here are my advices :
    I recommend this plugin in a server of 10 - 15 players max, if you wan't to use it on a server with more players, I recommend you to make hats with only 1 or 2 armor stands, and never more.
    If your server is still lagging a lot, then disable hat spawning on entities, and find an other way to give them to your players.

    [​IMG]
    There are 3 things you can edit in the config :
    - The 'DebugMsg' Boolean, you put 'true' or 'false', this will enable or disable debug messages, you don't need them if there are no bugs.
    - The 'EntitiesWithHats' Boolean, you put 'true' or 'false', this will enable or disable that entity can spawn with hats (if you disable it, the only way to get hats is to give them).
    - The 'SpawningRate' Integer, you put a number (not decimal), this will change the chance that an entity got an hat, by default it's 5, if you put for example 10, then their will be 1/10 chance when an entity spawn that she got a hat.


    [​IMG]

    Okay, I said it would be easy, but it's a bit complicate, you will need to understand carefully all i'm going to say now.
    To create and edit hat, go into the config.yml text file in your Hats folder in your plugins folder, to open it you will need a text editor, I recommend notepad++.

    1.14 Tutorial :
    Here is the example of an hat in the config :

    Danger:
    armorstands:
    - TNT;0.0;0.0;0.0
    - FLINT_AND_STEEL;0.0;0.5;0.2


    The first line is the name of the hat, in this case it's 'Danger', the second line isn't important, but need to be there, and what really interest us are the lines after, each of those represent an item part of the hat.
    If you look carefully, you can see that those lines are divided in parts.
    Here they are :

    [ITEM_NAME] ; [Right/Left] ; [Up/Down] ; [Front/Behind]
    Okay, that may be scary but don't care, you will understand, we're gonna go threw each element :

    - [ITEM_NAME] :
    This is the name of one of the item that will creates your hat.

    - [RIGHT/LEFT] :
    The Right/Left is one of the position of the item (the item is already at the center of the mob and at the good height), if you add for example 0.5 at this place (so it makes ITEM_NAME;0.5;Up/Down;Front/Behind) then your item/block will be placed 0.5 block at the right of the center of the mob (those numbers needs to be decimal, you can put 1.0 etc...), if you put -0.5 block, he'll go to the left.
    - [UP/DOWN] ; [FRONT/BEHIND] :
    Actually Up/Down and Front/Behind work exactly the same, to go up you put positives numbers, and to go down negatives, positives for the front, negatives for the behind.

    1.12 Tutorial :
    Here is the example of an hat in the config :

    Danger:
    armorstands:
    - 46;0.0;0.0;0.0
    - 259;0.0;0.5;0.2


    The first line is the name of the hat, in this case it's 'Danger', the second line isn't important, but need to be there, and what really interest us are the lines after, each of those represent an item part of the hat.
    If you look carefully, you can see that those lines are divided in parts.
    Here they are :

    [ID] ; [Right/Left] ; [Up/Down] ; [Front/Behind]
    Okay, that may be scary but don't care, you will understand, we're gonna go threw each element :

    - [ID] :
    This is the id of one of the item that will creates your hat.

    - [RIGHT/LEFT] :
    The Right/Left is one of the position of the item (the item is already at the center of the mob and at the good height), if you add for example 0.5 at this place (so it makes ID;0.5;Up/Down;Front/Behind) then your item/block will be placed 0.5 block at the right of the center of the mob (those numbers needs to be decimal, you can put 1.0 etc...), if you put -0.5 block, he'll go to the left.
    - [UP/DOWN] ; [FRONT/BEHIND] :
    Actually Up/Down and Front/Behind work exactly the same, to go up you put positives numbers, and to go down negatives, positives for the front, negatives for the behind.
    If it wasn't clear for you, just post a comment and I'll answer your questions.
    niho1212 likes this.

Recent Updates

  1. Update logs :

Recent Reviews

  1. Neoncam
    Neoncam
    3/5,
    Version: 1.0.1
    Goood but please add 1.13 - 1.14 support


    Thank's :)

    u know 80 chars
    *******************
    1. GreenTree0
      Author's Response
      Added ^*^, and it meant a lot of work.