Paste #47315: Untitled Paste

Date: 2018/04/29 14:18:55 UTC-07:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


booster:
  type: inventory 
  title: <&3>Global Boosters
  size: 27
  slots:
  - "[] [] [] [] [] [] [] [] []"
  - "[] [] [] [] [fly] [] [] [] []"
  - "[] [] [] [] [] [] [] [] []"

booster_command:
  type: command
  name: Booster
  description: Opens Booster GUI
  usage: "/booster"
  script:
  - inventory open d:in@booster

fly:
  type: item
  material: Elytra
  display name: <&6>Global Gly booster
  lore:
  - <&e>Enable fly for everyone online
  - <&e>on the server for 60 seconds!

flyb:
  type: item
  material: 288
  display name: <&b>Fly Badge
  lore:
  - <&7>Use this to activate a fly booster

fly_event:
  type: world
  events:
    on player clicks in booster:
    - determine cancelled
    on player drags in booster:
    - determine cancelled
    on player clicks fly in booster:
    - if <in@inventory.contains.flyb[<flyb>].quantity[<1>]> == true {
      - adjust <server.list_online_players> can_fly:true
      - take flyb
      {
      else {
      - inventory close
    }