Aller au contenu

Entourer un joueur de blocks


Messages recommandés

Posté(e)

Voilà tu peux essayer de modifier, j'ai pas le temps de cherche pour freezer un autre joueur

 

command /freeze:
   trigger:
       set the block below to glass
       set the block east to glass
       set the block north to glass
       set the block west to glass
       set the block south to glass
       #PT Haut
       set the block above east to glass
       set the block above north to glass
       set the block above west to glass
       set the block above south to glass
       set the block 2 above to glass
       set {glass.actif.%player%} to true


#Pour enlever le freeze
       set the block below to air
       set the block east to air
       set the block north to air
       set the block west to air
       set the block south to air
       #PT Haut
       set the block above east to air
       set the block above north to air
       set the block above west to air
       set the block above south to air
       set the block 2 above to air

Posté(e)
Merci mais il y a ces petites erreurs : http://prntscr.com/at8z2b

Sinon le reste marche :p

Sinon, tu fais avec des setblocks avec les coordonnées relatives c:.

Exemple :

command /test:
   trigger:
       run player command "/setblock glass ~1 ~ ~" as op
       run player command "/setblock glass ~-1 ~ ~" as op
       #Ainsi de suite

Si la commande /setblock marche pas, remplace "/setblock" par "/minecraft:setblock"

 

Et si la syntaxe de la commande est mauvaise, faut modifier :x.

 

PS : Pas besoin d'op le joueur ;)

Posté(e)
Mais du coup là il faut définir des coordonnées précises^^

Bah nan! Les coordonnées relatives sont relatives au coordonnées du joueur!

Voilà le skript en entier :

command /freeze [<player>]:
   trigger:
       if arg-1 isn't set:
           send "message d'erreur"
       else:
           run arg-1 command "/minecraft:setblock glass ~1 ~ ~" as op
           run arg-1 command "/minecraft:setblock glass ~-1 ~ ~" as op
           run arg-1 command "/minecraft:setblock glass ~1 ~1 ~" as op
           run arg-1 command "/minecraft:setblock glass ~-1 ~1~" as op
           run arg-1 command "/minecraft:setblock glass ~ ~2 ~" as op
           run arg-1 command "/minecraft:setblock glass ~ ~-1 ~" as op
           run arg-1 command "/minecraft:setblock glass ~ ~ ~1" as op
           run arg-1 command "/minecraft:setblock glass ~ ~ ~-1" as op
           run arg-1 command "/minecraft:setblock glass ~ ~1 ~1" as op
           run arg-1 command "/minecraft:setblock glass ~ ~1 ~-1" as op
           wait 5 seconds
           run arg-1 command "/minecraft:setblock air ~1 ~ ~" as op
           run arg-1 command "/minecraft:setblock air ~-1 ~ ~" as op
           run arg-1 command "/minecraft:setblock air ~1 ~1 ~" as op
           run arg-1 command "/minecraft:setblock air ~-1 ~1~" as op
           run arg-1 command "/minecraft:setblock air ~ ~2 ~" as op
           run arg-1 command "/minecraft:setblock air ~ ~-1 ~" as op
           run arg-1 command "/minecraft:setblock air ~ ~ ~1" as op
           run arg-1 command "/minecraft:setblock air ~ ~ ~-1" as op
           run arg-1 command "/minecraft:setblock air ~ ~1 ~1" as op
           run arg-1 command "/minecraft:setblock air ~ ~1 ~-1" as op

Sinon, méthode 10000x plus simple :

command /freeze [<player>]:
   trigger:
       if arg-1 isn't set:
           send "Message d'erreur"
       else:
           loop block in radius 2 around the player:
               set loop-blocks to glass
               wait 5 seconds
                set loop-blocks to air

Posté(e)

command /freeze [<player>]:
   trigger:       
       set the block behind the arg-1 to glass
       set the block in left of arg-1 to glass
       set the block forwards of arg-1 to glass
       set the block in right of arg-1 to glass
       set the block backwards of arg-1 to glass
       #PT Haut
       set the block above the left of arg-1 to glass
       set the block above forwards of arg-1 to glass
       set the block above the right of arg-1 to glass
       set the block above backwards of arg-1 to glass
       set the block 2 above arg-1 to glass
       set {glass.actif.%player%} to true

#Pour enlever le freeze

       set the block behind the arg-1 to air
       set the block in left of arg-1 to air
       set the block forwards of arg-1 to air
       set the block in right of arg-1 to air
       set the block backwards of arg-1 to air
       #PT Haut
       set the block above the left of arg-1 to air
       set the block above forwards of arg-1 to air
       set the block above the right of arg-1 to air
       set the block above backwards of arg-1 to air
       set the block 2 above arg-1 to air

Je suis pas sur PC, après, j'essaierai d'en faire un plus compliqué (En sauvegardant la position des blocks :x)

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