Paste #17105: Aquiring Iron

Date: 2015/06/28 19:15:10 UTC-07:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


Search For Iron:
    type: assignment
    interact scripts:
    - 10 Search For Iron

An Iron Start:
    type: interact
    steps:
        1:
            click trigger:
                script:
                - chat "Excuse me <player.name>, do you mind helping me?"
                - wait 1
                - chat "My name is <npc.name>. Can you help me?"
            click trigger:
                1:
                   trigger: /Yes/, I will help you
                   script:
                   - chat "Awesome! I need some iron ingots. Only three to be exact."
                   - wait 1
                   - chat "Come back when you have them"
                   -zap step:2
                2:
                    trigger: /No/, I am too busy.
                    script:
                    - chat "Oh... I'm sorry to have been a waste of your time."

        2:
            click trigger:
                script:
                - if <player.inventory.contains[IRON_INGOT].qty[3]> {
                    - ^take iron_ingot qty:3
                    - chat "Thank you, thank you!"
                    - wait 1
                    - chat "Thank you for your help! Now I can begin my mine!"
                    - give money qty:500
                    - zap step:3
                    } else {
                    - chat "Now you're just wasting my time, come back when you have them."
                    - wait 1
                    - narrate "<npc.name> shook his head."
                    }
        3:
            click trigger:
                script:
                - chat "I don't have anything else that needs to be done. Once again, thanks for your help."