Paste #43486: Gold Bar Quest NinkoKotOR

Date: 2017/08/13 01:32:45 UTC-07:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


QuestGoldBar:
    type: assignment
    interact scripts:
    - 10 GoldBarStart

GoldBarStart:
    type: interact
    steps:
        1:
            click trigger:
                script:
                - chat "Hello <player.name>, I need some help!"
                - wait 1
                - chat "Can you help me?"
                chat trigger:
                    1:
                        trigger: /Yes/, I can!
                        script:
                        - wait 1
                        - chat "Oh Great I need 10 gold bars."
                        - wait 1
                        - chat "I can pay you $3000 for them!!"
                        - wait 1
                        - chat "Come back when you have them!"
                        - zap step:2
                    2:    
                        trigger: /No/, sorry, I am busy.
                        script:
                        - chat "Oh darn, come back when you have some spare time..."
        2:
            click trigger:
                script:
                - if <player.inventory.contains[GOLD_INGOT].qt[10]> {
                  - take gold_ingot qty:10
                  - chat "Oh great, you have my gold!"
                  - wait 1
                  - chat "Here is your payment!"
                  - zap step:3
                  - give money qty:3000
                  } else {
                  - chat "Oh, come back when you have my 10 Gold Bars!"
                  - wait 1
                  - narrate "npc.name> frowns at you."
                  }
        3:
            click trigger:
                script:
                - chat "Thank you so much for your help earlier!"
                - wait 1
                - chat "I don't know how I would have gotten the Gold without you!"