-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprint.html
More file actions
419 lines (392 loc) · 23.7 KB
/
print.html
File metadata and controls
419 lines (392 loc) · 23.7 KB
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
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
<!DOCTYPE HTML>
<html lang="en" class="sidebar-visible no-js light">
<head>
<!-- Book generated using mdBook -->
<meta charset="UTF-8">
<title>EasterEggs Documentation</title>
<meta name="robots" content="noindex" />
<!-- Custom HTML head -->
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="theme-color" content="#ffffff" />
<link rel="icon" href="favicon.svg">
<link rel="shortcut icon" href="favicon.png">
<link rel="stylesheet" href="css/variables.css">
<link rel="stylesheet" href="css/general.css">
<link rel="stylesheet" href="css/chrome.css">
<link rel="stylesheet" href="css/print.css" media="print">
<!-- Fonts -->
<link rel="stylesheet" href="FontAwesome/css/font-awesome.css">
<link rel="stylesheet" href="fonts/fonts.css">
<!-- Highlight.js Stylesheets -->
<link rel="stylesheet" href="highlight.css">
<link rel="stylesheet" href="tomorrow-night.css">
<link rel="stylesheet" href="ayu-highlight.css">
<!-- Custom theme stylesheets -->
</head>
<body>
<!-- Provide site root to javascript -->
<script type="text/javascript">
var path_to_root = "";
var default_theme = window.matchMedia("(prefers-color-scheme: dark)").matches ? "navy" : "light";
</script>
<!-- Work around some values being stored in localStorage wrapped in quotes -->
<script type="text/javascript">
try {
var theme = localStorage.getItem('mdbook-theme');
var sidebar = localStorage.getItem('mdbook-sidebar');
if (theme.startsWith('"') && theme.endsWith('"')) {
localStorage.setItem('mdbook-theme', theme.slice(1, theme.length - 1));
}
if (sidebar.startsWith('"') && sidebar.endsWith('"')) {
localStorage.setItem('mdbook-sidebar', sidebar.slice(1, sidebar.length - 1));
}
} catch (e) { }
</script>
<!-- Set the theme before any content is loaded, prevents flash -->
<script type="text/javascript">
var theme;
try { theme = localStorage.getItem('mdbook-theme'); } catch(e) { }
if (theme === null || theme === undefined) { theme = default_theme; }
var html = document.querySelector('html');
html.classList.remove('no-js')
html.classList.remove('light')
html.classList.add(theme);
html.classList.add('js');
</script>
<!-- Hide / unhide sidebar before it is displayed -->
<script type="text/javascript">
var html = document.querySelector('html');
var sidebar = 'hidden';
if (document.body.clientWidth >= 1080) {
try { sidebar = localStorage.getItem('mdbook-sidebar'); } catch(e) { }
sidebar = sidebar || 'visible';
}
html.classList.remove('sidebar-visible');
html.classList.add("sidebar-" + sidebar);
</script>
<nav id="sidebar" class="sidebar" aria-label="Table of contents">
<div class="sidebar-scrollbox">
<ol class="chapter"><li class="chapter-item expanded "><a href="main.html"><strong aria-hidden="true">1.</strong> Introduction</a></li><li class="chapter-item expanded affix "><li class="part-title">GETTING STARTED</li><li class="chapter-item expanded "><div><strong aria-hidden="true">2.</strong> HOCON format</div></li><li class="chapter-item expanded "><a href="started/installing.html"><strong aria-hidden="true">3.</strong> Installing</a></li><li class="spacer"></li><li class="chapter-item expanded affix "><li class="part-title">GENERAL FETURES</li><li class="chapter-item expanded "><a href="features/category.html"><strong aria-hidden="true">4.</strong> Category</a></li><li class="chapter-item expanded "><a href="features/create.html"><strong aria-hidden="true">5.</strong> Create EasterEggs</a></li><li class="chapter-item expanded "><a href="features/actions.html"><strong aria-hidden="true">6.</strong> Actions</a></li><li><ol class="section"><li class="chapter-item expanded "><a href="features/actions/commands.html"><strong aria-hidden="true">6.1.</strong> Commands</a></li><li class="chapter-item expanded "><a href="features/actions/firework.html"><strong aria-hidden="true">6.2.</strong> Firework</a></li><li class="chapter-item expanded "><a href="features/actions/message.html"><strong aria-hidden="true">6.3.</strong> Message</a></li><li class="chapter-item expanded "><a href="features/actions/money.html"><strong aria-hidden="true">6.4.</strong> Money</a></li><li class="chapter-item expanded "><a href="features/actions/sound.html"><strong aria-hidden="true">6.5.</strong> Sound</a></li></ol></li><li class="chapter-item expanded "><a href="features/actions/finish.html"><strong aria-hidden="true">7.</strong> Finish action</a></li><li class="chapter-item expanded "><a href="features/placeholders.html"><strong aria-hidden="true">8.</strong> Placeholders</a></li><li class="chapter-item expanded "><div><strong aria-hidden="true">9.</strong> NPC</div></li><li class="chapter-item expanded "><a href="features/examples.html"><strong aria-hidden="true">10.</strong> Examples</a></li><li class="spacer"></li><li class="chapter-item expanded affix "><li class="part-title">FOR DEVELOPERS</li><li class="chapter-item expanded "><div><strong aria-hidden="true">11.</strong> Plugin API</div></li></ol>
</div>
<div id="sidebar-resize-handle" class="sidebar-resize-handle"></div>
</nav>
<div id="page-wrapper" class="page-wrapper">
<div class="page">
<div id="menu-bar-hover-placeholder"></div>
<div id="menu-bar" class="menu-bar sticky bordered">
<div class="left-buttons">
<button id="sidebar-toggle" class="icon-button" type="button" title="Toggle Table of Contents" aria-label="Toggle Table of Contents" aria-controls="sidebar">
<i class="fa fa-bars"></i>
</button>
<button id="theme-toggle" class="icon-button" type="button" title="Change theme" aria-label="Change theme" aria-haspopup="true" aria-expanded="false" aria-controls="theme-list">
<i class="fa fa-paint-brush"></i>
</button>
<ul id="theme-list" class="theme-popup" aria-label="Themes" role="menu">
<li role="none"><button role="menuitem" class="theme" id="light">Light (default)</button></li>
<li role="none"><button role="menuitem" class="theme" id="rust">Rust</button></li>
<li role="none"><button role="menuitem" class="theme" id="coal">Coal</button></li>
<li role="none"><button role="menuitem" class="theme" id="navy">Navy</button></li>
<li role="none"><button role="menuitem" class="theme" id="ayu">Ayu</button></li>
</ul>
<button id="search-toggle" class="icon-button" type="button" title="Search. (Shortkey: s)" aria-label="Toggle Searchbar" aria-expanded="false" aria-keyshortcuts="S" aria-controls="searchbar">
<i class="fa fa-search"></i>
</button>
</div>
<h1 class="menu-title">EasterEggs Documentation</h1>
<div class="right-buttons">
<a href="print.html" title="Print this book" aria-label="Print this book">
<i id="print-button" class="fa fa-print"></i>
</a>
</div>
</div>
<div id="search-wrapper" class="hidden">
<form id="searchbar-outer" class="searchbar-outer">
<input type="search" id="searchbar" name="searchbar" placeholder="Search this book ..." aria-controls="searchresults-outer" aria-describedby="searchresults-header">
</form>
<div id="searchresults-outer" class="searchresults-outer hidden">
<div id="searchresults-header" class="searchresults-header"></div>
<ul id="searchresults">
</ul>
</div>
</div>
<!-- Apply ARIA attributes after the sidebar and the sidebar toggle button are added to the DOM -->
<script type="text/javascript">
document.getElementById('sidebar-toggle').setAttribute('aria-expanded', sidebar === 'visible');
document.getElementById('sidebar').setAttribute('aria-hidden', sidebar !== 'visible');
Array.from(document.querySelectorAll('#sidebar a')).forEach(function(link) {
link.setAttribute('tabIndex', sidebar === 'visible' ? 0 : -1);
});
</script>
<div id="content" class="content">
<main>
<h1 id="introduction"><a class="header" href="#introduction">Introduction</a></h1>
<h1 id="eastereggs30"><a class="header" href="#eastereggs30">EasterEggs3.0</a></h1>
<p>This plugin allows you to create easter eggs (blocks, entities, <del>NPC</del>). By clicking<br />
them u can run various actions and events.</p>
<div style="break-before: page; page-break-before: always;"></div><h1 id="installing"><a class="header" href="#installing">Installing</a></h1>
<p>Copy the <strong>.jar</strong> file to your plugins folder. Run the server.
Now, go to the <strong>config.conf</strong>.<br />
You will see the following:</p>
<pre><code class="language-kotlin">database {
type: "MySQL"
host: "localhost"
database: "eastereggs"
port: 3306
user: "eastereggs"
password: "123123"
}
languageFile = "en"
</code></pre>
<p>To get help about the plugin type <code>/ee help</code>.</p>
<div style="break-before: page; page-break-before: always;"></div><h1 id="categories"><a class="header" href="#categories">Categories</a></h1>
<p>You can create several easter egg categories and assign different access rights to them for users.
For example, you have two categories, one of which is accessible to player A and one of which is not.
The access to the category is configured through the permissions <code>ee.type.<category_name></code></p>
<p>To create a new category type <code>/ee category create <category_name></code>.</p>
<p>To delete any category type <code>/ee category delete <category_name></code>. <em>If easter eggs from this category were already found by someone
they will be deleted from the database.</em></p>
<div style="break-before: page; page-break-before: always;"></div><h1 id="create-eastereggs"><a class="header" href="#create-eastereggs">Create EasterEggs</a></h1>
<p>Once you've created the group u can start editing it and adding new easter eggs by
typing <code>/ee edit <category_name></code>.</p>
<p>To add a new easter egg just click RMB on any block/armorstand/painting/frame/<del>npc</del>.
A new easter eggs with unique ID will be created.</p>
<p>To remove any easter egg just click LBM on it while editing.</p>
<h2 id="adding-actions-to-easter-eggs"><a class="header" href="#adding-actions-to-easter-eggs">Adding actions to easter eggs</a></h2>
<p>Easter eggs actions are adding in edit mode. To add an action just type
<code>/ee action add <easter_egg_id> <action_name> <action_data></code></p>
<p><code><action_name></code> value is the name of one of the following action types:</p>
<table><thead><tr><th>Param</th><th>Description</th></tr></thead><tbody>
<tr><td><code>message</code></td><td>Chat/actiobar/title message.</td></tr>
<tr><td><code>commands</code></td><td>Running commands by the player or server</td></tr>
<tr><td><code>sound</code></td><td>Playing sound for the player</td></tr>
<tr><td><code>money</code></td><td>Gives any amount of money</td></tr>
<tr><td><code>firework</code></td><td>Launching a firework</td></tr>
</tbody></table>
<p>Those actions are in the json format. Data depends on the variables of
specified action.</p>
<div style="break-before: page; page-break-before: always;"></div><h1 id="actions"><a class="header" href="#actions">Actions</a></h1>
<p>Actions are what will be done when the egg is found</p>
<p>Here is a list of all available actions:</p>
<ul>
<li><a href="features/./actions/commands.html">Commands</a> - command execution</li>
<li><a href="features/./actions/firework.html">Firework</a> - fireworks launch</li>
<li><a href="features/./actions/message.html">Message</a> - displaying the message on the screen</li>
<li><a href="features/./actions/money.html">Money</a> - disbursement of money</li>
<li><a href="features/./actions/sound.html">Sound</a> - sound payback</li>
</ul>
<div style="break-before: page; page-break-before: always;"></div><h1 id="commands"><a class="header" href="#commands">Commands</a></h1>
<p>Action to execute commands on behalf of the player or console</p>
<h3 id="structure"><a class="header" href="#structure">Structure</a></h3>
<table><thead><tr><th>Param</th><th>Description</th><th>Value type</th></tr></thead><tbody>
<tr><td><code>player</code></td><td>Commands list. Specifies whether run a command by console</td><td>List of String</td></tr>
<tr><td><code>console</code></td><td>Commands list. Specifies whether run a command by player</td><td>List of String</td></tr>
</tbody></table>
<h3 id="examples"><a class="header" href="#examples">Examples</a></h3>
<p>Example json format:<br />
<code>{console:["Command 1", "Command 2"]}</code></p>
<p>Example command to add action:<br />
<code>/ee action add <egg_id> commands {player=["home", "say Hello"] console=["broadcast Hi!"]}</code></p>
<h3 id="example-config"><a class="header" href="#example-config">Example config</a></h3>
<pre><code class="language-kotlin">title = "Eggs Category"
hidePlayerData = false
category = "category2"
"0" {
location = "world, 0.0, 1.0, 0.0"
type = "BLOCK"
id = 0
actions {
commands {
player = [
"home",
"money"
]
console = "say hello!"
}
}
}
</code></pre>
<div style="break-before: page; page-break-before: always;"></div><h1 id="message"><a class="header" href="#message">Message</a></h1>
<p>The action that sets off the fireworks</p>
<h3 id="structure-1"><a class="header" href="#structure-1">Structure</a></h3>
<table><thead><tr><th>Param</th><th>Description</th><th>Default</th><th>Value type</th></tr></thead><tbody>
<tr><td><code>power</code></td><td>The distance the fireworks will fly. power = 0 ~ 4-5 blocks</td><td>0</td><td>Integer</td></tr>
<tr><td><code>effects</code></td><td>Effects list</td><td>Random</td><td>List of String</td></tr>
</tbody></table>
<p>Colors for effects must be set in HEX. The number of effects is unlimited.</p>
<h3 id="examples-1"><a class="header" href="#examples-1">Examples</a></h3>
<p>At the moment, this action can only be added via config.</p>
<h3 id="example-config-1"><a class="header" href="#example-config-1">Example config</a></h3>
<pre><code class="language-kotlin">title = "Eggs Category"
hidePlayerData = false
category = "category2"
"0" {
location = "world, 0.0, 0.0, 0.0"
type = "BLOCK"
id = 0;
actions {
firework {
power = 1
effects: [
{
type = BALL
trail = false
colors: [
"FF00FF",
"FF00FF",
"F000F0"
]
fadeColors: [
"000000",
"FF0000"
]
}
]
}
}
</code></pre>
<div style="break-before: page; page-break-before: always;"></div><h1 id="message-1"><a class="header" href="#message-1">Message</a></h1>
<p>Action to display text on the player's screen. This can be either a regular chat message to the player or an action bar & title with subtitle</p>
<h3 id="structure-2"><a class="header" href="#structure-2">Structure</a></h3>
<table><thead><tr><th>Param</th><th>Description</th><th>Default value</th><th>Value type</th></tr></thead><tbody>
<tr><td><code>messages</code></td><td>List of messages displaying in the chat. That's how it looks in</td><td></td><td>String</td></tr>
<tr><td><code>title</code></td><td>Title message</td><td></td><td>String</td></tr>
<tr><td><code>subTitle</code></td><td>Subtitle message</td><td></td><td>String</td></tr>
<tr><td><code>actionbar</code></td><td>Actionbar message</td><td></td><td>String</td></tr>
<tr><td><code>fadeIn</code></td><td>Title fade in period in ticks <em>(1 second = 20 ticks)</em></td><td>10 (in ticks)</td><td>Integer</td></tr>
<tr><td><code>fadeOut</code></td><td>Title fade out period in ticks</td><td>10 (in ticks)</td><td>Integer</td></tr>
<tr><td><code>stay</code></td><td>Delay period before fade out starts in ticks</td><td>30 (in ticks)</td><td>Integer</td></tr>
</tbody></table>
<p><code>fadeIn</code>, <code>fadeOut</code>, <code>stay</code> parameters only affect the following <code>actionBar</code>, <code>title</code> or <code>subTitle</code> parameters</p>
<h3 id="examples-2"><a class="header" href="#examples-2">Examples</a></h3>
<p>Example json format:<br />
<code>{messages:["Message 1", "Message 2"]}</code></p>
<p>For example, if u want to display something in actionbar, you should type:<br />
<code>/ee action add <egg_id> message {actionbar:"Hello, world!"}</code><br />
or<br />
<code>/ee action add <egg_id> message {messages=["&eFirst", "&cSecond"]}</code></p>
<h3 id="example-config-2"><a class="header" href="#example-config-2">Example config</a></h3>
<pre><code class="language-kotlin">title = "Eggs Category"
hidePlayerData = false
category = "category2"
"0" {
location = "world, 0.0, 1.0, 0.0"
type = "BLOCK"
id = 0
actions {
message {
messages: [
"Hello world!",
"..."
]
title = "Title text"
subTitle = "subtitle text"
actionBar = "Actionbar text"
fadeIn = 10
stay = 40
fadeOut = 10
}
}
}
</code></pre>
<div style="break-before: page; page-break-before: always;"></div><h1 id="money"><a class="header" href="#money">Money</a></h1>
<p>Action to give money to a player</p>
<h3 id="structure-3"><a class="header" href="#structure-3">Structure</a></h3>
<table><thead><tr><th>Param</th><th>Description</th><th>Value type</th></tr></thead><tbody>
<tr><td><code>money</code></td><td>The amount of money to be handed out</td><td>Float or Integer</td></tr>
</tbody></table>
<h3 id="examples-3"><a class="header" href="#examples-3">Examples</a></h3>
<p>At the moment, this action can only be added via config.</p>
<h3 id="example-config-3"><a class="header" href="#example-config-3">Example config</a></h3>
<pre><code class="language-kotlin">title = "Eggs Category"
hidePlayerData = false
category = "category2"
"0" {
location = "world, 0.0, 1.0, 0.0"
type = "BLOCK"
id = 0
actions {
money = 100
}
}
</code></pre>
<div style="break-before: page; page-break-before: always;"></div><h1 id="sound"><a class="header" href="#sound">Sound</a></h1>
<p>Action that plays the sound</p>
<h3 id="structure-4"><a class="header" href="#structure-4">Structure</a></h3>
<table><thead><tr><th>Param</th><th>Description</th><th>Default</th><th>Value type</th></tr></thead><tbody>
<tr><td><code>type</code></td><td>Sound name. Here you can find all of them: <a href="https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Sound.html">Sound types</a></td><td></td><td>String</td></tr>
<tr><td><code>location</code></td><td>Sound format playback location: <code>"world,x,y,z"</code></td><td>Player location</td><td>String</td></tr>
<tr><td><code>pitch</code></td><td>The pitch of the volume</td><td>1.0</td><td>Float</td></tr>
<tr><td><code>volume</code></td><td>How loud the sound</td><td>1.0</td><td>Float</td></tr>
</tbody></table>
<h3 id="examples-4"><a class="header" href="#examples-4">Examples</a></h3>
<p>Example json format:<br />
<code>{type="SOUND_TYPE_NAME" location="world,0,0,0"}</code></p>
<p>Command to add an action for an easter egg:<br />
<code>/ee action add <egg_id> sound {type="ENTITY_PLAYER_LEVELUP" location="world,0,60,-133"}</code></p>
<h3 id="example-config-4"><a class="header" href="#example-config-4">Example config</a></h3>
<pre><code class="language-kotlin">title = "Eggs Category"
hidePlayerData = false
category = "category2"
"0" {
location = "world, 0.0, 1.0, 0.0"
type = "BLOCK"
id = 0
actions {
sound {
type: "ENTITY_PLAYER_LEVELUP"
location: "world, -99.47, 4.0, -380.93"
}
}
}
</code></pre>
<div style="break-before: page; page-break-before: always;"></div><h1 id="finish-action"><a class="header" href="#finish-action">Finish action</a></h1>
<p>The action that sets off the fireworks</p>
<h3 id="example-config-5"><a class="header" href="#example-config-5">Example config</a></h3>
<pre><code class="language-kotlin">title = "Eggs Category"
hidePlayerData = false
category = "category2"
finishAction {
sound = "UI_TOAST_CHALLENGE_COMPLETE"
message {
title = "&aFinish!"
subtitle = "&eyou have found them all :)"
fadeIn = 10
fadeOut = 10
stay = 50
}
}
</code></pre>
<div style="break-before: page; page-break-before: always;"></div><h1 id="placeholders"><a class="header" href="#placeholders">Placeholders</a></h1>
<p><a href="https://www.spigotmc.org/resources/placeholderapi.6245/">PlaceholderAPI</a> support has been added to work with third-party plugins Available placeholders:<br />
<code>%ee_found_<name>%</code> - Number of found easter eggs in the group <code><name></code><br />
<code>%ee_count_<name>%</code> - Total number of easter eggs in the group <code><name></code> </p>
<div style="break-before: page; page-break-before: always;"></div><h1 id="examples-5"><a class="header" href="#examples-5">Examples</a></h1>
</main>
<nav class="nav-wrapper" aria-label="Page navigation">
<!-- Mobile navigation buttons -->
<div style="clear: both"></div>
</nav>
</div>
</div>
<nav class="nav-wide-wrapper" aria-label="Page navigation">
</nav>
</div>
<script type="text/javascript">
window.playground_copyable = true;
</script>
<script src="elasticlunr.min.js" type="text/javascript" charset="utf-8"></script>
<script src="mark.min.js" type="text/javascript" charset="utf-8"></script>
<script src="searcher.js" type="text/javascript" charset="utf-8"></script>
<script src="clipboard.min.js" type="text/javascript" charset="utf-8"></script>
<script src="highlight.js" type="text/javascript" charset="utf-8"></script>
<script src="book.js" type="text/javascript" charset="utf-8"></script>
<!-- Custom JS scripts -->
<script type="text/javascript">
window.addEventListener('load', function() {
window.setTimeout(window.print, 100);
});
</script>
</body>
</html>