- D1 Meta Docs - Denizen Script -
Home Page / Pi to one million places / Contact mcmonkey / Donate / Paste Scripts / Denizen Help /
You are browsing as a guest.
Login | Register


Click here to create your own public paste ~ ~ click to duplicate and edit this paste


TitleTravelers
TypeDenizen Script
Date2014/05/31 21:39:09 UTC-07:00
ByGuest
Other
Paste
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
4800
traveler_assign:
    type: assignment
    actions:
        on assignment:
        - trigger name:click state:true
        - trigger name:proximity state:true
        - trigger name:chat state:true
        on enter proximity:
        - narrate format:cchat "Come talk to me if you need to get somewhere!"
    interact scripts:
    - 10 traveler_interact

traveler_interact:
    type: interact
    steps:
        1:
            click trigger:
                script:
                - ^run npc_wander_pause instantly
                - narrate format:cchat "I can take you anywhere you need to go! $100 to go anywhere!"
                - narrate format:cchat "Merstone, StoneRose, Solace, Flotsam..."
                - narrate "<&c><&o>Specify a location to travel there."
                - ^run npc_wander_resume delay:10s
            chat trigger:
                1:
                    trigger/regex:(?i)(Merstone|StoneRose|Solace|Flotsam)/
                    script:
                    - ^if !<li@merstone|stonerose|solace|flotsam.contains[<escape:<context.message>>]> {
                      - narrate format:cchat "Huh?"
                      - queue clear
                      }
                    - ^define destination <context.message>
                    - ^inject traveler_shop_handler

traveler_shop_handler:
    type: task
    script:
    - ^if <npc.flag[cityloc]> == %destination% {
      - narrate format:cchat "We're already there, silly."
      - queue clear
      }
    - ^if <player.money> < 100 {
      - narrate format:cchat "You can't afford that!"
      - queue clear
      }
    - ^narrate format:cchat "Alright, let's go!"
    - execute as_server "warp %destination% <player.name>"



RawRaw



Pastes made: 57250