Aller au contenu
  • 0

Probleme kit


Question

Posté(e)

Bonjour j'ai un probleme !

command /kit <text>:
   trigger:
       if arg 1 is "voleur":
           permission: kit.voleur
           permission message: "Tu n'es pas un voleur !"
           equip player with iron helmet of protection 3
           equip player with diamond chestplate of protection 4
           equip player with iron leggings of protection 3
           equip player with diamond boots of protection 3
           set slot 0 of player to iron sword of sharpness 2,fire aspect 1
           set slot 1 of player to fishing rod of unbreaking 3
           set slot 2 of player to bow of unbreaking 3,power 3,flame 1
           set slot 3 of player to 64 steak
           set slot 4 of player to water bucket
           set slot 5 of player to lava bucket
           set slot 6 of player to 0373:8258
           set slot 7 of player to 0373:8270
           set slot 8 of player to 16 golden apple
           set slot 9 of player to 64 arrow
           set slot 10 of player to 64 arrow
           message "&aTu as recu le kit Voleur"
       if arg 1 is "gardien":
           permission: kit.policier                                                   
           permission message: "Tu es pas un policier !"
           equip player with diamond helmet of protection 2
           equip player with diamond chestplate of protection 4
           equip player with diamond leggings of protection 2
           equip player with diamond boots of protection 2
           set slot 0 of player to diamond sword of sharpness 2,fire aspect 1
           set slot 1 of player to fishing rod of unbreaking 3
           set slot 2 of player to bow of unbreaking 3,power 3,flame 1
           set slot 3 of player to 64 steak
           set slot 4 of player to water bucket
           set slot 5 of player to lava bucket
           set slot 6 of player to 0373:8258
           set slot 7 of player to 0373:8270
           set slot 8 of player to 8 golden apple
           set slot 9 of player to 64 arrow
           set slot 10 of player to 64 arrow
           message "&aTu as recu le kit Gardien"

 

Meme quand je suis deop je peux quand meme faire /kit et ça me le donne alors que j'ai pas la permission.

Comment faire quand je suis deop et sans la permission que ca me le donne pas ?

 

cordialement

Titan007

5 réponses à cette question

Messages recommandés

  • 0
Posté(e)

A mon avis, cela se ferait de cette manière :

command /kit <text>:
trigger:
	if arg 1 is "voleur":
		if player has permission "kit.voleur":
			--Tout le tralala d'équipement et de give
			send "&aTu as reçu le kit voleur !"
		else:
			send "&4Tu n'es pas un voleur !"
	else if arg 1 is "gardien":
		if player has permission "kit.gardien":
			--Tout le tralala d'équipement et de give
			send "&aTu as reçu le kit gardien !"
		else:
			send "&4Tu n'es pas un gardien !"

  • 0
Posté(e)

cela ne fonctionne pas

command /kit <text>:
   trigger:
       if arg 1 is "voleur":
           if player has permission "kit.voleur"
           permission message: "Tu n'es pas un voleur !"
           equip player with iron helmet of protection 3
           equip player with diamond chestplate of protection 4
           equip player with iron leggings of protection 3
           equip player with diamond boots of protection 3
           set slot 0 of player to iron sword of sharpness 2,fire aspect 1
           set slot 1 of player to fishing rod of unbreaking 3
           set slot 2 of player to bow of unbreaking 3,power 3,flame 1
           set slot 3 of player to 64 steak
           set slot 4 of player to water bucket
           set slot 5 of player to lava bucket
           set slot 6 of player to 0373:8258
           set slot 7 of player to 0373:8270
           set slot 8 of player to 16 golden apple
           set slot 9 of player to 64 arrow
           set slot 10 of player to 64 arrow
           send "&aTu as recu le kit Voleur"
       if arg 1 is "gardien":
           if player has permission "kit.gardien"                                                 
           permission message: "Tu es pas un policier !"
           equip player with diamond helmet of protection 2
           equip player with diamond chestplate of protection 4
           equip player with diamond leggings of protection 2
           equip player with diamond boots of protection 2
           set slot 0 of player to diamond sword of sharpness 2,fire aspect 1
           set slot 1 of player to fishing rod of unbreaking 3
           set slot 2 of player to bow of unbreaking 3,power 3,flame 1
           set slot 3 of player to 64 steak
           set slot 4 of player to water bucket
           set slot 5 of player to lava bucket
           set slot 6 of player to 0373:8258
           set slot 7 of player to 0373:8270
           set slot 8 of player to 8 golden apple
           set slot 9 of player to 64 arrow
           set slot 10 of player to 64 arrow
           message "&aTu as recu le kit Gardien"

  • 0
Posté(e)

il ne faut pas que tu mettes "permission message" (cela n'est valable qu'au tout début de la commande, c'est inapproprié dans la commande que tu proposes). Pour afficher un message d'erreur, tu dois utiliser un else, comme indiqué plus haut. Respecte également l'indentation !

  • 0
Posté(e)

Essaye ça :)

 

command /kit <text>:
   trigger:
       if arg 1 is "voleur":
           if player has permission "kit.voleur":
               equip player with iron helmet of protection 3
               equip player with diamond chestplate of protection 4
               equip player with iron leggings of protection 3
               equip player with diamond boots of protection 3
               set slot 0 of player to iron sword of sharpness 2,fire aspect 1
               set slot 1 of player to fishing rod of unbreaking 3
               set slot 2 of player to bow of unbreaking 3,power 3,flame 1
               set slot 3 of player to 64 steak
               set slot 4 of player to water bucket
               set slot 5 of player to lava bucket
               set slot 6 of player to 0373:8258
               set slot 7 of player to 0373:8270
               set slot 8 of player to 16 golden apple
               set slot 9 of player to 64 arrow
               set slot 10 of player to 64 arrow
               message "&aTu as recu le kit Voleur"
           else:
               send "&4Tu n'es pas un voleur !"
       if arg 1 is "gardien":
           if player has permission "kit.gardien":                                                
               equip player with diamond helmet of protection 2
               equip player with diamond chestplate of protection 4
               equip player with diamond leggings of protection 2
               equip player with diamond boots of protection 2
               set slot 0 of player to diamond sword of sharpness 2,fire aspect 1
               set slot 1 of player to fishing rod of unbreaking 3
               set slot 2 of player to bow of unbreaking 3,power 3,flame 1
               set slot 3 of player to 64 steak
               set slot 4 of player to water bucket
               set slot 5 of player to lava bucket
               set slot 6 of player to 0373:8258
               set slot 7 of player to 0373:8270
               set slot 8 of player to 8 golden apple
               set slot 9 of player to 64 arrow
               set slot 10 of player to 64 arrow
               message "&aTu as recu le kit Gardien"
           else:
               send "&aTu n'es pas un policier"

×
×
  • 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.