Paste #31891: Untitled Paste

Date: 2016/03/23 18:36:26 UTC-07:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19


npc_interaction_start:
  type: task
  debug: true
  speed: 0
  script:
  - if <player.has_flag[npc_interaction_cooldown]> queue clear
  - if <player.has_flag[need_answer]> queue clear
    - if <player.flag[<queue.script.name>_completion]||false> == true {
      - if <queue.script.name.yaml_key[questinfo.repeatable]||false> == false {
        - narrate "<queue.script.yaml_key[questinfo.messages.already_completed].random||I have nothing for you.>" format:npc_to_player_format
        - queue clear
        } else if <queue.script.name.yaml_key[questinfo.delay].as_duration.in_ticks||1728000> > <util.date.time.duration.in_ticks.sub[<player.flag[<queue.script.name>_completion_date]||0>]> {
        - narrate "<queue.script.yaml_key[questinfo.messages.on_cooldown].random||I have nothing for you yet.>" format:npc_to_player_format
        - queue clear
        } else {
        - flag <player> <queue.script.name>_progress:0
        }
      }
  - flag <player> npc_interaction_cooldown duration:10s