Date: 2020/04/16 06:47:06 UTC-07:00
Type: Denizen Script
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
MoldirBanker:
type: assignment
debug: true
actions:
on assignment:
- trigger name: click state:true
on click:
- if <player.item_in_hand.script.name||false> == "BankPermit":
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Seems like you got a <&6>Golden Nugget Bank Permit<&f>."
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Please take the door to your right to enter the vault area!"
- wait 2s
- playsound <player> Entity_VILLAGER_CELEBRATE
- narrate "Make sure to hold it in your hand!"
- stop
- if <player.item_in_hand.material.name> == emerald_block:
- playsound <player> ENTITY_VILLAGER_NO
- narrate "<&f>Let me count those real quick.<&f>."
- wait 1s
- repeat 14:
- if <player.item_in_hand.material.name> == emerald_block:
- playsound <player> ENTITY_EXPERIENCE_ORB_PICKUP
- take iteminhand
- wait 0.15s
- define Count:+:1
- else:
- playsound <player> ENTITY_VILLAGER_NO
- narrate "<&f>That's just <&3><[Count]> Emerald Block!"
- wait 1
- playsound <player> ENTITY_VILLAGER_NO
- narrate "Sorry, i can't hand you over one for that."
- give <player> Emerald_Block qty:<[Count]>
- define Count:0
- stop
- if <[Count]> == 14:
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Looks good. Here is your <&6>Golden Nugget Bank Permit<&f>."
- flag npc counter:+:1
- adjust <[BankPermit]> nbt:number/<npc.flag[counter]>
- give BankPermit
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Let me explain this real quick!"
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "This permit allows you to enter the vault area!"
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Inside the vault area, you have your own safe vault assigned."
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Inside this vault, you can store whatever you want"
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Most people store their <&5>Enderchest <&f>inside."
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Probably the smartest thing you can do."
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "Enough talk! To get to the vault area, take the door to your right!"
- else:
- playsound <player> ENTITY_VILLAGER_AMBIENT
- narrate "<&f>Welcome to the <&6>Gold Nugget Bank<&f>!"
- wait 2s
- playsound <player> ENTITY_VILLAGER_AMBIENT
- narrate "<&f>Nobody else can store your belongings as safe as we do."
- wait 3s
- playsound <player> ENTITY_VILLAGER_AMBIENT
- narrate "<&f>If you want to become a customer, you need to pay <&3>14 Emerald Blocks<&f>."
- wait 3s
- playsound <player> ENTITY_VILLAGER_AMBIENT
- narrate "<&f>Super cheap for a safe place like this right?"
- wait 2s
- playsound <player> ENTITY_VILLAGER_CELEBRATE
- narrate "<&f>If you have the <&3>14 Emerald Blocks <&f>feel free to hand them over to me."
BankPermit:
type: item
debug: true
material: paper
display name: <&6>Gold Nugget Bank Permit
lore:
- Permit to enter a personal
- vault in <&3>Moldir<&5>. This
- permit is for room <npc.flag[<counter>]>
enchantments:
- silk_touch:1
mechanisms:
flags: HIDE_ALL
nbt:<number/<npc.flag[counter]>