Aller au contenu

[Conversion] Plugin en skript


Messages recommandés

Posté(e)

Bonsoir,

 

Je viens ici demander (si c'est possible) une conversion de plugin en skript. Je m'explique :

 

J'ai actuellement le plugin 1vs1, plugin de PvP et je souhaite avec la même chose (ou à peu près) en skript.

Fonctions requises : Plusieurs arènes, définir des spawns, des rounds, un compte à rebours, un prix de victoire, un stuff paramétrable pour chaque arène.

 

Je peux skype ou ts. Me MP pour le contact.

Je ne RÉMUNÈRE PAS !

 

Merci d'avance !

Posté(e)

Alors voilà ce que je t'ai fait:

 

Tu as la possibilité de créer des arènes qui peuvent être configuré entièrement grâce à un menu tel que /setinv <integer>

Tu n'as pas la possibilité de choisir le nom de ton arène.

Exemple:

command /setarena1 <integer>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           arg 1 > 0
           if {max} is not set:
               set {max} to 1
           arg 1 =< {max}
           set {arena1.%arg 1%}
           if {arenalist.%arg 1%::*} does not contains arg 1:
               add arg 1 to {arenalist::*}
           else:
               stop
           message "&eVous venez de saisir de point de spawn numéro &62 &edans l'arène &6%arg 1%."

Pendant un combat le premier arrivé à trois victoire l'emporte.

Tu peux choisir un nombre maximum d'arènes.

Tu peux mettre jusqu' à 53 arènes.

Si tu souhaites des améliorations recontacte moi.

Il est tard donc si il y a des erreurs merci de me pardonner et de m'envoyer un screen des erreurs pour que je puisse corriger cela.

 

options:
   perm: mod
   default:1
command /setarena1 <integer>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           arg 1 > 0
           if {max} is not set:
               set {max} to 1
           arg 1 =< {max}
           set {arena1.%arg 1%}
           if {arenalist.%arg 1%::*} does not contains arg 1:
               add arg 1 to {arenalist::*}
           else:
               stop
           message "&eVous venez de saisir de point de spawn numéro &62 &edans l'arène &6%arg 1%."
command /setarena2 <integer>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           arg 1 > 0
           if {max} is not set:
               set {max} to 1
           arg 1 =< {max}
           set {arena2.%arg 1%}
           if {arenalist.%arg 1%::*} does not contains arg 1:
               add arg 1 to {arenalist::*}
           else:
               stop
           message "&eVous venez de saisir de point de spawn numéro &62 &edans l'arène &6%arg 1%."
command /maxarenas <integer>:
   permission: {@perm}
   trigger:
       if arg 1 is not set:
           message "&eLe nombre maximum d'arène vient d'être mis à defaut: {@default}"
           set {max} to 1
       else:
           message "&eLe nombre maximum d'arène vient d'être mis à: %arg 1%"
           set {max} to 1
command /setinv [<integer>]:
   permisison: {@perm}
   trigger:
       if arg 1 is not set:
           wait 3 ticks
           set {var} to 0
           set {ize} to size of {arenalist::*}
           if {ize} =< 8:
               open chest with 1 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 17:
               open chest with 2 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 26:
               open chest with 3 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 35:
               open chest with 4 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 44:
               open chest with 5 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 53:
               open chest with 6 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
       else:
           if {arenalist::*} contains arg 1:
               set {slat} to 0
               loop 36 times
                   set {inventory.%arg 1%.%{slat}%} to the slot {slat} of player's inventory
                   add 1 to {slat}
               clear {slat}
               set {helmet.%arg 1%} to player's helmet
               set {chestplate.%arg 1%} to player's chestplate
               set {leggings.%arg 1%} to player's leggings
               set {boots.%arg 1%} to player's boots
               send "&bSauvegarde effectué."
               set {withinv.%arg 1%} to true
               wait 3 ticks
               open chest with 6 rows named "&bApperçu" to player
               set {slat} to 0
               wait 3 ticks
               loop 36 times:
                   format slot {slat} of player with {inventory.%arg 1%.%{slat}%} to close
                   add 1 to {slat}
               format slot 50 of player with {helmet.%arg 1%} to close
               format slot 51 of player with {chestplate.%arg 1%} to close
               format slot 52 of player with {leggings.%arg 1%} to close
               format slot 53 of player with {boots.%arg 1%} to close 
           else:
               send "&cEchec, l'arène %arg 1% n'éxiste pas."
on inventory click:
   slot of clicked item is 44:
       clicked item is a paper named "&cSauvegarder l'inventaire dans l'arène.":
           clear player's inventory
           if %{modif.%player%}% is not set:
               send "&cEchec, vous n'avez aucune arène."
           make player execute command "/setinv %{modif.%player%}%"
   inventory name of current inventory of player is "&6Listes des arènes":
       cancel event
       name of clicked slot is "&eModifier arène":
           set {slot} to slot of clicked item + 1
           close player's inventory
           open a chest with 6 rows named "Paramètres" to player
           format slot 0 of player with book named "&6Définir inventaire" with lore "&eArène %{slot}%" to close
           if {withinv.%{slot}%} is true:
               format slot 1 of player with book named "&bAppercu" to close
           set {modif.%player%} to {slot}
       name of clicked slot is "&6Définir inventaire":
           if {modif.%player%} is set:
               close player's inventory
               send "&6Vous modifier maintenant le contenu de l'arène %{modif.%player%}%" to player
               set slot 44 of player to paper named "&cSauvegarder l'inventaire dans l'arène." with lore "&7Clique droit" to close
       name of clicked slot is "&bApperçu":
           close player's inventory
           open chest with 6 rows named "&bApperçu" to player
           set {slat} to 0
           wait 3 ticks
           loop 36 times:
               format slot {slat} of player with {inventory.%arg 1%.%{slat}%} to close
               add 1 to {slat}
           format slot 50 of player with {helmet.%arg 1%} to close
           format slot 51 of player with {chestplate.%arg 1%} to close
           format slot 52 of player with {leggings.%arg 1%} to close
           format slot 53 of player with {boots.%arg 1%} to close
command /duel [<player>] [<integer>]:
   trigger:
       if {dueled.%player%} is true:
           send "&6Vous êtes en combat."
       else:
           if {dueled.%arg 1%} is false:
               set {ize2} to size of {arenalist::*}
               if {ize2} =< 8:
                   open chest with 1 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 17:
                   open chest with 2 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 26:
                   open chest with 3 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 35:
                   open chest with 4 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 44:
                   open chest with 5 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 53:
                   open chest with 6 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
           else:
               send "&6Le joueur %arg 1% est en combat."
       if arg 2 is set:
           if {withinv.%arg 2%} is true:
               set {wanted.%player%} to arg-1
               send "&6Vous venez de demander en duel &6%arg 1% &esur la map &6%arg 2%"
               send "&e%player% &7vous propose un duel sur la map &6%arg 2%" to arg 1
               send json "&7[&eAccepter&7]" tooltip "&cAccepeter" run "/accept %player% %{loop2}%" to arg 1
command /accept [<player>] [<integer>]:
   trigger:
       if {dueled.%player%} is true:
           send "&6Vous êtes en combat."
       else:
           if {dueled.%arg 1%} is false:
               if {wanted.%arg-1%} is player:
                   set {round.%player%} to 0
                   set {round.%arg 1%} to 0
                   wait 1 tick
                   send "&6Le duel commencer contre %player%" to arg 1
                   send "&6Le duel commence contre %arg 1%" to player
                   wait 1 tick
                   set {dueled.%player%} to true
                   set {dueled.%arg 1%} to true
                   clear player's inventory
                   clear arg 1's inventory
                   wait 1 tick
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of player to {inventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of arg 1 to {inventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   equip arg 1 with {helmet.%arg 2%}
                   equip arg 1 with {chestplate.%arg 2%}
                   equip arg 1 with {leggings.%arg 2%}
                   equip arg 1 with {boots.%arg 2%}
                   equip player with {helmet.%arg 2%}
                   equip player with {chestplate.%arg 2%}
                   equip player with {leggings.%arg 2%}
                   equip player with {boots.%arg 2%}
                   hide all players to player
                   hide all players to arg 1
                   reveal arg 1 to player
                   reveal player to arg 1
                   teleport player to {arena1.%arg 2%}
                   teleport arg 1 to {arena2.%arg 2%}
                   apply slowness 250 to arg 1 for 3 seconds
                   apply slowness 250 to player for 3 seconds
                   send "&eLe match commence dans 3 secondes" to player
                   send "&eLe match commence dans 3 secondes" to arg 1
on death of player:
   attacker is a player
   victim is a player
   if {dueled.%attacker%} is true:
       if {dueled.%victim%} is true:
           if {round.%attacker%} is not 3:
               add 1 to {round.%attacker%}
               wait 1 tick
                   send "&6Le duel commencer contre %player%" to attacker
                   send "&6Le duel commence contre %arg 1%" to victim
                   wait 1 tick
                   set {dueled.%attacker%} to true
                   set {dueled.%victim%} to true
                   clear attacker's inventory
                   clear victim's inventory
                   wait 1 tick
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of attacker to {inventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of victim to {inventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   equip victim with {helmet.%arg 2%}
                   equip victim with {chestplate.%arg 2%}
                   equip victim with {leggings.%arg 2%}
                   equip victim with {boots.%arg 2%}
                   equip victim with {helmet.%arg 2%}
                   equip victim with {chestplate.%arg 2%}
                   equip victim with {leggings.%arg 2%}
                   equip victim with {boots.%arg 2%}
                   hide all players to victim
                   hide all players to attacker
                   reveal attacker to victim
                   reveal victim to attacker
                   teleport attacker to {arena1.%arg 2%}
                   teleport victim to {arena2.%arg 2%}
                   apply slowness 250 to victim for 3 seconds
                   apply slowness 250 to attacker for 3 seconds
                   send "&eLe match commence dans 3 secondes" to player
                   send "&eLe match commence dans 3 secondes" to arg 1
           else:
               broadcast "&e%attacker gagne contre %victim% &7[&c%{round.%attacker%}%/%{round.%victim%}%"
               reveal attacker to all players
               reveal all players to attacker
               heal attacker
               clear attacker's inventory
               clear victim's inventory
               set {dueled.%attacker%} to false
               reveal victim to all players
               reveal all players to victim
               heal victim
               set {dueled.%victim%} to false
               teleport attacker to {lob}
               teleport victim to {lob}
command /setrespawn:
   permission: {@perm}
   trigger:
       set {lob} to player's location
       send "&6Le point de respawn est désormais mis en %{lob}%"
on drop:
   if {dueled.%player%} is true:
       wait 4.5 seconds
       clear dropped items

on load:
   loop all players:
       set {dueled.%loop-player%} to false
on join:
   if {dueled.%player%} is not set:
       set {dueled.%player%} to false
on quit:
   if {dueled.%player%} is true:
       set {dueled.%player%} to false

Si je t'ai aidé mets un like, cela reste un code basique sans complexité ici.

Posté(e)
Alors voilà ce que je t'ai fait:

 

Tu as la possibilité de créer des arènes qui peuvent être configuré entièrement grâce à un menu tel que /setinv <integer>

Tu n'as pas la possibilité de choisir le nom de ton arène.

Exemple:

command /setarena1 <integer>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           arg 1 > 0
           if {max} is not set:
               set {max} to 1
           arg 1 =< {max}
           set {arena1.%arg 1%}
           if {arenalist.%arg 1%::*} does not contains arg 1:
               add arg 1 to {arenalist::*}
           else:
               stop
           message "&eVous venez de saisir de point de spawn numéro &62 &edans l'arène &6%arg 1%."

Pendant un combat le premier arrivé à trois victoire l'emporte.

Tu peux choisir un nombre maximum d'arènes.

Tu peux mettre jusqu' à 53 arènes.

Si tu souhaites des améliorations recontacte moi.

Il est tard donc si il y a des erreurs merci de me pardonner et de m'envoyer un screen des erreurs pour que je puisse corriger cela.

 

options:
   perm: mod
   default:1
command /setarena1 <integer>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           arg 1 > 0
           if {max} is not set:
               set {max} to 1
           arg 1 =< {max}
           set {arena1.%arg 1%}
           if {arenalist.%arg 1%::*} does not contains arg 1:
               add arg 1 to {arenalist::*}
           else:
               stop
           message "&eVous venez de saisir de point de spawn numéro &62 &edans l'arène &6%arg 1%."
command /setarena2 <integer>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           arg 1 > 0
           if {max} is not set:
               set {max} to 1
           arg 1 =< {max}
           set {arena2.%arg 1%}
           if {arenalist.%arg 1%::*} does not contains arg 1:
               add arg 1 to {arenalist::*}
           else:
               stop
           message "&eVous venez de saisir de point de spawn numéro &62 &edans l'arène &6%arg 1%."
command /maxarenas <integer>:
   permission: {@perm}
   trigger:
       if arg 1 is not set:
           message "&eLe nombre maximum d'arène vient d'être mis à defaut: {@default}"
           set {max} to 1
       else:
           message "&eLe nombre maximum d'arène vient d'être mis à: %arg 1%"
           set {max} to 1
command /setinv [<integer>]:
   permisison: {@perm}
   trigger:
       if arg 1 is not set:
           wait 3 ticks
           set {var} to 0
           set {ize} to size of {arenalist::*}
           if {ize} =< 8:
               open chest with 1 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 17:
               open chest with 2 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 26:
               open chest with 3 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 35:
               open chest with 4 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 44:
               open chest with 5 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
           else if {ize} =< 53:
               open chest with 6 rows named "&6Listes des arènes" to player
               loop {arenalist::*}:
                   set {loop} to loop-value
                   format slot {var} of player with book named "&eModifier arène" with lore "&7Arène %{loop}%" to close
                   add 1 to {var}
       else:
           if {arenalist::*} contains arg 1:
               set {slat} to 0
               loop 36 times
                   set {inventory.%arg 1%.%{slat}%} to the slot {slat} of player's inventory
                   add 1 to {slat}
               clear {slat}
               set {helmet.%arg 1%} to player's helmet
               set {chestplate.%arg 1%} to player's chestplate
               set {leggings.%arg 1%} to player's leggings
               set {boots.%arg 1%} to player's boots
               send "&bSauvegarde effectué."
               set {withinv.%arg 1%} to true
               wait 3 ticks
               open chest with 6 rows named "&bApperçu" to player
               set {slat} to 0
               wait 3 ticks
               loop 36 times:
                   format slot {slat} of player with {inventory.%arg 1%.%{slat}%} to close
                   add 1 to {slat}
               format slot 50 of player with {helmet.%arg 1%} to close
               format slot 51 of player with {chestplate.%arg 1%} to close
               format slot 52 of player with {leggings.%arg 1%} to close
               format slot 53 of player with {boots.%arg 1%} to close
           else:
               send "&cEchec, l'arène %arg 1% n'éxiste pas."
on inventory click:
   slot of clicked item is 44:
       clicked item is a paper named "&cSauvegarder l'inventaire dans l'arène.":
           clear player's inventory
           if %{modif.%player%}% is not set:
               send "&cEchec, vous n'avez aucune arène."
           make player execute command "/setinv %{modif.%player%}%"
   inventory name of current inventory of player is "&6Listes des arènes":
       cancel event
       name of clicked slot is "&eModifier arène":
           set {slot} to slot of clicked item + 1
           close player's inventory
           open a chest with 6 rows named "Paramètres" to player
           format slot 0 of player with book named "&6Définir inventaire" with lore "&eArène %{slot}%" to close
           if {withinv.%{slot}%} is true:
               format slot 1 of player with book named "&bAppercu" to close
           set {modif.%player%} to {slot}
       name of clicked slot is "&6Définir inventaire":
           if {modif.%player%} is set:
               close player's inventory
               send "&6Vous modifier maintenant le contenu de l'arène %{modif.%player%}%" to player
               set slot 44 of player to paper named "&cSauvegarder l'inventaire dans l'arène." with lore "&7Clique droit" to close
       name of clicked slot is "&bApperçu":
           close player's inventory
           open chest with 6 rows named "&bApperçu" to player
           set {slat} to 0
           wait 3 ticks
           loop 36 times:
               format slot {slat} of player with {inventory.%arg 1%.%{slat}%} to close
               add 1 to {slat}
           format slot 50 of player with {helmet.%arg 1%} to close
           format slot 51 of player with {chestplate.%arg 1%} to close
           format slot 52 of player with {leggings.%arg 1%} to close
           format slot 53 of player with {boots.%arg 1%} to close
command /duel [<player>] [<integer>]:
   trigger:
       if {dueled.%player%} is true:
           send "&6Vous êtes en combat."
       else:
           if {dueled.%arg 1%} is false:
               set {ize2} to size of {arenalist::*}
               if {ize2} =< 8:
                   open chest with 1 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 17:
                   open chest with 2 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 26:
                   open chest with 3 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 35:
                   open chest with 4 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 44:
                   open chest with 5 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       if {withinv.%{loop2}%} is true:
                           format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
               if {ize2} =< 53:
                   open chest with 6 rows named "&eChoix de l'arène" to player
                   wait 3 ticks
                   set {slat} to 0
                   loop {arenalist::*}:
                       set {loop2} to loop-value
                       format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
           else:
               send "&6Le joueur %arg 1% est en combat."
       if arg 2 is set:
           if {withinv.%arg 2%} is true:
               set {wanted.%player%} to arg-1
               send "&6Vous venez de demander en duel &6%arg 1% &esur la map &6%arg 2%"
               send "&e%player% &7vous propose un duel sur la map &6%arg 2%" to arg 1
               send json "&7[&eAccepter&7]" tooltip "&cAccepeter" run "/accept %player% %{loop2}%" to arg 1
command /accept [<player>] [<integer>]:
   trigger:
       if {dueled.%player%} is true:
           send "&6Vous êtes en combat."
       else:
           if {dueled.%arg 1%} is false:
               if {wanted.%arg-1%} is player:
                   set {round.%player%} to 0
                   set {round.%arg 1%} to 0
                   wait 1 tick
                   send "&6Le duel commencer contre %player%" to arg 1
                   send "&6Le duel commence contre %arg 1%" to player
                   wait 1 tick
                   set {dueled.%player%} to true
                   set {dueled.%arg 1%} to true
                   clear player's inventory
                   clear arg 1's inventory
                   wait 1 tick
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of player to {inventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of arg 1 to {inventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   equip arg 1 with {helmet.%arg 2%}
                   equip arg 1 with {chestplate.%arg 2%}
                   equip arg 1 with {leggings.%arg 2%}
                   equip arg 1 with {boots.%arg 2%}
                   equip player with {helmet.%arg 2%}
                   equip player with {chestplate.%arg 2%}
                   equip player with {leggings.%arg 2%}
                   equip player with {boots.%arg 2%}
                   hide all players to player
                   hide all players to arg 1
                   reveal arg 1 to player
                   reveal player to arg 1
                   teleport player to {arena1.%arg 2%}
                   teleport arg 1 to {arena2.%arg 2%}
                   apply slowness 250 to arg 1 for 3 seconds
                   apply slowness 250 to player for 3 seconds
                   send "&eLe match commence dans 3 secondes" to player
                   send "&eLe match commence dans 3 secondes" to arg 1
on death of player:
   attacker is a player
   victim is a player
   if {dueled.%attacker%} is true:
       if {dueled.%victim%} is true:
           if {round.%attacker%} is not 3:
               add 1 to {round.%attacker%}
               wait 1 tick
                   send "&6Le duel commencer contre %player%" to attacker
                   send "&6Le duel commence contre %arg 1%" to victim
                   wait 1 tick
                   set {dueled.%attacker%} to true
                   set {dueled.%victim%} to true
                   clear attacker's inventory
                   clear victim's inventory
                   wait 1 tick
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of attacker to {inventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of victim to {inventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   equip victim with {helmet.%arg 2%}
                   equip victim with {chestplate.%arg 2%}
                   equip victim with {leggings.%arg 2%}
                   equip victim with {boots.%arg 2%}
                   equip victim with {helmet.%arg 2%}
                   equip victim with {chestplate.%arg 2%}
                   equip victim with {leggings.%arg 2%}
                   equip victim with {boots.%arg 2%}
                   hide all players to victim
                   hide all players to attacker
                   reveal attacker to victim
                   reveal victim to attacker
                   teleport attacker to {arena1.%arg 2%}
                   teleport victim to {arena2.%arg 2%}
                   apply slowness 250 to victim for 3 seconds
                   apply slowness 250 to attacker for 3 seconds
                   send "&eLe match commence dans 3 secondes" to player
                   send "&eLe match commence dans 3 secondes" to arg 1
           else:
               broadcast "&e%attacker gagne contre %victim% &7[&c%{round.%attacker%}%/%{round.%victim%}%"
               reveal attacker to all players
               reveal all players to attacker
               heal attacker
               clear attacker's inventory
               clear victim's inventory
               set {dueled.%attacker%} to false
               reveal victim to all players
               reveal all players to victim
               heal victim
               set {dueled.%victim%} to false
               teleport attacker to {lob}
               teleport victim to {lob}
command /setrespawn:
   permission: {@perm}
   trigger:
       set {lob} to player's location
       send "&6Le point de respawn est désormais mis en %{lob}%"
on drop:
   if {dueled.%player%} is true:
       wait 4.5 seconds
       clear dropped items

on load:
   loop all players:
       set {dueled.%loop-player%} to false
on join:
   if {dueled.%player%} is not set:
       set {dueled.%player%} to false
on quit:
   if {dueled.%player%} is true:
       set {dueled.%player%} to false

Si je t'ai aidé mets un like, cela reste un code basique sans complexité ici.

Ok, mais as-tu fait toutes les conditions ? Et pour le nom de l'arène c'est plutôt gênant.. :/

Sinon merci beaucoup !

ou au pire, https://skript-mc.fr/forum/threads/practice-1-8.9161/ ou https://skript-mc.fr/forum/threads/practice-duel.5799/ :)

 

Amicalement,

noftaly

 

PS: Je sais que ce n'est pas une copie du plugin 1v1, mais comme il est plus complet... et ya la possibilité de poser des blocks, et puis que l'arène soit reset.

Si je fais un post dans demande de skript c'est que j'ai déjà cherché et déjà trouvé des choses, mais là je veux 1vs1 en skript ! pas PvPRankep ou autre !

Posté(e)

Correction:

 

Nom des arènes possibles à choisir.

Correction des erreurs dûent à "clicked item"

amélioration fluidité du gui.

 

Possibilité de supprimer une arène.

Ajout de case 'retour' pour améliorer la fluidité et l'éfficassité.

 

ADD-ONS: SkQuery, SkRayFall, WildSkript, Umbaska (les miens)

*possible seulement avec SkQuery

-239 lignes

 

 

-'/maxarenas' a été supprimé car les arènes ne se nomment pas en integer.

- ajout '/menu' alternative qui remplace 'clicked item'

Des ajouts, répondre à ce commentaire avec votre idée.

 

options:
   perm: mod

command /setarena1 <text>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           set {aarena1.%arg 1%} to player's location
           {aarena.%arg 1%} is not set:
               add arg 1 to {aarenalist::*}
           set {aarena.%arg 1%} to "on"
           message "&eVous venez de saisir de point de spawn numéro &61 &edans l'arène &6%arg 1%."
command /setarena2 <text>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           set {aarena2.%arg 1%} to player's location
           {aarena.%arg 1%} is not set:
               add arg 1 to {aarenalist::*}
           set {aarena.%arg 1%} to "on"
           message "&eVous venez de saisir de point de spawn numéro &62 &edans l'arène &6%arg 1%."
command /setinv [<text>]:
   permission: {@perm}
   trigger:
       if arg 1 is not set:
           wait 3 ticks
           set {var} to 0
           set {ize} to size of {aarenalist::*}
           open chest with 6 rows named "&6Listes des arènes" to player
           loop {aarenalist::*}:
               set {loop} to loop-value
               format slot {var} of player with book named "&eModifier arène %{loop}%" to close then run [make player execute command "/menu %{loop}% settings"]
               add 1 to {var}
       else:
           if {aarenalist::*} contains arg 1:
               set {slat} to 0
               loop 36 times:
                   set {ainventory.%arg 1%.%{slat}%} to the slot {slat} of player's inventory
                   add 1 to {slat}
               clear {slat}
               set {ahelmet.%arg 1%} to player's helmet
               set {achestplate.%arg 1%} to player's chestplate
               set {aleggings.%arg 1%} to player's leggings
               set {aboots.%arg 1%} to player's boots
               send "&bSauvegarde effectué."
               set {withinv.%arg 1%} to true
               wait 3 ticks
               open chest with 6 rows named "&bApperçu" to player
               set {slat} to 0
               wait 3 ticks
               loop 36 times:
                   format slot {slat} of player with {ainventory.%arg 1%.%{slat}%} to close
                   add 1 to {slat}
               format slot 50 of player with {ahelmet.%arg 1%} to close
               format slot 51 of player with {achestplate.%arg 1%} to close
               format slot 52 of player with {aleggings.%arg 1%} to close
               format slot 53 of player with {aboots.%arg 1%} to close
           else:
               send "&cEchec, l'arène %arg 1% n'éxiste pas."
command /menu [<text>] [<text>]:
   permission: {@perm}
   trigger:
       if {aarena.%arg 1%} is set:
           if arg 2 is "settings":
               wait 3 ticks
               open chest with 1 rows named "&6Paramètres" to player
               wait 3 ticks
               format slot 0 of player with book named "&eChanger l'inventaire %arg 1%" with lore "&7Arène %arg 1%" to close then run [make player execute command "/setinv %arg 1%"]
               format slot 1 of player with book named "&eAperçu" to close then run [make player execute command "/menu %arg 1% view"]
               format slot 7 of player with red wool named "&7Retour" to close then run [make player execute command "/setinv"]
               format slot 8 of player with 166 named "&cSupprimer" to close then run [make player execute command "/menu %arg 1% delete"]
           if arg 2 is "view":
               wait 3 ticks
               open chest with 6 rows named "&6Aperçu" to player
               wait 3 ticks
               set {slat} to 0
               loop 36 times:
                   format slot {slat} of player with {ainventory.%arg 1%.%{slat}%} to be unstealable
                   add 1 to {slat}
               format slot 50 of player with {ahelmet.%arg 1%} to close
               format slot 51 of player with {achestplate.%arg 1%} to close
               format slot 52 of player with {aleggings.%arg 1%} to close
               format slot 53 of player with {aboots.%arg 1%} to close
               format slot 44 of player with red wool named "&7Retour" to close then run [make player execute command "/menu %arg 1% settings"]
           if arg 2 is "delete":
               remove arg 1 from {aarenalist::*}
               clear {aarena.%arg 1%}
               make player execute command "/setinv"
               delete {name.%arg 1%}
on chat:
   if {chat.name.%player%} is true:
       set {n2.%{n}%} to "%message%"
       clear {chat.name.%player%}
   else:
       cancel event
       broadcast "&a%player%&7: %message%"
command /duel [<player>] [<integer>]:
   trigger:
       if {dueled.%player%} is true:
           send "&6Vous êtes en combat."
       else:
           if {dueled.%arg 1%} is false:
               set {ize2} to size of {aarenalist::*}
               open chest with 1 rows named "&eChoix de l'arène" to player
               wait 3 ticks
               set {slat} to 0
               loop {aarenalist::*}:
                   set {loop2} to loop-value
                   if {withinv.%{loop2}%} is true:
                       format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
           else:
               send "&6Le joueur %arg 1% est en combat."
       if arg 2 is set:
           if {withinv.%arg 2%} is true:
               set {wanted.%player%} to arg-1
               send "&6Vous venez de demander en duel &6%arg 1% &esur la map &6%arg 2%"
               send "&e%player% &7vous propose un duel sur la map &6%arg 2%" to arg 1
               send json "&7[&eAccepter&7]" tooltip "&cAccepeter" run "/accept %player% %{loop2}%" to arg 1
command /accept [<player>] [<integer>]:
   trigger:
       if {adueled.%player%} is true:
           send "&6Vous êtes en combat."
       else:
           if {adueled.%arg 1%} is false:
               if {wanted.%arg-1%} is player:
                   set {arena.%player%} to arg 2
                   set {arena.%arg 2%} to arg 2
                   set {round.%player%} to 0
                   set {round.%arg 1%} to 0
                   wait 1 tick
                   send "&6Le duel commencer contre %player%" to arg 1
                   send "&6Le duel commence contre %arg 1%" to player
                   wait 1 tick
                   set {adueled.%player%} to true
                   set {adueled.%arg 1%} to true
                   clear player's inventory
                   clear arg 1's inventory
                   wait 1 tick
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of player to {ainventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of arg 1 to {ainventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   equip arg 1 with {ahelmet.%arg 2%}
                   equip arg 1 with {achestplate.%arg 2%}
                   equip arg 1 with {aleggings.%arg 2%}
                   equip arg 1 with {aboots.%arg 2%}
                   equip player with {ahelmet.%arg 2%}
                   equip player with {achestplate.%arg 2%}
                   equip player with {aleggings.%arg 2%}
                   equip player with {aboots.%arg 2%}
                   hide all players to player
                   hide all players to arg 1
                   reveal arg 1 to player
                   reveal player to arg 1
                   teleport player to {aarena1.%arg 2%}
                   teleport arg 1 to {aarena2.%arg 2%}
                   apply slowness 250 to arg 1 for 3 seconds
                   apply slowness 250 to player for 3 seconds
                   send "&eLe match commence dans 3 secondes" to player
                   send "&eLe match commence dans 3 secondes" to arg 1
on death of player:
   attacker is a player
   victim is a player
   if {dueled.%attacker%} is true:
       if {dueled.%victim%} is true:
           if {round.%attacker%} is not 3:
               add 1 to {round.%attacker%}
               wait 1 tick
               send "&6Le duel commencer contre %victim%" to attacker
               send "&6Le duel commence contre %attacker%" to victim
               wait 1 tick
               set {adueled.%attacker%} to true
               set {adueled.%victim%} to true
               clear attacker's inventory
               clear victim's inventory
               wait 1 tick
               set {slat} to 0
               loop 36 times:
                   set slot {slat} of attacker to {ainventory.%{arena.%attacker%}%.%{slat}%}
                   add 1 to {slat}
               set {slat} to 0
               loop 36 times:
                   set slot {slat} of victim to {ainventory.%{arena.%attacker%}%.%{slat}%}
                   add 1 to {slat}
               equip victim with {ahelmet.%{arena.%victim%}%}
               equip victim with {achestplate.%{arena.%victim%}%}
               equip victim with {aleggings.%{arena.%victim%}%}
               equip victim with {aboots.%{arena.%victim%}%}
               equip victim with {ahelmet.%{arena.%victim%}%}
               equip victim with {achestplate.%{arena.%victim%}%}
               equip victim with {leggings.%{arena.%victim%}%}
               equip victim with {aboots.%{arena.%victim%}%}
               hide all players to victim
               hide all players to attacker
               reveal attacker to victim
               reveal victim to attacker
               teleport attacker to {arena1.%{arena.%attacker%}%}
               teleport victim to {arena2.%{arena.%attacker%}%}
               apply slowness 250 to victim for 3 seconds
               apply slowness 250 to attacker for 3 seconds
               send "&eLe match commence dans 3 secondes" to victim
               send "&eLe match commence dans 3 secondes" to attacker
           else:
               broadcast "&e%attacker% gagne contre %victim% &7[&c%{round.%attacker%}%/%{round.%victim%}%"
               reveal attacker to all players
               reveal all players to attacker
               heal attacker
               clear attacker's inventory
               clear victim's inventory
               set {dueled.%attacker%} to false
               reveal victim to all players
               reveal all players to victim
               heal victim
               set {dueled.%victim%} to false
               teleport attacker to {lob}
               teleport victim to {lob}
command /setrespawn:
   permission: {@perm}
   trigger:
       set {lob} to player's location
       send "&6Le point de respawn est désormais mis en %{lob}%"
on drop:
   if {adueled.%player%} is true:
       wait 4.5 seconds
       clear dropped items

on load:
   loop all players:
       set {adueled.%loop-player%} to false
on join:
   if {adueled.%player%} is not set:
       set {adueled.%player%} to false
on quit:
   if {adueled.%player%} is true:
       set {adueled.%player%} to false

Posté(e)
Correction:

 

Nom des arènes possibles à choisir.

Correction des erreurs dûent à "clicked item"

amélioration fluidité du gui.

 

Possibilité de supprimer une arène.

Ajout de case 'retour' pour améliorer la fluidité et l'éfficassité.

 

ADD-ONS: SkQuery, SkRayFall, WildSkript, Umbaska (les miens)

*possible seulement avec SkQuery

-239 lignes

 

 

-'/maxarenas' a été supprimé car les arènes ne se nomment pas en integer.

- ajout '/menu' alternative qui remplace 'clicked item'

Des ajouts, répondre à ce commentaire avec votre idée.

 

options:
   perm: mod

command /setarena1 <text>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           set {aarena1.%arg 1%} to player's location
           {aarena.%arg 1%} is not set:
               add arg 1 to {aarenalist::*}
           set {aarena.%arg 1%} to "on"
           message "&eVous venez de saisir de point de spawn numéro &61 &edans l'arène &6%arg 1%."
command /setarena2 <text>:
   permission: {@perm}
   trigger:
       if arg 1 is set:
           set {aarena2.%arg 1%} to player's location
           {aarena.%arg 1%} is not set:
               add arg 1 to {aarenalist::*}
           set {aarena.%arg 1%} to "on"
           message "&eVous venez de saisir de point de spawn numéro &62 &edans l'arène &6%arg 1%."
command /setinv [<text>]:
   permission: {@perm}
   trigger:
       if arg 1 is not set:
           wait 3 ticks
           set {var} to 0
           set {ize} to size of {aarenalist::*}
           open chest with 6 rows named "&6Listes des arènes" to player
           loop {aarenalist::*}:
               set {loop} to loop-value
               format slot {var} of player with book named "&eModifier arène %{loop}%" to close then run [make player execute command "/menu %{loop}% settings"]
               add 1 to {var}
       else:
           if {aarenalist::*} contains arg 1:
               set {slat} to 0
               loop 36 times:
                   set {ainventory.%arg 1%.%{slat}%} to the slot {slat} of player's inventory
                   add 1 to {slat}
               clear {slat}
               set {ahelmet.%arg 1%} to player's helmet
               set {achestplate.%arg 1%} to player's chestplate
               set {aleggings.%arg 1%} to player's leggings
               set {aboots.%arg 1%} to player's boots
               send "&bSauvegarde effectué."
               set {withinv.%arg 1%} to true
               wait 3 ticks
               open chest with 6 rows named "&bApperçu" to player
               set {slat} to 0
               wait 3 ticks
               loop 36 times:
                   format slot {slat} of player with {ainventory.%arg 1%.%{slat}%} to close
                   add 1 to {slat}
               format slot 50 of player with {ahelmet.%arg 1%} to close
               format slot 51 of player with {achestplate.%arg 1%} to close
               format slot 52 of player with {aleggings.%arg 1%} to close
               format slot 53 of player with {aboots.%arg 1%} to close
           else:
               send "&cEchec, l'arène %arg 1% n'éxiste pas."
command /menu [<text>] [<text>]:
   permission: {@perm}
   trigger:
       if {aarena.%arg 1%} is set:
           if arg 2 is "settings":
               wait 3 ticks
               open chest with 1 rows named "&6Paramètres" to player
               wait 3 ticks
               format slot 0 of player with book named "&eChanger l'inventaire %arg 1%" with lore "&7Arène %arg 1%" to close then run [make player execute command "/setinv %arg 1%"]
               format slot 1 of player with book named "&eAperçu" to close then run [make player execute command "/menu %arg 1% view"]
               format slot 7 of player with red wool named "&7Retour" to close then run [make player execute command "/setinv"]
               format slot 8 of player with 166 named "&cSupprimer" to close then run [make player execute command "/menu %arg 1% delete"]
           if arg 2 is "view":
               wait 3 ticks
               open chest with 6 rows named "&6Aperçu" to player
               wait 3 ticks
               set {slat} to 0
               loop 36 times:
                   format slot {slat} of player with {ainventory.%arg 1%.%{slat}%} to be unstealable
                   add 1 to {slat}
               format slot 50 of player with {ahelmet.%arg 1%} to close
               format slot 51 of player with {achestplate.%arg 1%} to close
               format slot 52 of player with {aleggings.%arg 1%} to close
               format slot 53 of player with {aboots.%arg 1%} to close
               format slot 44 of player with red wool named "&7Retour" to close then run [make player execute command "/menu %arg 1% settings"]
           if arg 2 is "delete":
               remove arg 1 from {aarenalist::*}
               clear {aarena.%arg 1%}
               make player execute command "/setinv"
               delete {name.%arg 1%}
on chat:
   if {chat.name.%player%} is true:
       set {n2.%{n}%} to "%message%"
       clear {chat.name.%player%}
   else:
       cancel event
       broadcast "&a%player%&7: %message%"
command /duel [<player>] [<integer>]:
   trigger:
       if {dueled.%player%} is true:
           send "&6Vous êtes en combat."
       else:
           if {dueled.%arg 1%} is false:
               set {ize2} to size of {aarenalist::*}
               open chest with 1 rows named "&eChoix de l'arène" to player
               wait 3 ticks
               set {slat} to 0
               loop {aarenalist::*}:
                   set {loop2} to loop-value
                   if {withinv.%{loop2}%} is true:
                       format slot {slat} of player with paper named "&eArena %{loop2}%" to close then run [make player execute command "/duel %arg 1% %{loop2}%"]
           else:
               send "&6Le joueur %arg 1% est en combat."
       if arg 2 is set:
           if {withinv.%arg 2%} is true:
               set {wanted.%player%} to arg-1
               send "&6Vous venez de demander en duel &6%arg 1% &esur la map &6%arg 2%"
               send "&e%player% &7vous propose un duel sur la map &6%arg 2%" to arg 1
               send json "&7[&eAccepter&7]" tooltip "&cAccepeter" run "/accept %player% %{loop2}%" to arg 1
command /accept [<player>] [<integer>]:
   trigger:
       if {adueled.%player%} is true:
           send "&6Vous êtes en combat."
       else:
           if {adueled.%arg 1%} is false:
               if {wanted.%arg-1%} is player:
                   set {arena.%player%} to arg 2
                   set {arena.%arg 2%} to arg 2
                   set {round.%player%} to 0
                   set {round.%arg 1%} to 0
                   wait 1 tick
                   send "&6Le duel commencer contre %player%" to arg 1
                   send "&6Le duel commence contre %arg 1%" to player
                   wait 1 tick
                   set {adueled.%player%} to true
                   set {adueled.%arg 1%} to true
                   clear player's inventory
                   clear arg 1's inventory
                   wait 1 tick
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of player to {ainventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   set {slat} to 0
                   loop 36 times:
                       set slot {slat} of arg 1 to {ainventory.%arg 2%.%{slat}%}
                       add 1 to {slat}
                   equip arg 1 with {ahelmet.%arg 2%}
                   equip arg 1 with {achestplate.%arg 2%}
                   equip arg 1 with {aleggings.%arg 2%}
                   equip arg 1 with {aboots.%arg 2%}
                   equip player with {ahelmet.%arg 2%}
                   equip player with {achestplate.%arg 2%}
                   equip player with {aleggings.%arg 2%}
                   equip player with {aboots.%arg 2%}
                   hide all players to player
                   hide all players to arg 1
                   reveal arg 1 to player
                   reveal player to arg 1
                   teleport player to {aarena1.%arg 2%}
                   teleport arg 1 to {aarena2.%arg 2%}
                   apply slowness 250 to arg 1 for 3 seconds
                   apply slowness 250 to player for 3 seconds
                   send "&eLe match commence dans 3 secondes" to player
                   send "&eLe match commence dans 3 secondes" to arg 1
on death of player:
   attacker is a player
   victim is a player
   if {dueled.%attacker%} is true:
       if {dueled.%victim%} is true:
           if {round.%attacker%} is not 3:
               add 1 to {round.%attacker%}
               wait 1 tick
               send "&6Le duel commencer contre %victim%" to attacker
               send "&6Le duel commence contre %attacker%" to victim
               wait 1 tick
               set {adueled.%attacker%} to true
               set {adueled.%victim%} to true
               clear attacker's inventory
               clear victim's inventory
               wait 1 tick
               set {slat} to 0
               loop 36 times:
                   set slot {slat} of attacker to {ainventory.%{arena.%attacker%}%.%{slat}%}
                   add 1 to {slat}
               set {slat} to 0
               loop 36 times:
                   set slot {slat} of victim to {ainventory.%{arena.%attacker%}%.%{slat}%}
                   add 1 to {slat}
               equip victim with {ahelmet.%{arena.%victim%}%}
               equip victim with {achestplate.%{arena.%victim%}%}
               equip victim with {aleggings.%{arena.%victim%}%}
               equip victim with {aboots.%{arena.%victim%}%}
               equip victim with {ahelmet.%{arena.%victim%}%}
               equip victim with {achestplate.%{arena.%victim%}%}
               equip victim with {leggings.%{arena.%victim%}%}
               equip victim with {aboots.%{arena.%victim%}%}
               hide all players to victim
               hide all players to attacker
               reveal attacker to victim
               reveal victim to attacker
               teleport attacker to {arena1.%{arena.%attacker%}%}
               teleport victim to {arena2.%{arena.%attacker%}%}
               apply slowness 250 to victim for 3 seconds
               apply slowness 250 to attacker for 3 seconds
               send "&eLe match commence dans 3 secondes" to victim
               send "&eLe match commence dans 3 secondes" to attacker
           else:
               broadcast "&e%attacker% gagne contre %victim% &7[&c%{round.%attacker%}%/%{round.%victim%}%"
               reveal attacker to all players
               reveal all players to attacker
               heal attacker
               clear attacker's inventory
               clear victim's inventory
               set {dueled.%attacker%} to false
               reveal victim to all players
               reveal all players to victim
               heal victim
               set {dueled.%victim%} to false
               teleport attacker to {lob}
               teleport victim to {lob}
command /setrespawn:
   permission: {@perm}
   trigger:
       set {lob} to player's location
       send "&6Le point de respawn est désormais mis en %{lob}%"
on drop:
   if {adueled.%player%} is true:
       wait 4.5 seconds
       clear dropped items

on load:
   loop all players:
       set {adueled.%loop-player%} to false
on join:
   if {adueled.%player%} is not set:
       set {adueled.%player%} to false
on quit:
   if {adueled.%player%} is true:
       set {adueled.%player%} to false

Super ! Je verrais en détail ce soir mais sinon j'avais oublié de préciser qu'il faut faire en sorte que le joueur en combat ne puisse pas drop son staff et ne puisse pas faire de commande. Aussi il ne faut pas que quand 2 autres players se duel ils aillent dans l'arène ou il y a un combat, et ça je ne sais pas si c'est bon ?

 

Autrement un grand merci à toi je vois en détail ce soir.

Posté(e)
Les joueurs en combat ne voient que leur adversaire. Meme si il y a 5 combats sur la même arène ils ne se verront que par deux.

Ils ne se verront juste pas ou ne pourront aussi pas se taper ?

Sinon aucune erreur, merci beaucoup !

  • 2 semaines après...
×
×
  • 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.