Paste #39779: Untitled Paste

Date: 2017/02/08 22:58:59 UTC-08:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


lockpicks:
  type: world
  events:
    on player right clicks chest with lockpick:
    - if !<global.flag[lockedchest].contains.context.location> {
      }
        else {
      - flag player lockpicking
      - bossbar create playerlockpick lockpin
      }
    on player walks:
    - if !<player.has_flag[lockpicking]> {
      }
      - else {
      - bossbar update playerlockpick <context.player.location.pitch>
      }
locked chest:
  type: world
  events:
    on player right clicks chest with lock:
    - flag global lockedchest:->:<context.location>
    - flag player lockedchestlist:->:<context.location>
Locked chest access:
  type: world
  events:
    on player right clicks chest:
    - if <global.flag[lockedchest].contains.context.location> && <player.flag[lockedchestlist].contains.context.location> {
      queue clear
      }
      else {
      - determine cancelled
      }
lockpick:
  type: item
  material: name_tag
  title: lock pick  
chest lock:
  type: item
  material: flint_and_steel
  title: lock