Paste #953: Starter

Date: 2014/01/03 10:27:14 UTC-08:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


Starter:
    type: assignment

    Interact scripts:
    - 10 Welcome
    - 10 TalkToPriest

    actions:
        on assignment:
        - TRIGGER name:click state:true 
        - TRIGGER name:chat state:true      

Welcome:
    type: interact
    steps:
        1:
            click trigger:
                script:
                - if <player.flag[crystalnorepeat]> == true {
                  - chat "You can only do this quest once a day, please try again later."
                  - zap 1
                  } else {
                  - chat "Welcome To the World of Archan Choose the Quest you want" 
                  - chat "Your Choices are"
                  - chat "<&f>Talk To Quests Priest, Warrior, or Mage"
                  - chat "<&B>Hunter-Get the Magic Crystal"
                  - zap 2
                  }
        2:
            Chat trigger:
                1:                   
                    trigger: I to go talk to the /Priest/
                    script:
                    - chat "Ok he's in the church across the path"
                    - run TalkToPriest
                2: 
                    trigger: I want to go talk to the /Warrior/
                    script:
                    - chat "Ok he's most likely fighting or in the inn"
                    - run TalkToWarrior
                3: 
                    trigger: I want to go talk to the /Mage/
                    script:
                    - chat "Ok if you can find his tower send him my respects"
                    - run TalkToMage
                4: 
                    trigger: I want to go /hunt/ing
                    script:
                    - chat "Ok go kill 10 cows, 5 pigs, and 5 zombies"
                    - run Hunter
                5: 
                    trigger: I want to go get the magic /crystal/
                    script:
                    - chat "Ok i will teleport you to the house overrun by enemies you will have to battle your way through to the chest containing the crystal"
                    - run Crystal
                    - zap 1
                6:
                    trigger: /No/ i don't want to go on a quest
                    script:
                      - zap 1
                      - chat "Ok come back later if you want a quest"
TalkToPriest:

TalkToWarrior:

TalkToMage:

Hunter:

Crystal:
    type: task
    script:
        - teleport <player> l@-5,64,146,Moirae
        - narrate "<&3>You get Teleported to room"
        - wait 1
        - chat "Find the diamond in a room"
        - listen item type:craft item:264 qty:9 script:crystal2
Crystal2:
    type: task
    script:
        - if <player.inventory.contains[diamond].qty:9> {
          - take diamond qty:9
          - give player money qty:100
          - narrate "You have gotten the crystal"
          - flag crystalnorepeat:true duration:1d
          - chat "Thanks for helping come back tommorow to redo quest"
          } else {
          - chat "<&b>Your Not Done!"
          - zap Crystal
          }