Paste #7087: Untitled Paste

Date: 2014/07/18 12:38:12 UTC-07:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


TheBloodMoon:
  type: world
  debug: true
  events:
    on time changes in world in world:
    - if <context.time.hour.is[ORMORE].to[20]> || <context.time.hour.is[ORLESS].to[5]> {
      - run s@TheBloodMoonTask
      }
    on 6:00 in world:
    - execute as_server "butcher" 

TheBloodMoonTask:
    type: task
    debug: true
    script:
    on time changes in world in world:
    - define bloodmoon <util.random.int[1].to[1]>
    - if bloodmoon == 1 {
      - announce "Hurry and digin in hell has broke loose"
      - define r <util.random.int[<1>].to[<5>]>
      - define bad <util.random.int[<1>].to[<1000>]>
      - if r == 1 <drop <Pig_Zombie> <util.random.int[<0>].to[<10000000>]> ,<util.random.int[<0>].to[<1000>]>, <util.random.int[<0>].to[<10000000>]> qty:30>
      - if r == 2 <drop <Blaze> <util.random.int[<0>].to[<10000000>]> ,<util.random.int[<0>].to[<1000>]>,<util.random.int[<0>].to[<10000000>]> qty:50>
      - if r == 3 <drop <Magma_Cube> <util.random.int[<0>].to[<10000000>]> ,<util.random.int[<0>].to[<1000>]>, <util.random.int[<0>].to[<10000000>]> qty:50>
      - if r == 4 <drop <Lightning> <util.random.int[<0>].to[<10000000>]> ,<util.random.int[<0>].to[<1000>]>, <util.random.int[<0>].to[<10000000>]> qty:50>
      - if r == 5 <drop <GHAST> <util.random.int[<0>].to[<10000000>]> ,<util.random.int[<0>].to[<1000>]>, <util.random.int[<0>].to[<10000000>]> qty:50>
      - if bad == 123 <drop <WITHER> <util.random.int[<0>].to[<10000000>]>, <util.random.int[<0>].to[<1000>]>, <util.random.int[<0>].to[<10000000>]> qty:1>
      }
      else {
      - announce "You are safe for now"
      }