Date: 2018/07/30 16:49:52 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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
#######################################
#Quest Log System
#Author: theDadmin
#Version 1.0
#Instructions: A detailed video can be found here https://www.youtube.com/watch?v=MWgeukJGv7c&feature=youtu.be
#Using this system is fairly easy and can be applied to existing quests.
#This script is stand alone and only requires certain commands be added to quests. You will need to, at the completion of a quest flag a player with the completedquests flag +1. You will need to do this as well for quest points. You will also need to make books and bookitem scripts and include an event in worldscripts to allow the books to be read. Below are examples of these scripts for copy and paste purposes.
#Start of quest:
#- inventory add d:<player>questjournal o:examplebookitem
#
#At end of quest:
#- inventory add d:<player>completedquests o:examplebookitem
#- inventory remove d:<player>questjournal o:examplebookitem
#- flag player completedquests:+:1 (This is only needed if this is a scripted quest)
#- flag player questpoints:+:(number awarded) (This is only needed if this is a scripted quest)
#
#Example Book
#rolandreagentsb:
# type: book
# author: Active Quest
# title: Roland's Reagents
# signed: yes
# text:
# - "I have been asked by Roland to retrieve the following items:<n>10 Blaze Rods<n>32 Glowstone Dust<n>64 Netherwart."
#Example Book Item
#
#rolandreagentsbi:
# type: item
# material: book
# display name: Roland's Reagents
# lore:
# - "Click here to bring up quest information"
#
#You may wish to have two different books for when a quest is active and completed. In this case you will also need a second book item for the completed quest book with a cooresponding event.
#
#Example Event: (This can be added to ANY existing world script)
# on player clicks examplebookitem in inventory:
# - inventory close
# - define held <player.item_in_hand>
# - adjust <player> item_in_hand:examplebook
# - adjust <player> open_book
# - adjust <player> item_in_hand:<def[held]>
# - queue clear
#
#IF YOU ARE USING THE QUESTS PLUGIN: You will need to create task scripts and a standing world script for the quests plugin to call. I detailed explanation of this can be found in the video posted above.
#######################################
questlogworld:
type: world
events:
on player left clicks queststatsi in inventory:
- inventory close
- narrate "Completed Quests: <player.quests.completed.add[<player.flag[completedquests]>].round>"
- wait 3
- inventory open d:in@<player>completedquests
- queue clear
on player left clicks completedquestsi in inventory:
- inventory close
- inventory open d:in@<player>completedquests
on player left clicks activequestsi in inventory:
- inventory close
- inventory open d:in@<player>questjournal
on player logs in:
- if <player.has_flag[questjournal].not> {
- note in@QuestJournalMenu as:<player>questjournal
- note in@questcompletemenu as:<player>completedquests
- flag player questjournal
}
questlog:
type: command
name: questlog
usage: /questlog
script:
- if <player.has_flag[questjournal].not> {
- note in@QuestJournalMenu as:<player>questjournal
- note in@questcompletemenu as:<player>completedquests
- flag player questjournal
}
- inventory open d:in@<player>questjournal
questcompletemenu:
type: inventory
title: Completed Quests
size: 45
slots:
- "[] [] [] [] [] [] [] [] []"
- "[] [] [] [] [] [] [] [] []"
- "[] [] [] [] [] [] [] [] []"
- "[] [] [] [] [] [] [] [] []"
- "[] [] [] [] [] [] [] [i@queststatsi] [i@activequestsi]"
QuestJournalMenu:
type: inventory
title: Active Quests
size: 45
slots:
- "[] [] [] [] [] [] [] [] []"
- "[] [] [] [] [] [] [] [] []"
- "[] [] [] [] [] [] [] [] []"
- "[] [] [] [] [] [] [] [] []"
- "[] [] [] [] [] [] [] [] [i@completedquestsi]"
completedquestsi:
type: item
material: book
display name: Quest Stats
lore:
- "Click here to view your completed quests."
queststatsi:
type: item
material: book
display name: Quest Stats
lore:
- "Click here to view your quest stats."
activequestsi:
type: item
material: book
display name: Active Quests.
lore:
- "Click here to access information."
- "about your active quests."