Paste #25095: ShopGUI

Date: 2015/12/21 04:09:38 UTC-08:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


Shopsystem_Apotheker: 
  type: inventory
  title: " <&8>>> <&7>Apotheker"
  size: 27
  slots:
   - "[i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Shopname_Apotheker] [i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Placeholder]"
   - "[i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Placeholder]"
   - "[i@Placeholder] [i@Placeholder] [i@Placeholder] [i@Shop_Apotheker_Item2] [i@Shop_Apotheker_Item3] [i@Shop_Apotheker_Item3] [i@Placeholder] [i@Placeholder] [i@Placeholder]"

########################################################################################################################################
#--------------------------------------------------------------------------------------------------------------------------------------#
#|                                                        Shop öffnen                                                                 |#
#--------------------------------------------------------------------------------------------------------------------------------------#
######################################################################################################################################## 
Shop_Apotheker:
  type: assignment
  interact scripts:
  - 10 Shop_Apotheker_open


Shop_Apotheker_open:
    type: interact
    events:
    steps:
        open:
            click trigger:
                script:
                - inventory open d:in@Shopsystem_Apotheker

########################################################################################################################################
#--------------------------------------------------------------------------------------------------------------------------------------#
#|                                                Shopsystem<i> Definitionen                                                          |#
#--------------------------------------------------------------------------------------------------------------------------------------#
######################################################################################################################################## 
Shopname_Apotheker:
  type: item
  material: m@human_skull
  display name: <&c>Shop <&7>| Holzf<&auml>ller

########################################################################################################################################
#--------------------------------------------------------------------------------------------------------------------------------------#
#|                                                      Item Definitionen                                                             |#
#--------------------------------------------------------------------------------------------------------------------------------------#
######################################################################################################################################## 
Shop_Apotheker_Item1:
  type: item
  material: potion,69
  display name: "Geringer Heiltrank"
  lore:
  - " "
  - "<&7>1 St<&uuml>ck <&8>> <&7>1050 Gold"
# Handle item1
Shop_Apotheker_Item1i:
  type: world
  debug: false
  events:
   on player right clicks potion,69 in Shopsystem_Apotheker:
    - if <player.money> > 1050 {
     - ^TAKE MONEY QTY:1050
     - ^GIVE POTION,69 QTY:1
     - narrate "<&8>> <&7>Du hast <&c>einen geringen Heiltrank <&7>gekauft!"
     - determine cancelled
     } else {
     - narrate "<&8>> <&7>Du hast nicht gen<&uuml>gend Gold!"
     - determine cancelled
     }
#################################### ITEM 2 #####################################
Shop_Apotheker_Item2:
  type: item
  material: potion,37
  display name: "Normaler Heiltrank"
  lore:
  - " "
  - "<&7>1 St<&uuml>ck <&8>> <&7>2470 Gold"
# Handle item2
Shop_Apotheker_Item2i:
  type: world
  debug: false
  events:
   on player right clicks potion,37 in Shopsystem_Apotheker:
    - if <player.money> > 2470 {
     - ^TAKE MONEY QTY:2470
     - ^GIVE POTION,37 QTY:1
     - narrate "<&8>> <&7>Du hast <&c>einen normalen Heiltrank <&7>gekauft!"
     - determine cancelled
     } else {
     - narrate "<&8>> <&7>Du hast nicht gen<&uuml>gend Gold!"
     - determine cancelled
     }
#################################### ITEM 3 #####################################
Shop_Apotheker_Item3:
  type: item
  material: potion,69
  display name: "Starker Heiltrank"
  lore:
  - " "
  - "<&7>1 St<&uuml>ck <&8>> <&7520 Gold"
# Item | Starker Heiltrank
StarkerHeiltrank:
    type: item
    material: potion,69
    display name: "Starker Heiltrank"
    effect: instant_health
    level: 5
    lore:
    - "<&9>Heiltrank"
    - "<&7>Heilt 10 Herzen."
# Handle item3 
Shop_Apotheker_Item3i:
  type: world
  debug: false
  events:
   on player right clicks potion,69 in Shopsystem_Apotheker:
    - if <player.money> > 7520 {
     - ^TAKE MONEY QTY:7520
     - ^GIVE i@StarkerHeiltrank QTY:1
     - narrate "<&8>> <&7>Du hast <&c>einen starken Heiltrank <&7>gekauft!"
     - determine cancelled
     } else {
     - narrate "<&8>> <&7>Du hast nicht gen<&uuml>gend Gold!"
     - determine cancelled
     }