Paste #61896: Untitled Paste

Date: 2019/11/10 07:19:36 UTC-08:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


# Punti_Fabbro - da assegnare per le abilità
# Punti_esp_fabbro - indica i punti esperienza del fabbro
# Livello_fabbro - indica il livello fabbro
# Mestiere_fabbro_XXXXX - indica l'abilità con il livello.
#
# Menù fabbro compra skill
Mestiere_fabbro_menu:
    type: inventory
    title: Mestiere Fabbro
    size: 54
    slots:
    - "[i@Fabbro_Guida_menu_slot2] [] [] [] [] [] [] [] []"
    - "[] [] [] [] [] [] [] [] [i@Mestiere_fabbro_Tutorial_slot1]"
    - "[] [] [] [] [] [] [] [] [i@Mestiere_fabbro_Tutorial_slot2]"
    - "[] [] [] [] [] [] [] [] [i@Mestiere_fabbro_Tutorial_slot3]"
    - "[] [] [] [] [] [] [] [] []"
    - "[] [] [] [] [] [] [] [] []"
# menù fabbro usa skill
Cast_Mestiere_fabbro:
    type: inventory
    title: Cast Fabbro
    size: 54
    slots:
    - "[] [i@Fabbro_Guida_menu_Cast] [] [] [] [] [] [] []"
    - "[i@Mestiere_fabbro_Tutorial_slot0] [] [] [] [] [] [] [] []"
    - "[i@Mestiere_fabbro_Tutorial_slot2] [] [] [] [] [] [] [] []"
    - "[i@Mestiere_fabbro_Tutorial_slot3] [] [] [] [] [] [] [] []"
    - "[] [] [] [] [] [] [] [] []"
    - "[] [] [] [] [] [] [] [] []"
# comandi fabbro
Mestiere_fabbro_menu_command_1:
    type: command
    debug: false
    name: fabbro
    permission: mestiere.fabbro
    description: Apre l'interfaccia del fabbro.
    usage: /fabbro
    script:
    - inventory open d:in@Mestiere_fabbro_menu
    - narrate "<green>Acquisisci abilità!"

# sezione click in inventory acquisisci abilità
Mestiere_fabbro_menu_Click:
    type: world
    debug: false
    events:
        on player drags in Mestiere_fabbro_menu:
        - determine cancelled
#
        on player clicks in Mestiere_fabbro_menu:
        - determine passively cancelled
#
        on player drags in Cast_Mestiere_fabbro:
        - determine cancelled
#
        on player clicks in Cast_Mestiere_fabbro:
        - determine passively cancelled
#
# click in fabbro cast
#        
        on player clicks Fabbro_Guida_menu_Cast in Cast_Mestiere_fabbro:
        - if <player.flag[Mestiere_fabbro_Guida_al_fabbro]> = 1:
            - execute as_op "cmi saveditems get GuidaFabbro"
        - else:
            - narrate "Non hai Questa Skill"
#
# click per cambiare inventory
#
        on player clicks Mestiere_fabbro_Tutorial_slot1 in Mestiere_fabbro_menu:
        - inventory close d:in@Cast_Mestiere_fabbro
        - wait 5t
        - inventory open d:in@Mestiere_fabbro_menu
#
        on player clicks Mestiere_fabbro_Tutorial_slot1 in Mestiere_fabbro_menu:
        - inventory close d:in@Mestiere_fabbro_menu
        - wait 5t
        - inventory open d:in@Cast_Mestiere_fabbro
#
# click per apprendere le abilità
#
        on player clicks Fabbro_Guida_menu_slot2 in Mestiere_fabbro_menu:
        - if <player.flag[punti_fabbro]> > 0:
            - if <player.flag[Mestiere_fabbro_Guida_al_fabbro]> = 0:
                - flag player Mestiere_fabbro_Guida_al_fabbro:1
                - flag player punti_fabbro:--
                - inventory close d:in@Mestiere_fabbro_menu
                - inventory open d:in@Mestiere_fabbro_menu
            - if <player.flag[Mestiere_fabbro_Guida_al_fabbro]> = 1:
                - narrate "Hai raggiunto il livello massimo per questa skill"
            - else:
                - narrate "Hai già acquistato questa abilità"
        - else:
            - if <player.flag[Mestiere_fabbro_Guida_al_fabbro]> = 1:
                - narrate "Hai raggiunto il livello massimo per questa skill"
            - else:
                - narrate "Non hai Punti Mestiere per Questa skill"


# sezione slot tutorial
Mestiere_fabbro_Tutorial_slot0:
    type: item
    material: SIGN
    display name: <gold>sezione cast
    enchantments:
    - vanishing_curse:1
    mechanisms:
        flags: HIDE_ENCHANTS
    lore:
    - <dark_green>Passa alla sezione Apprendi

Mestiere_fabbro_Tutorial_slot1:
    type: item
    material: SIGN
    display name: <gold>Sezione Apprendi
    enchantments:
    - vanishing_curse:1
    mechanisms:
        flags: HIDE_ENCHANTS
    lore:
    - <dark_green>Passa alla sezione Cast

Mestiere_fabbro_Tutorial_slot2:
    type: item
    material: SIGN
    display name: <gold>Punti Skill Fabbro
    enchantments:
    - vanishing_curse:1
    mechanisms:
        flags: HIDE_ENCHANTS
    lore:
    - <green>hai <aqua><player.flag[punti_fabbro]> <green>Punti abilità
Mestiere_fabbro_Tutorial_slot3:
    type: item
    material: SIGN
    display name: <gold>Livello e esperienza
    enchantments:
    - vanishing_curse:1
    mechanisms:
        flags: HIDE_ENCHANTS
    lore:
    - <green>Il tuo livello da fabbro è <aqua><player.flag[Livello_fabbro]>
# sezione slot compra skill
Fabbro_Guida_menu_slot2:
    type: item
    material: ENCHANTED_BOOK
    display name: Guida al Fabbro
    lore:
    - <dark_green>Livello fabbro sbloccabile: <dark_aqua>1
    - <dark_green>Livello skill massimo: <dark_aqua>1
    - <dark_green>Livello: <gold><player.flag[Mestiere_fabbro_Guida_al_fabbro]>
    - <blue>Ottieni Il Libro Guida del mestiere Fabbro.
#
#
#
# sezione slot usa skill
Fabbro_Guida_menu_Cast:
    type: item
    material: ENCHANTED_BOOK
    display name: Guida al Fabbro
    lore:
    - <dark_green>Livello: <gold><player.flag[Mestiere_fabbro_Guida_al_fabbro]>
    - <blue>Ottieni Il Libro Guida del mestiere Fabbro.