Aller au contenu

Question

Posté(e)

Bonjour, Bonsoir,

 

J'ai un problème sur un skript repris sur YouTube

 

c uiun hungergames tous marche sauf le remplissage de coffres et la fin quand il reste que 1 joueur la partie continue :

 

options:
   Bungeecord: False
   Jeu_Name: HungerGames
   MsgJoin: &9[&6HungerGames&9] &aVous avez rejoint la partie !
   MsgJoinOther: &9[&6HungerGames&9] &7%player% a rejoint la partie !  &5(%size of {FilePlayer::*}% / 4)
   NbrStart: 1
   NbrMax: 4
   Debut30: &9[&6HungerGames&9] &6Début dans 30 secondes !
   Debut15: &9[&6HungerGames&9] &6Début dans 15 secondes !
   Debut10: &9[&6HungerGames&9] &6Début dans 10 secondes !
   Debut5: &9[&6HungerGames&9] &6Début dans 5 secondes !
   Debut4: &9[&6HungerGames&9] &6Début dans 4 secondes !
   Debut3: &9[&6HungerGames&9] &6Début dans 3 secondes !
   Debut2: &9[&6HungerGames&9] &6Début dans 2 secondes !
   Debut1: &9[&6HungerGames&9] &6Début dans 1 seconde !
   Annulé: &9[&6HungerGames&9] &cCompte à rebours annulé : Pas assez de personnes &8(%size of {FilePlayer::*}% / 4) !
   World: hg
   MortAttacker: &9[&6HungerGames&9] &c%victim% &6est mort de la main de &a%attacker%
   MortOther: &9[&6HungerGames&9] &c%victim% &6est mort !
   MortJoueur: &9[&6HungerGames&9] &cVous êtes mort !
   MsgQuit: &9[&6HungerGames&9] &7Vous avez &cquitté &7la partie !
   MsgQuitOther: &9[&6HungerGames&9] &7%player% a &cquitté &7la partie !  &5(%size of {FilePlayer::*}% / 20)
   EnCours: &9[&6HungerGames&9] &7La partie est en cours !
   Win: &9[&6HungerGames&9] &5%loop-value% a gagné !
   Full: &9[&6HungerGames&9] &cLa partie est complete !
   RadiusMap: 10
on join:
   set {_bungee} to "{@Bungeecord}"
   {_bungee} is "true"
   make player execute command "/§gamejoin"






command /hg:
   trigger:
       set {_bungee} to "{@Bungeecord}"
       {_bungee} isn't "true"
       player's world is "{@World}"
       open chest with 1 rows named "&6Menu" to player
       wait 1 tick
       format slot 4 of player with a diamond named "&aRejoindre le &6HungerGames" to run [make player execute command "/gamejoin"]
on right click with a bed:
   player is holding a bed named "&cRetour au hub"
   player's world is "{@World}"
   make player execute command "/§gamequit"
on quit:
   make player execute command "/§gamequit"
on death:
   victim's world is "%{@World}%"
   send "{@MortJoueur}" to victim
   set death message to ""
   loop {FilePlayer::*}:
       loop-value is a player
       if attacker is a player:
           send "{@MortAttacker}" to loop-value
   remove victim from {FilePlayer::*}
   make victim execute command "/§gamequitmort"
   damage was caused by lava, fire, fall or burning:
       loop {FilePlayer::*}:
           loop-value is a player
           send "{@MortOther}" to loop-value
command /setpos [<text>] [<number>]:
   permission: op
   permission message: &cTu n'as pas la permission
   trigger:
       if arg 1 is not set:
           send "&cUsage: /setpos [File/Spawn/Centre]"
           stop
       if arg 1 is not "File" or "spawn" or "Centre":
           send "&cUsage: /setpos [File/Spawn/Centre]"
           stop
       if arg 1 is "File":
           set {File} to player's location
           send "&aPosition de téléportation défini (File)"
           stop
       if arg 1 is "Spawn":
           if arg 2 is not set:
               send "&cUsage: /setpos Spawn Nombre"
               stop
           else:

               set {Spawn.%number-arg%} to player's location
               send "&aPosition de téléportation défini (Spawn n° %arg 2%)"
       if arg 1 is "Centre":
           set {Centre} to player's location
           send "&aPosition du centre bien défini :D"

command /gamejoin:
   trigger:
       if {InGame} is not set:
           set player's gamemode to survival
           if {InFile.%player%} is not set:
               if size of {FilePlayer::*} > {@NbrMax}:
                   send "{@Full}"
                   stop
               else:
                   player's world is "%{@World}%"
                   set {LastPos.%player%} to player's location
                   set {InFile.%player%} to true
                   add player to {FilePlayer::*}
                   teleport player to {File}
                   set slot 8 of player to a bed named "&cRetour au hub"
                   wait 1 tick
                   loop {FilePlayer::*}:
                       loop-value is a player
                       send "{@MsgJoinOther}" to loop-value
                   send "{@MsgJoin}" to player
                   make player execute command "/§consolestart"
           else:
               send "&cTu es dans la file"
               stop
       else:
           send "{@EnCours}" to player
           make console execute command "/gamemode %player% spectator"
command /§gamequit:
   trigger:
       player's world is {@World}
       clear {cantmoove.%player%}
       if {InGame} is not set:
           if {InWait} is set:
               if size of {FilePlayer::*} = 2:
                   if {InFile.%player%} is true:
                       clear {InWait}
                       clear {InFile.%player%}
                       remove player from {FilePlayer::*}
                       teleport player to {LastPos.%player%}
                       clear sender's inventory
                       loop {FilePlayer::*}:
                           send "{@MsgQuitOther}" to loop-value
                       send  "{@MsgQuit}" to sender
           else:
               if {InFile.%player%} is true:
                   clear {InWait}
                   clear {InFile.%player%}
                   remove player from {FilePlayer::*}
                   teleport player to {LastPos.%player%}
                   clear sender's inventory
                   loop {FilePlayer::*}:
                       send "{@MsgQuitOther}" to loop-value
                       send  "{@MsgQuit}" to sender
               else if {InFile.%player%} is not set:
                   send "&cTu n'es pas dans la file"
       else:
           if {InFile.%player%} is true:
               remove player from {FilePlayer::*}
               clear {InFile.%player%}
               teleport player to {LastPos.%player%}
               clear sender's inventory
               loop {FilePlayer::*}:
                   loop-value is a player
                   send "{@MsgQuitOther}" to loop-value
               send  "{@MsgQuit}" to sender
               if size of {FilePlayer::*} = 1:
                   loop {FilePlayer::*}:
                       clear {cantmoove.%loop-value%}
                       clear loop-value's inventory
                       loop-value is a player
                       broadcast "{@Win}"
                       heal loop-value
                       clear {InFile.%loop-value%}
                       teleport loop-value to {LastPos.%loop-value%}
                       clear {FilePlayer::*}
                       clear {InGame}
           else if {InFile.%player%} is not set:
               send "&cTu n'es pas dans la file"
on damage:
   victim's world is {@World}
   if {InWait} is set:
       cancel event
   if {InGame} is not set:
       cancel event
command /§gamequitmort:
   trigger:
       player's world is {@World}
       clear {cantmoove.%player%}
       make console execute command "/gamemode %player% spectator"
       if {InFile.%player%} is true:
           remove player from {FilePlayer::*}
           clear {InFile.%player%}
           teleport player to {LastPos.%player%}
           clear sender's inventory
           if size of {FilePlayer::*} = 1:
               loop {FilePlayer::*}:
                   clear loop-value's inventory
                   clear {cantmoove.%loop-value%}
                   loop-value is a player
                   broadcast "{@Win}"
                   heal loop-value
                   teleport loop-value to {LastPos.%loop-value%}
                   clear {InFile.%loop-value%}
                   clear {FilePlayer::*}
                   clear {InGame}
                   clear {InWait}
           loop all players in world {@World}:
               set loop-player's gamemode to survival
on script load:
   clear {InWait}
command /consolestart:
   trigger:
       {InWait} is not set
       {Centre} is set
       if {InGame} is true:
           send "&4ERREUR, partie en jeu !" to console
           stop
       else:
           if size of {FilePlayer::*} > {@NbrStart}:
               loop {FilePlayer::*}:
                   loop-value is a player
                   send "{@Debut30}" to loop-value
               set {InWait} to true
               wait 15 seconds
               {InWait} is true
               if size of {FilePlayer::*} > {@NbrStart}:
                   loop {FilePlayer::*}:
                       loop-value is a player
                       send "{@Debut15}" to loop-value
                   wait 5 seconds
                   if size of {FilePlayer::*} > {@NbrStart}:
                       loop {FilePlayer::*}:
                           loop-value is a player
                           send "{@Debut10}" to loop-value
                       wait 5 seconds
                       if size of {FilePlayer::*} > {@NbrStart}:
                           loop {FilePlayer::*}:
                               loop-value is a player
                               send "{@Debut5}" to loop-value
                           wait 1 seconds
                           if size of {FilePlayer::*} > {@NbrStart}:
                               loop {FilePlayer::*}:
                                   loop-value is a player
                                   send "{@Debut4}" to loop-value
                               wait 1 seconds
                               if size of {FilePlayer::*} > {@NbrStart}:
                                   loop {FilePlayer::*}:
                                       loop-value is a player
                                       send "{@Debut3}" to loop-value
                                   wait 1 seconds
                                   if size of {FilePlayer::*} > {@NbrStart}:
                                       loop {FilePlayer::*}:
                                           loop-value is a player
                                           send "{@Debut2}" to loop-value
                                       wait 1 seconds
                                       if size of {FilePlayer::*} > {@NbrStart}:
                                           loop {FilePlayer::*}:
                                               loop-value is a player
                                               send "{@Debut1}" to loop-value
                                           wait 1 seconds
                                           clear {InWait}
                                           set {_nombreTP} to 1
                                           loop {FilePlayer::*}:

                                               loop-value is a player
                                               teleport loop-value to {Spawn.%{_nombreTP}%}
                                               set {InGame} to true
                                               clear loop-value's inventory
                                               add 1 to {_nombreTP}
                                               set {cantmoove.%loop-value%} to true
                                               send loop-value title "&9Début dans" with subtitle "&45 secondes" for 1 seconds
                                           wait 1 second
                                           loop {FilePlayer::*}:
                                               send loop-value title "&9Début dans" with subtitle "&54 secondes" for 1 seconds
                                           wait 1 second
                                           loop {FilePlayer::*}:
                                               send loop-value title "&9Début dans" with subtitle "&c3 secondes" for 1 seconds
                                           wait 1 second
                                           loop {FilePlayer::*}:
                                               send loop-value title "&9Début dans" with subtitle "&62 secondes" for 1 seconds
                                           wait 1 second
                                           loop {FilePlayer::*}:
                                               send loop-value title "&9Début dans" with subtitle "&a1 seconde" for 1 seconds
                                           wait 1 second
                                           loop {FilePlayer::*}:
                                               send loop-value title "&9Début dans" with subtitle "&50 seconde" for 1 seconds
                                           wait 1 second
                                           loop {FilePlayer::*}:
                                               send loop-value title "&aGO" with subtitle "&aQue le meilleur gagne !" for 5 seconds
                                               clear {Cantmoove.%loop-value%}
                                           broadcast "{@Jeu_Name} &9La partie a commencé ! &aQue le meilleur gagne !"
                                           loop blocks in radius {@RadiusMap} around {Centre}:
                                               if loop-block is a chest:
                                                   clear loop-block's inventory
                                                   add 1 diamond chestplate to {_refill.list::*}
                                                   add 1 diamond sword to {_refill.list::*}
                                                   add 1 diamond boots to {_refill.list::*}
                                                   add 1 diamond leggings to {_refill.list::*}
                                                   add 1 diamond helmet to {_refill.list::*}
                                                   add 12 golden apple to {_refill.list::*}
                                                   add 1 flint and steel to {_refill.list::*}
                                                   set {_reffil1} to a random element out of {_refill.list::*}
                                                   set {_reffil2} to a random element out of {_refill.list::*}
                                                   set {_reffil3} to a random element out of {_refill.list::*}
                                                   add {_reffil1} to inventory of loop-block
                                                   add {_reffil2} to inventory of loop-block
                                                   add {_reffil3} to inventory of loop-block

                                       else:
                                           loop {FilePlayer::*}:
                                               loop-value is a player
                                               send "{@Annulé}" to loop-value
                                               clear {InWait}
                                               stop
                                   else:
                                       loop {FilePlayer::*}:
                                           loop-value is a player
                                           send "{@Annulé}" to loop-value
                                           clear {InWait}
                                           stop
                               else:
                                   loop {FilePlayer::*}:
                                       loop-value is a player
                                       send "{@Annulé}" to loop-value
                                       clear {InWait}
                                       stop
                           else:
                               loop {FilePlayer::*}:
                                   loop-value is a player
                                   send "{@Annulé}" to loop-value
                                   clear {InWait}
                                   stop
                       else:
                           loop {FilePlayer::*}:
                               loop-value is a player
                               send "{@Annulé}" to loop-value
                               clear {InWait}
                               stop
                   else:
                       loop {FilePlayer::*}:
                           loop-value is a player
                           send "{@Annulé}" to loop-value
                           clear {InWait}
                           stop
               else:
                   loop {FilePlayer::*}:
                       loop-value is a player
                       send "{@Annulé}" to loop-value
                       clear {InWait}
                       stop
on any move:
   if {cantmoove.%player%} is set:
       cancel event
command /leave:
   trigger:
       make player execute command "/§gamequit"
on break:
   player's world is {@World}
   if player is not op:
       cancel event

On peut m'aider merci cordialement :)

 

si besoin !

 

 

1 réponse à cette question

Messages recommandé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.