Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #---------- Variables ----------#
- Variables:
- {disguise.sheep.%player%} = false
- #---------- Paramètres ----------#
- On join:
- Give a chest named "&6[&eAnimals&6]" to the player
- Display board named "&6[&eAnimals&6]" to player
- Make score "&4Pas d'animal" in board of player to 0
- Move display of player to sidebar
- On quit:
- Remove every chest named "&6[&eAnimals&6]" to the player
- Set {disguise.sheep.%player%} to false
- Undisguise player
- On place of chest:
- If player is holding a chest named "&6[&eAnimals&6]":
- Cancel event
- On load:
- Broadcast "&6[&eAnimals&6] &aLoaded"
- On unload:
- Broadcast "&6[&eAnimals&6] &cUnloaded"
- #---------- Menu ----------#
- On rightclick with a chest:
- If player is holding a chest named "&6[&eAnimals&6]":
- Open chest with 1 rows named "&6[&eAnimals&6]" to player
- Wait 1 tick
- Format slot 0 of player with white wool named "&7Mouton" to close then run [make player execute command "/disguise sheep"]
- Format slot 8 of player with 166 named "§4Enlever le déguisement" to close then run [make player execute command "/disguise clear"]
- #---------- Commandes ----------#
- Command /disguise [<text>]:
- Trigger:
- If args 1 is "sheep":
- If {disguise.sheep.%player%} is true:
- Send "&6[&eAnimals&6] &3Vous êtes déjà déguisé en &7Mouton§3..."
- Else:
- Send "&6[&eAnimals&6] &aVous êtes maintenant déguisé en &7Mouton &a!"
- Set {disguise.sheep.%player%} to true
- Disguise player as "sheep"
- #-- ScoreBoard --#
- Display board named "&6[&eAnimals&6]" to player
- Make score "§7Mouton" in board of player to 0
- Move display of player to sidebar
- If args 1 is "clear":
- Display board named "&6[&eAnimals&6]" to player
- Make score "&4Pas d'animal" in board of player to 0
- Move display of player to sidebar
- If {disguise.sheep.%player%} is true:
- Send "&6[&eAnimals&6] &5Vous n'êtes plus déguisé."
- Set {disguise.sheep.%player%} to false
- Undisguise player
- Else:
- Send "&6[&eAnimals&6] &2Vous n'êtes pas déguisé..."
- Command /chest:
- Trigger:
- Give a chest named "&6[&eAnimals&6]" to the player
- #---------- Effets ----------#
- #----- Mouton -----#
- On rightclick on a grass:
- If {disguise.sheep.%player%} is true:
- If player's food level is smaller than 10:
- Add 1 to hunger of player
- Set the clicked block to dirt
- On damage:
- If {disguise.sheep.%victim%} is true:
- Play raw sound "mob.sheep.say" at victim with pitch 1 volume 10
- On damage:
- If victim is a sheep:
- If {disguise.sheep.%attacker%} is true:
- Send "&6[&eAnimals&6] §5Mais c'est ton cousin, ne lui fait pas de mal !" to the attacker
- Cancel event
Advertisement
Add Comment
Please, Sign In to add comment