MissAuthenTiiq Posté(e) le 12 octobre 2019 Posté(e) le 12 octobre 2019 Version de Minecraft : 1.8.9Version de Skript : 2.2 Type du skript : Killcash, donne une récompense (Money ig) suite à un kill de joueur Description du script : Bonjour ! Petit problème avec mon systeme de killcash. Lorsqu'un joueur tue un autre joueur, l'attaqueur gagne 1 Creep's (creep's = money IG) Jusqu'à la tout va bien. Petit problème. Quand un joueur pousse l'autre joueur dans un troup. La victime meurt du dégat de chute. Et l'attaquant ne gagne pas de Creep's 😞 Je sais pas si c'est bien expliquer.. Je l'éspère. Voila une partie de mon code on death: attacker is a player: victim is a player: if attacker or victim is not in world "lobby": send "&a+1.0" to attacker add 1 to attacker's balance send "&cVous êtes mort(e) contre %attacker%" to victim send "&aVous venez de détruire %victim% !" to attacker
0 Rémi Posté(e) le 12 octobre 2019 Posté(e) le 12 octobre 2019 Hello ! Tu dois faire une variable temporaire, qui contiens la dernière personne qui a frappé le joueur en question avant ça mort 😉 !
0 MissAuthenTiiq Posté(e) le 12 octobre 2019 Auteur Posté(e) le 12 octobre 2019 il y a une heure, TheRemiDev a dit : Hello ! Tu dois faire une variable temporaire, qui contiens la dernière personne qui a frappé le joueur en question avant ça mort 😉 ! Hmmm... Comment pourais-je faire cela ?
0 Rémi Posté(e) le 12 octobre 2019 Posté(e) le 12 octobre 2019 Je suis un peu fatigué, et j'ai pas scripté depuis longtemps, mais je verrais ça un peu dans ce style : on fight: if attacker is a player: if victim is a player: set {fight.%victim%} to "%attacker%" on death of player: #addcoins to {fight.%victim%}
0 MissAuthenTiiq Posté(e) le 13 octobre 2019 Auteur Posté(e) le 13 octobre 2019 Il y a 18 heures, TheRemiDev a dit : Je suis un peu fatigué, et j'ai pas scripté depuis longtemps, mais je verrais ça un peu dans ce style : on fight: if attacker is a player: if victim is a player: set {fight.%victim%} to "%attacker%" on death of player: #addcoins to {fight.%victim%} Si le joueur fuit et meurt plus tard par exemple 1 minutes plus tard. L'autre gagne quand même 😕 Il faudrait delete la var. Mais si on met un wait 5 seconds. et delete Il va y avoir un problème nn ? Je sais pas trop comment faire 😕
0 Romitou Posté(e) le 14 octobre 2019 Posté(e) le 14 octobre 2019 on damage of player: attacker is a player victim is a player set {attacker::%{_victim}%} to attacker wait 10 seconds clear {attacker::%{_victim}%} on death of player: if attacker or victim is not in world "lobby": if attacker is set: set {_attacker} to attacker else: set {_attacker} to {attacker::%{_victim}%} send "&a+1.0" to {_attacker} add 1 to {_attacker}'s balance send "&cVous êtes mort(e) contre %attacker%" to victim send "&aVous venez de détruire %victim% !" to {_attacker} clear {attacker::%{_victim}%}
0 MissAuthenTiiq Posté(e) le 16 octobre 2019 Auteur Posté(e) le 16 octobre 2019 Le 14/10/2019 à 21:42, Romitou a dit : on damage of player: attacker is a player victim is a player set {attacker::%{_victim}%} to attacker wait 10 seconds clear {attacker::%{_victim}%} on death of player: if attacker or victim is not in world "lobby": if attacker is set: set {_attacker} to attacker else: set {_attacker} to {attacker::%{_victim}%} send "&a+1.0" to {_attacker} add 1 to {_attacker}'s balance send "&cVous êtes mort(e) contre %attacker%" to victim send "&aVous venez de détruire %victim% !" to {_attacker} clear {attacker::%{_victim}%} Merci ça marche. Mais juste un problème avec ça Citation add 1 to {royalpvp.totalkills::%uuid of {_attacker}%} J'ai rajouté ça car j'en ai besoin. Mais on peut pas mettre de variables dans le nom de la variable 😕 1
0 Romitou Posté(e) le 16 octobre 2019 Posté(e) le 16 octobre 2019 il y a une heure, MissAuthenTiiq a dit : Merci ça marche. Mais juste un problème avec ça J'ai rajouté ça car j'en ai besoin. Mais on peut pas mettre de variables dans le nom de la variable 😕 Normalement ça fonctionne, tu as quelle erreur ?
0 MissAuthenTiiq Posté(e) le 17 octobre 2019 Auteur Posté(e) le 17 octobre 2019 Il y a 15 heures, Romitou a dit : Normalement ça fonctionne, tu as quelle erreur ? Voila l'erreur : Invalid amount or placement of brackets. Please make sure that each opening bracket has a corresponding closing bracket. (killcash.sk line 32: add 1 to {royalpvp.totalkills::%uuid of {_attacker}%}
0 Romitou Posté(e) le 17 octobre 2019 Posté(e) le 17 octobre 2019 Il y a 5 heures, MissAuthenTiiq a dit : Voila l'erreur : Invalid amount or placement of brackets. Please make sure that each opening bracket has a corresponding closing bracket. (killcash.sk line 32: add 1 to {royalpvp.totalkills::%uuid of {_attacker}%} Peux-tu envoyer tout ton code ?
0 MissAuthenTiiq Posté(e) le 22 octobre 2019 Auteur Posté(e) le 22 octobre 2019 Le 17/10/2019 à 17:03, Romitou a dit : Peux-tu envoyer tout ton code ? Citation on damage of player: attacker is a player victim is a player set {attacker::%{_victim}%} to attacker wait 10 seconds clear {attacker::%{_victim}%} on death of player: if attacker or victim is not in world "lobby": if attacker is set: set {_attacker} to attacker else: set {_attacker} to {attacker::%{_victim}%} send "&a+1.0" to {_attacker} add 1 to {_attacker}'s balance add 1 to {royalpvp.totalkills::%uuid of %{_attacker}% %} send "&cVous êtes mort(e) contre %{_attacker}%" to victim send "&aVous venez de détruire %victim% !" to {_attacker} make console execute command "leveladd %{_attacker}% kill" clear {attacker::%{_victim}%} Voila le code
0 MissAuthenTiiq Posté(e) le 24 octobre 2019 Auteur Posté(e) le 24 octobre 2019 Le 22/10/2019 à 10:05, Kilterra a dit : Tiens voici ton code modifié : on damage of player: attacker is a player victim is a player set {attacker::%{_victim}%} to attacker wait 10 seconds clear {attacker::%victim%} on death of player: if attacker or victim is not in world "lobby": if attacker is set: set {_attacker} to attacker else: set {_attacker} to {attacker::%victim%} send "&a+1.0" to {_attacker} add 1 to {_attacker}'s balance add 1 to {royalpvp.totalkills::%uuid of {_attacker} %} send "&cVous êtes mort(e) contre %{_attacker}%" to victim send "&aVous venez de détruire %victim% !" to {_attacker} make console execute command "leveladd %{_attacker}% kill" clear {attacker::%victim%} Merci de l'aide :) J'ai une erreur encore :( Citation can't understand this condition/effect: add 1 to {royalpvp.totalkills::%uuid of {_attacker} %}
0 MissAuthenTiiq Posté(e) le 27 octobre 2019 Auteur Posté(e) le 27 octobre 2019 Le 24/10/2019 à 13:37, Kilterra a dit : on damage of player: attacker is a player victim is a player set {attacker::%{_victim}%} to attacker wait 10 seconds clear {attacker::%victim%} on death of player: if attacker or victim is not in world "lobby": if attacker is set: set {_attacker} to attacker else: set {_attacker} to {attacker::%victim%} send "&a+1.0" to {_attacker} add 1 to {_attacker}'s balance set {_UUID} to UUID of {_attacker} add 1 to {royalpvp.totalkills::%{_UUID}%} send "&cVous êtes mort(e) contre %{_attacker}%" to victim send "&aVous venez de détruire %victim% !" to {_attacker} make console execute command "leveladd %{_attacker}% kill" clear {attacker::%victim%} ça marche ! merci !
0 Joriis Posté(e) le 27 octobre 2019 Posté(e) le 27 octobre 2019 Super, je déplace en résolu 🙂 Bonne journée ! 1
0 Rush2Fer Posté(e) le 27 octobre 2019 Posté(e) le 27 octobre 2019 Le sujet a été résolu. Il a donc été verrouillé. Cordialement, l'équipe. 1
Question
MissAuthenTiiq
Version de Minecraft : 1.8.9
Version de Skript : 2.2
Type du skript : Killcash, donne une récompense (Money ig) suite à un kill de joueur
Description du script :
Bonjour !
Petit problème avec mon systeme de killcash. Lorsqu'un joueur tue un autre joueur, l'attaqueur gagne 1 Creep's (creep's = money IG)
Jusqu'à la tout va bien.
Petit problème.
Quand un joueur pousse l'autre joueur dans un troup. La victime meurt du dégat de chute. Et l'attaquant ne gagne pas de Creep's 😞
Je sais pas si c'est bien expliquer.. Je l'éspère.
Voila une partie de mon code
14 réponses à cette question
Messages recommandés