Aller au contenu

[Botania Mod Hat] en Skript !


Messages recommandés

Posté(e)

Bonjour, aujourd'hui je vous donne un petit Skript qui permet d'avoir les casques qui détectent si l'objet que vous tenez dans votre main est dans un coffre aux alentours de vous dans un rayon X.

Les crafts sont pour ceux qui savent lire le Skript (désolé les débutants)

Mais je déteste les leechers.

 

on load:
   register new shaped recipe for diamond helmet named "&bCasque &4BOTANIA &2x6" using diamond, diamond, diamond, diamond, redstone, diamond, compass, clock, compass
   register new shaped recipe for diamond helmet named "&bCasque &4BOTANIA &2x12" using  diamond, diamond, diamond, diamond, emerald, diamond, compass, clock, compass
   register new shaped recipe for diamond helmet named "&bCasque &4BOTANIA &2x24" using diamond, diamond, diamond, diamond, beacon, diamond, compass, clock, compass

command /botania:
   trigger:
       if player is wearing a diamond helmet named "&bCasque &4BOTANIA &2x6":
           if player is not holding air:
               loop all blocks in radius 6:
                   if loop-block is chest:
                       if loop-block's inventory contains player's tool:
                           set action bar of player to "&4[botania]&2Un coffre contient l'objet que tu tiens ! X : %x location of loop-block% Y : %y location of loop-block% Z : %x location of loop-block%"
                           play "LEVEL_UP" to player at volume 100
       else if player is wearing a diamond helmet named "&bCasque &4BOTANIA &2x12":
           if player is not holding air:
               loop all blocks in radius 12:
                   if loop-block is chest:
                       if loop-block's inventory contains player's tool:
                           set action bar of player to "&4[botania]&2Un coffre contient l'objet que tu tiens ! X : %x location of loop-block% Y : %y location of loop-block% Z : %x location of loop-block%"
                           play "LEVEL_UP" to player at volume 100
       else if player is wearing a diamond helmet named "&bCasque &4BOTANIA &2x24":
           if player is not holding air:
               loop all blocks in radius 24:
                   if loop-block is chest:
                       if loop-block's inventory contains player's tool:
                           set action bar of player to "&4[botania]&2Un coffre contient l'objet que tu tiens ! X : %x location of loop-block% Y : %y location of loop-block% Z : %x location of loop-block%"
                           play "LEVEL_UP" to player at volume 100

every 0.1 tick:
   make all players execute command "/botania"

 

Voilà un petit code bien sympa ! ;)

 

PS : Qui pourrait me passer RandomSk qui fonctionne sous Spigot 1.8.7 (mon serveur est hébergé chez Crystal-Serv et les .jar de bukkit et spigot sont un peu modifiés mais je ne pense pas que le problème vient de là)

Cordialement,

Clemdu45

 

REQUIS POUR CE SKRIPT : Les addons les plus utilisés ;)

Posté(e)
Bonjour, aujourd'hui je vous donne un petit Skript qui permet d'avoir les casques qui détectent si l'objet que vous tenez dans votre main est dans un coffre aux alentours de vous dans un rayon X.

Les crafts sont pour ceux qui savent lire le Skript (désolé les débutants)

Mais je déteste les leechers.

 

on load:
   register new shaped recipe for diamond helmet named "&bCasque &4BOTANIA &2x6" using diamond, diamond, diamond, diamond, redstone, diamond, compass, clock, compass
   register new shaped recipe for diamond helmet named "&bCasque &4BOTANIA &2x12" using  diamond, diamond, diamond, diamond, emerald, diamond, compass, clock, compass
   register new shaped recipe for diamond helmet named "&bCasque &4BOTANIA &2x24" using diamond, diamond, diamond, diamond, beacon, diamond, compass, clock, compass

command /botania:
   trigger:
       if player is wearing a diamond helmet named "&bCasque &4BOTANIA &2x6":
           if player is not holding air:
               loop all blocks in radius 6:
                   if loop-block is chest:
                       if loop-block's inventory contains player's tool:
                           set action bar of player to "&4[botania]&2Un coffre contient l'objet que tu tiens ! X : %x location of loop-block% Y : %y location of loop-block% Z : %x location of loop-block%"
                           play "LEVEL_UP" to player at volume 100
       else if player is wearing a diamond helmet named "&bCasque &4BOTANIA &2x12":
           if player is not holding air:
               loop all blocks in radius 12:
                   if loop-block is chest:
                       if loop-block's inventory contains player's tool:
                           set action bar of player to "&4[botania]&2Un coffre contient l'objet que tu tiens ! X : %x location of loop-block% Y : %y location of loop-block% Z : %x location of loop-block%"
                           play "LEVEL_UP" to player at volume 100
       else if player is wearing a diamond helmet named "&bCasque &4BOTANIA &2x24":
           if player is not holding air:
               loop all blocks in radius 24:
                   if loop-block is chest:
                       if loop-block's inventory contains player's tool:
                           set action bar of player to "&4[botania]&2Un coffre contient l'objet que tu tiens ! X : %x location of loop-block% Y : %y location of loop-block% Z : %x location of loop-block%"
                           play "LEVEL_UP" to player at volume 100

every 0.1 tick:
   make all players execute command "/botania"

 

Voilà un petit code bien sympa ! ;)

 

PS : Qui pourrait me passer RandomSk qui fonctionne sous Spigot 1.8.7 (mon serveur est hébergé chez Crystal-Serv et les .jar de bukkit et spigot sont un peu modifiés mais je ne pense pas que le problème vient de là)

Cordialement,

Clemdu45

 

REQUIS POUR CE SKRIPT : Les addons les plus utilisés ;)

Every 0.1 tick est trop exagéré non ? Lag assuré au bout de 100 joueurs ! Sinon il a l'air bien :)

Posté(e)
Every 0.1 tick est trop exagéré non ? Lag assuré au bout de 100 joueurs ! Sinon il a l'air bien :)

Ouais mais j'aime bien c'est sur que c'est tout le temps ;)

Posté(e)

Sympa, bien penser, mais je peux te dire que du 1 tick suffira amplement, il y a quand même 20 tick dans 1 seconde, donc si tu mets every 1 tick, sa ne changera pas grand chose on y prêtera même pas attention :)

Posté(e)
Sympa, bien penser, mais je peux te dire que du 1 tick suffira amplement, il y a quand même 20 tick dans 1 seconde, donc si tu mets every 1 tick, sa ne changera pas grand chose on y prêtera même pas attention :)

Le mieux c'est toujours d'utiliser un event ;)

 

Sinon j'ai pas trop regardé mais juste la vérification de l'objet dans les coffres c'est super sympa ! Gg :3

Posté(e)

PS : Qui pourrait me passer RandomSk qui fonctionne sous Spigot 1.8.7 (mon serveur est hébergé chez Crystal-Serv et les .jar de bukkit et spigot sont un peu modifiés mais je ne pense pas que le problème vient de là)

Cordialement,

Clemdu45

REQUIS POUR CE SKRIPT : Les addons les plus utilisés ;)

Il faut que ton serveur soit en Java 1.8

×
×
  • Créer...

Information importante

Nous avons placé des cookies sur votre appareil pour aider à améliorer ce site. Vous pouvez choisir d’ajuster vos paramètres de cookie, sinon nous supposerons que vous êtes d’accord pour continuer.