Aller au contenu
  • 0

Daily Reward


Question

Posté(e)

Hey ! J'aimerais savoir comment faire un Daily Reward ! J'ai tenter ça: Tout marche sauf le Cooldown

 


options:


cooldown: 24 hours





on rightclick on a ender chest:
if player is in world "hub":
cancel event
if {_wait} is less than {@cooldown}:
chance of 70%:
add 250 to {PouletCoins.%UUID of player%}
add 15 to {Pouley.%UUID of player%}
send "&aTu a gagner &e250 &aPouletCoins et &e15 &a Pouley ! Va tu gagner autre chose ?"
chance of 29.5%:
add 750 to {PouletCoins.%UUID of player%}
add 50 to {Pouley.%UUID of player%}
send "&aTu a gagner &e750 &aPouletCoins et &e50 &a Pouley ! Va tu gagner autre chose ?"
chance of 0.5%:
add 2000 to {PouletCoins.%UUID of player%}
add 500 to {Pouley.%UUID of player%}
send "&a&lTu a gagner &e&l2000&a&l PouletCoins et &e&l500&a&l Pouley !"
broadcast "&b&l[DailyReward]&a&l %player% a gagner &e&l2000 &a&lPouletCoins et &e&l500&a&l Pouley !"
else:
send "&aTu a déjà jouer ! Retente dans &e%{_wait}%"[/Code]

8 réponses à cette question

Messages recommandés

  • 0
Posté(e)

Evite les double post merci ;)

 

options:


   cooldown: 24 hours





on rightclick on a ender chest:
   if player is in world "hub":
       cancel event
       if {_wait} is less than {@cooldown}:
           set {_wait} to now
           chance of 70%:
               add 250 to {PouletCoins.%UUID of player%}
               add 15 to {Pouley.%UUID of player%}
               send "&aTu a gagner &e250 &aPouletCoins et &e15 &a Pouley ! Va tu gagner autre chose ?"
           chance of 29.5%:
               add 750 to {PouletCoins.%UUID of player%}
               add 50 to {Pouley.%UUID of player%}
               send "&aTu a gagner &e750 &aPouletCoins et &e50 &a Pouley ! Va tu gagner autre chose ?"
           chance of 0.5%:
               add 2000 to {PouletCoins.%UUID of player%}
               add 500 to {Pouley.%UUID of player%}
               send "&a&lTu a gagner &e&l2000&a&l PouletCoins et &e&l500&a&l Pouley !"
               broadcast "&b&l[DailyReward]&a&l %player% a gagner &e&l2000 &a&lPouletCoins et &e&l500&a&l Pouley !"
       else:
           send "&aTu a déjà jouer ! Retente dans &e%{_wait}%"

 

  • 0
Posté(e)

Essaye ça.

 

options:

 {pret.%player%} = false

on rightclick on a ender chest:
if player is in world "hub":
   cancel event
    if {pret.%player%} is true:
      set {pret.%player%} to false
      set {wait.%player%} to 0
      chance of 70%:
        add 250 to {PouletCoins.%UUID of player%}
        add 15 to {Pouley.%UUID of player%}
        send "&aTu a gagné &e250 &aPouletCoins et &e15 &a Pouley ! Vas-tu gagner autre chose ?"
      chance of 29.5%:
        add 750 to {PouletCoins.%UUID of player%}
        add 50 to {Pouley.%UUID of player%}
        send "&aTu a gagné &e750 &aPouletCoins et &e50 &a Pouley ! Vas-tu gagner autre chose ?"
      chance of 0.5%:
        add 2000 to {PouletCoins.%UUID of player%}
        add 500 to {Pouley.%UUID of player%}
        send "&a&lTu a gagné &e&l2000&a&l PouletCoins et &e&l500&a&l Pouley !"
        broadcast "&b&l[DailyReward]&a&l %player% a gagné &e&l2000 &a&lPouletCoins et &e&l500&a&l Pouley !"
    else:
      send "&aTu a déjà joué... Retente dans &e1 jour&a."

every 12 hours:
 if {pret.%player%} is false:
   add 1 to {wait.%player%}
   if {wait.%player%} is equal to 2:
     set {pret.%player%} to true 

  • 0
Posté(e)
every 12 hours: if {pret.%player%} is false: add 1 to {wait.%player%} if {wait.%player%} is equal to 2: set {pret.%player%} to true

Remplace ça par :

every 12 hours:
   loop all players:
       if {pret.%loop-player%} is false:
           add 1 to {wait.%loop-player%}
       if {wait.%loop-player%} is equal to 2:
           set {pret.%loop-player%} to true

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