Aller au contenu
  • 0

run une commande quand on clique sur un bloc dans un coffre


Question

Posté(e)

j'aimerais que quand la personne clique sur les bloc pas ls vitre sa execute des commandes merci

 

command /rank [<player>]:
   permission:rank.use
   permission message: &cVous n'avez pas le droit d'utiliser cette commande !
   trigger:
       if arg 1 is not set:   
           message "&cErreur : Vous devez précisez quelqu'un !"
       if arg 1 is set:
           open chest with 3 rows named "&b&lRank de &c%arg 1%" to player
           wait 1 tick
           format slot 0 of player with Black Stained Glass Pane named " " to close
           format slot 1 of player with Black Stained Glass Pane named " " to close
           format slot 2 of player with Block of gold named "&eGold" to close
           format slot 3 of player with Black Stained Glass Pane named " " to close
           format slot 4 of player with Black Stained Glass Pane named " " to close
           format slot 5 of player with Black Stained Glass Pane named " " to close
           format slot 6 of player with Lapis lazuli block named "&cAdmin" to close
           format slot 7 of player with Black Stained Glass Pane named " " to close
           format slot 8 of player with Black Stained Glass Pane named " " to close
           format slot 9 of player with Black Stained Glass Pane named " " to close
           format slot 10 of player with Block of iron named "&7Silver" to close
           format slot 11 of player with Black Stained Glass Pane named " " to close
           format slot 12 of player with block of emerald named "&2Mod" to close
           format slot 13 of player with Black Stained Glass Pane named " " to close
           format slot 14 of player with Block of redstone named "&2Mod&c+" to close
           format slot 15 of player with Black Stained Glass Pane named " " to close
           format slot 16 of player with Block of diamond named "&4Owner" to close
           format slot 17 of player with Black Stained Glass Pane named " " to close
           format slot 18 of player with Black Stained Glass Pane named " " to close
           format slot 19 of player with Black Stained Glass Pane named " " to close
           format slot 20 of player with Glowstone named "&lYou&c&lTube" to close
           format slot 21 of player with Black Stained Glass Pane named " " to close
           format slot 22 of player with Black Stained Glass Pane named " " to close
           format slot 23 of player with Black Stained Glass Pane named " " to close
           format slot 24 of player with Obsidian named "&lFa&5&lMous" to close
           format slot 25 of player with Black Stained Glass Pane named " " to close
           format slot 26 of player with Black Stained Glass Pane named " " to close
           format slot 27 of player with Black Stained Glass Pane named " " to close

5 réponses à cette question

Messages recommandés

  • 0
Posté(e)

Tu fais ça :

 

format slot 20 of player with glowstone named "&lYou&c&lTube" to close then run [make player execute "/tacommande"]

 

Voilà je t'ai donné un exemple, à toi de faire le reste avec ce que je t'ai donné ;) !

  • 0
Posté(e)
Tu fais ça :

 

format slot 20 of player with glowstone named "&lYou&c&lTube" to close then run [make player execute "/tacommande"]

 

Voilà je t'ai donné un exemple, à toi de faire le reste avec ce que je t'ai donné ;) !

merci mais j'ai fais sa :

            format slot 20 of player with glowstone named "&lYou&c&lTube" to close then run [make player execute "/manuadd %arg 1% ytb , /automessager broadcast &7&l-============[&aPromotion&7&l]-============= %nl% /automessager broadcast &7&l%arg 1% viens d'etre promu du grade &lYou&c&lTube ! %nl% , /automessager broadcast &7&l-============[&aPromotion&7&l]-============= "]

mais le skript marche plus ...

  • 0
Posté(e)

Pour cela il faut passer par un sub :

 

format slot 20 of player with glowstone named "&lYou&c&lTube" to close then run [invoke "Sub_1" from "%arg 1%"]

Sub "Sub_1":
   set {_player} to parameter 1
   wait 0.1 tick
   set {_player} to "%{_player}%" parsed as player
   wait 0.1 tick
   execute console command "/manuadd %{_player}% ytb"
   broadcast "&7&l-============[&aPromotion&7&l]-============="
   broadcast "&7&l%{_player}% viens d'être promu du grade &lYou&c&lTube !"
   broadcast "&7&l-============[&aPromotion&7&l]-============="

  • 0
Posté(e)
Pour cela il faut passer par un sub :

 

format slot 20 of player with glowstone named "&lYou&c&lTube" to close then run [invoke "Sub_1" from "%arg 1%"]

Sub "Sub_1":
   set {_player} to parameter 1
   wait 0.1 tick
   set {_player} to "%{_player}%" parsed as player
   wait 0.1 tick
   execute console command "/manuadd %{_player}% ytb"
   broadcast "&7&l-============[&aPromotion&7&l]-============="
   broadcast "&7&l%{_player}% viens d'être promu du grade &lYou&c&lTube !"
   broadcast "&7&l-============[&aPromotion&7&l]-============="

erreur : http://prntscr.com/cj4uhc

 

code :

command /rank [<player>]:
   permission:rank.use
   permission message: &cVous n'avez pas le droit d'utiliser cette commande !
   trigger:
       if arg 1 is not set:   
           message "&cErreur : Vous devez précisez quelqu'un !"
       if arg 1 is set:
           open chest with 3 rows named "&b&lRank de &c%arg 1%" to player
           wait 1 tick
           format slot 0 of player with Black Stained Glass Pane named " " to close
           format slot 1 of player with Black Stained Glass Pane named " " to close
           format slot 2 of player with Block of gold named "&eGold" to close
           format slot 3 of player with Black Stained Glass Pane named " " to close
           format slot 4 of player with Black Stained Glass Pane named " " to close
           format slot 5 of player with Black Stained Glass Pane named " " to close
           format slot 6 of player with Lapis lazuli block named "&cAdmin" to close
           format slot 7 of player with Black Stained Glass Pane named " " to close
           format slot 8 of player with Black Stained Glass Pane named " " to close
           format slot 9 of player with Black Stained Glass Pane named " " to close
           format slot 10 of player with Block of iron named "&7Silver" to close
           format slot 11 of player with Black Stained Glass Pane named " " to close
           format slot 12 of player with block of emerald named "&2Mod" to close
           format slot 13 of player with Black Stained Glass Pane named " " to close
           format slot 14 of player with Block of redstone named "&2Mod&c+" to close
           format slot 15 of player with Black Stained Glass Pane named " " to close
           format slot 16 of player with Block of diamond named "&4Owner" to close
           format slot 17 of player with Black Stained Glass Pane named " " to close
           format slot 18 of player with Black Stained Glass Pane named " " to close
           format slot 19 of player with Black Stained Glass Pane named " " to close
           format slot 20 of player with glowstone named "&lYou&c&lTube" to close then run [invoke "Sub_1" from "%arg 1%"]

Sub "Sub_1":
   set {_player} to parameter 1
   wait 0.1 tick
   set {_player} to "%{_player}%" parsed as player
   wait 0.1 tick
   execute console command "/manuadd %{_player}% ytb"
   broadcast "&7&l-============[&aPromotion&7&l]-============="
   broadcast "&7&l%{_player}% viens d'être promu du grade &lYou&c&lTube !"
   broadcast "&7&l-============[&aPromotion&7&l]-============="


               format slot 21 of player with Black Stained Glass Pane named " " to close
               format slot 22 of player with Black Stained Glass Pane named " " to close
               format slot 23 of player with Black Stained Glass Pane named " " to close
               format slot 24 of player with Obsidian named "&lFa&5&lMous" to close
               format slot 25 of player with Black Stained Glass Pane named " " to close
               format slot 26 of player with Black Stained Glass Pane named " " to close
               format slot 27 of player with Black Stained Glass Pane named " " to close

  • 0
Posté(e)

[spoiler=Rectification]

command /rank [<player>]:
   permission:rank.use
   permission message: &cVous n'avez pas le droit d'utiliser cette commande !
   trigger:
       if arg 1 is not set:  
           message "&cErreur : Vous devez précisez quelqu'un !"
       if arg 1 is set:
           open chest with 3 rows named "&b&lRank de &c%arg 1%" to player
           wait 2 ticks
           format slot 0 of player with Black Stained Glass Pane named " " to close
           format slot 1 of player with Black Stained Glass Pane named " " to close
           format slot 2 of player with Block of gold named "&eGold" to close
           format slot 3 of player with Black Stained Glass Pane named " " to close
           format slot 4 of player with Black Stained Glass Pane named " " to close
           format slot 5 of player with Black Stained Glass Pane named " " to close
           format slot 6 of player with Lapis lazuli block named "&cAdmin" to close
           format slot 7 of player with Black Stained Glass Pane named " " to close
           format slot 8 of player with Black Stained Glass Pane named " " to close
           format slot 9 of player with Black Stained Glass Pane named " " to close
           format slot 10 of player with Block of iron named "&7Silver" to close
           format slot 11 of player with Black Stained Glass Pane named " " to close
           format slot 12 of player with block of emerald named "&2Mod" to close
           format slot 13 of player with Black Stained Glass Pane named " " to close
           format slot 14 of player with Block of redstone named "&2Mod&c+" to close
           format slot 15 of player with Black Stained Glass Pane named " " to close
           format slot 16 of player with Block of diamond named "&4Owner" to close
           format slot 17 of player with Black Stained Glass Pane named " " to close
           format slot 18 of player with Black Stained Glass Pane named " " to close
           format slot 19 of player with Black Stained Glass Pane named " " to close
           format slot 20 of player with glowstone named "&lYou&c&lTube" to close then run [invoke "Sub_1" from "%arg 1%"]
           format slot 21 of player with Black Stained Glass Pane named " " to close
           format slot 22 of player with Black Stained Glass Pane named " " to close
           format slot 23 of player with Black Stained Glass Pane named " " to close
           format slot 24 of player with Obsidian named "&lFa&5&lMous" to close
           format slot 25 of player with Black Stained Glass Pane named " " to close
           format slot 26 of player with Black Stained Glass Pane named " " to close
           format slot 27 of player with Black Stained Glass Pane named " " to close

Sub "Sub_1":
   set {_player} to parameter 1
   wait 0.1 tick
   set {_player} to "%{_player}%" parsed as player
   wait 0.1 tick
   execute console command "/manuadd %{_player}% ytb"
   broadcast "&7&l-============[&aPromotion&7&l]-============="
   broadcast "&7&l%{_player}% viens d'être promu du grade &lYou&c&lTube !"
   broadcast "&7&l-============[&aPromotion&7&l]-============="

 

 

  • J'aime 1
×
×
  • 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.