Aller au contenu
  • 0

Menu | Gui


Question

Posté(e)

Titre > Menu | Gui

 

Version > 1.9.x

 

Skript > Bonsoir, je possède actuellement un skript qui me donne une map à chaque connexion,en cliquant sur cette map un menu s'ouvre, le problème, c'est que je sais pas comment faire pas changer la map en étoile du nether, et comment ajouter des fonctions dans le menu, genre /shop etc, aussi les joueurs peuvent drop la map et peuvent aussi la déplacé dans l'inventaire et à chaque reco la map ce stack, je vous montres le code et des screens.

 

Screen >

 

1498163657-2017-06-22-22-32-42.png

 

1498163662-2017-06-22-22-32-46.png *

 

Et le code >

on join: # Pour give l'item quand il spawn
   wait 3 ticks
   give empty map named "&8>> &6Menu &8<<" to slot 0 of player
on click with empty map:
   if name of player's tool is "&8>> &6Menu &8<<":
       cancel event
       open virtual chest inventory with size 5 named "&8>> &6Menu &8<<" to player
       wait 1 ticks
       make a gui slot 0 of player with stained glass pane named " " to do nothing
       make a gui slot 1 of player with stained glass pane named " " to do nothing
       make a gui slot 2 of player with stained glass pane named " " to do nothing
       make a gui slot 3 of player with stained glass pane named " " to do nothing
       make a gui slot 5 of player with stained glass pane named " " to do nothing
       make a gui slot 6 of player with stained glass pane named " " to do nothing
       make a gui slot 7 of player with stained glass pane named " " to do nothing
       make a gui slot 8 of player with stained glass pane named " " to do nothing
       make a gui slot 9 of player with stained glass pane named " " to do nothing
       make a gui slot 17 of player with stained glass pane named " " to do nothing
       make a gui slot 18 of player with stained glass pane named " " to do nothing
       make a gui slot 26 of player with stained glass pane named " " to do nothing
       make a gui slot 27 of player with stained glass pane named " " to do nothing
       make a gui slot 35 of player with stained glass pane named " " to do nothing
       make a gui slot 36 of player with stained glass pane named " " to do nothing
       make a gui slot 37 of player with stained glass pane named " " to do nothing
       make a gui slot 38 of player with stained glass pane named " " to do nothing
       make a gui slot 39 of player with stained glass pane named " " to do nothing
       make a gui slot 41 of player with stained glass pane named " " to do nothing
       make a gui slot 42 of player with stained glass pane named " " to do nothing
       make a gui slot 43 of player with stained glass pane named " " to do nothing
       make a gui slot 44 of player with stained glass pane named " " to do nothing
       make a gui slot 4 of player with barrier named "&7Revenir en arrière" to close
       make a gui slot 40 of player with barrier named "&7Revenir en arrière" to close

  • J'aime 1

Messages recommandés

  • 0
Posté(e)
on join: # Pour give l'item quand il spawn
   remove nether star from player 's inventory
   wait 3 ticks
   give nether star named "&8>> &6Menu &8<<" to slot 0 of player

Je l'avais déjà envoyé ^^

  • 0
Posté(e)
Le problème qui reste c'est que les joueurs peuvent toujours déplacé l'item dans l'inventaire..

Sa je crois qu'on peut pas faire en sorte qu'on ne peux le déplacer au pire fais une comande c'est mieux car les joueurs gagne 1 slot comme ça

  • 0
Posté(e)

il peuvent déplacer la nether star c'est ça?

Tu peux faire comme ça pour éviter qu'ils puissent:

on inventory click:
   if name of clicked item is "&8>> &6Menu &8<<":
       cancel event
       close the player's inventory

Comme ça il ne pourra pas cliquer sur l'item nommé &8>> &6Menu &8<<

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