Paste #46761: Edit of P#46760 - Edit of P#46759 - Hobo Stew

Date: 2018/03/01 12:30:04 UTC-08:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


LostCity:
  type: assignment
  interact scripts:
  - 10 LostCityMain

Hobo_Stew:
  type: item
  material: i@beetroot_soup
  display name: Hobo Stew
  lore:
  - nothing special
  - just a bowl of stew

SoupHandler:
  type: world
  events:
    on player consumes Hobo_Stew:
    - flag <player> soup_consumed

LostCityMain:
  type: interact
  steps:
    1:
      proximity trigger:
        entry:
          script:
            - chat "Hello <player.name>!"
            - wait 2
            - chat "Why are you suprised I know your name?"
            - wait 1
            - chat "I may be a hobo, but there is more to me than you can see."
            - wait 2
            - chat "Would you like some soup?"
      chat trigger:
        1:
          trigger: "/Yes/, I am hungry."
          script:
          - wait 1
          - CHAT "Here. Have a bowl of my hobo stew. "
          - animate <npc> animation:ARM_SWING
          - give Hobo_Stew qty:1
          - zap step:11
        2:
          trigger: "/No/, thank you."
          script:
          - wait 1
          - chat "Suit yourself."
          - wait 2
          - chat "What can I do for you?"
          - zap step:2
    2:
      chat trigger:
        1:
          trigger: "I want to hear the /story/ of the lost civilization."
          script:
          - wait 1
          - CHAT "The story of the lost civilization..."
          - wait 2
          - chat "How'd you hear about that I wonder..."
          - wait 2
          - chat "Let's sit in the tent and I'll tell it to you"
          - sit location:266,63,298,world
          - wait 3
          - zap step:3
        2:
          trigger: "/Nothing/ at all."
          script:
          - wait 1
          - CHAT "That's too bad. See you around, <player.name>" 
          - zap step:8
    11:       
      proximity trigger:
        entry:
          script:
          - if <player.flag[soup_consumed]> == null {
            - narrate "Drink your soup!" }
            else {
            - chat "The stew's not bad, eh?"
            - wait 3
            - chat "What can I do for you? 
            - wait 1
            - chat "Nobody visits a hobo for no reason."
            - zap step:2
            }
    3:
      proximity trigger:
        entry:
          script:
          - chat "Well, there is a legend of an ancient civilization that existed long ago."
          - wait 2
          - chat "The legend says that these people could do great things that we can't even imagine."
          - wait 2
          - chat "They could build monstrous cities, cure many diseases, and were rich beyond measure."
          - wait 2
          - chat "They were so technologically advanced they could teleport across the world in a single blink..."
          - wait 2
          - chat "and according to legend, build giant cities in the sky."
          - wait 4
          - chat "Are you following so far?"
          - zap step:4
    4:
      chat trigger:
        1:
          trigger: "/Yes/, I'm following."
          script:
          - wait 2 
          - chat "Isn't his story interesting? I wonder if it's true..."
          - zap step:5
        2:
          trigger: "/No/, I lost you."
          script:
          - zap step:3
    5:
      proximity trigger:
        entry:
          script:
          - chat "One day, something and terrible came from the ocean and the civilization disappeared..."
          - wait 2
          - chat "The legend ends that there is one last floating city where the remnants of these people fled."
          - wait 2
          - chat "But the location of the island has been lost."
          - stand l@:263,63,301,world
          - zap step:6
    6:
      proximity trigger:
        entry:
          script:
          - wait 1
          - chat "That's all I know, but there is someone who lives in Switalaville who is said to know more."
          - wait 2
          - chat "What do you think of the story?"
      chat trigger:
        1:
          trigger: "I, somehow, /believe/ it."
          script:
          - wait 1
          - chat "If you ever find yourself in Switalaville, try to find a man named Zeke"
          - wait 1
          - chat "He is rumored to know more about the lost civilization."
          - wait 3
          - narrate "Find Zeke in Switalaville"
          - zap step:9
        2:
          trigger: "It's just a /fairy tale/"
          script:
          - chat "It might very well be, but in every fairy tale there is some truth."
          - wait 2
          - chat "It was nice meeting you, <player.name>. Come back if you change your mind."
          - zap step:7
    7:
      proximity trigger:
        entry:
          script:
          - cooldown duration:30s
          - chat "Hello, <player.name>, have you changed your mind about the story?"
      chat trigger:
        1:
          trigger: "/Yes/ I have."
          script:
          - wait 1
          - chat "Very good! There is a man named Zeke in Switalaville that can tell you more if you wish."
          - zap step:9
        2:
          trigger: "/No/, not at all."
          script:
          - wait 1
          - chat "Come back if you change your mind."
          - zap step:7
    8:
      proximity trigger:
        entry:
          script:
          - chat "Welcome back, <player.name>, what can I do for you?"
          - zap step:2
    9:
      proximity trigger:
        entry:
          script:
          - chat "Hey <player.name>! Would you like some more soup?"
      chat trigger:
        1:
          trigger: "/Yes/, please"
          script:
          - chat "Here you go"
          - animate <npc> animation:ARM_SWING
          - give item:Hobo Stew qty:1
          - wait 5
          - chat "Not bad, eh?"
          - zap step:10
        2:
          trigger: "/No/, thank you."
          script:
          - zap step:9
    10:
      proximity trigger:
        entry:
          script:
          - random 3
          - chat "Lovely day, <player.name>!"
          - chat "Good to see you again, <player.name>"
          - chat "Huh?"