Date: 2015/01/07 10:33:35 UTC-08: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
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
# +----------------------------------
# | Angel scripts
# +----------------------------------
Angel:
type: assignment
interact scripts:
- 10 Angel_Script
actions:
on assignment:
# These triggers enable interaction with an NPC via chatting, clicking and entering proximity
- trigger name:chat state:true radius:10
- trigger name:click state:true
- trigger name:proximity state:true
- lookclose <npc> state:true
Angel_Script:
type: interact
steps:
1:
Click Trigger:
Script:
- narrate "<aqua>[Angel] -> You<&co> <yellow>What can I help you with?"
- zap step:Help
proximity Trigger:
exit:
Script:
- if <player.flag[angel]> {
- narrate "<aqua>The angel fades away."
- flag server AngeL:!
- despawn <npc>
}
Help:
Click Trigger:
Script:
- narrate "<aqua>[Angel] -> You<&co> <red>What can I help you with?"
chat Trigger:
1:
Trigger: "/regex:(?i)(switch)/"
Script:
- wait 1
- narrate "<aqua>[Angel] -> You<&co> <red>You can use the following commands to switch between your diferent characters<&co>"
- narrate "<blue>- <gold>/char switch <blue>(This only works if you have exactly 2 characters.)"
- narrate "<blue>- <gold>/char # <blue>(This will switch you to the character in a specific character slot number. e.g. /char 3)"
- narrate "<blue>- <gold>/char Character_Name <blue>(This will switch you to the character with that exact name.)"
- narrate "<blue>- type <gold>/char help <blue>to see more character commands"
2:
Trigger: "/regex:(?i)(name|rename|namechange)/"
Script:
- narrate "<dark_red>This command is only to be used in case of events and if you chose an indecent name."
- narrate "<dark_red>Your name changing will be recorded and abuse of this command will result in punishment."
- narrate "<red>If you wish to continue, please type your new name in chat."
# Setting the basic order of the filters in the file, for easy reading.
- yaml id:Names set Players.<player.name>.banned
- yaml id:Names set Players.<player.name>.swear_filter
- yaml id:Names set Players.<player.name>.titles_filter
- yaml id:Names set Players.<player.name>.number_filter
- yaml id:Names set Players.<player.name>.other_filter
- yaml id:Names set Players.<player.name>.names
- zap step:Rename
3:
Trigger: "/regex:(?i)(commands|cmds)/"
Script:
- wait 1
- narrate "<aqua>[Angel] -> You<&co> <red>You can find the commands on arithia at<&co> <aqua>http://www.arithia.com/commands"
4:
Trigger: "/regex:(?i)(character slot|character slots)/"
Script:
- narrate "<blue>At the moment you have used<&co> <yaml[Players].list_keys[Players.<player.name>.Characters].size>/<yaml[Players].read[Players.<player.name>.Donations.Character_Slots]> Character slots"
- narrate "<blue>You can buy more character slots in our store! http://www.arithia.com/store"
5:
Trigger: "/regex:(?i)(char|character)/"
Script:
- narrate "<blue>Type <gold>/char help <blue>to see the character commands"
# +----------------------------------
# | Professions
# +----------------------------------
6:
Trigger: "/regex:(?i)(profession|job)/"
Script:
- narrate "<blue>The available professions are<&co>"
- narrate "<red>----------"
- narrate "<gold>Miner"
- narrate "<gold>Blacksmith"
- narrate "<gold>Cook"
- narrate "<gold>Farmer"
- narrate "<gold>Alchemist"
- narrate "<gold>Hunter"
- narrate "<gold>Lumberjack"
- narrate "<gold>Engineer"
- narrate "<red>----------"
- if <yaml[Players].read[Players.<player.name>.Characters.%Character%.Jobs]> {
- narrate "<blue>You are currently a <gold><yaml[Players].read[Players.<player.name>.Characters.%Character%.Jobs].as_list>"
- narrate "<blue>You can change your job(s) by talking to the Steward"
} else {
- narrate "<blue>You currently don't have a job, to get a job, you must talk to the steward."
}
7:
Trigger: "/regex:(?i)(miner)/"
Script:
- narrate "<blue>Miners can mine all ores and craft<&co>"
- narrate "<red>--- crafting list ---"
- narrate "<gold>Wooden pickaxe"
8:
Trigger: "/regex:(?i)(blacksmith)/"
Script:
- narrate "<blue>Blacksmiths can smelt ores and metals into various items<&co>"
- narrate "<red>--- crafting list ---"
- narrate "<gold>all tools"
- narrate "<gold>all armor <red>(except leather)"
- narrate "<gold>all swords"
- narrate "<gold>all metal blocks"
- narrate "<gold>iron doors and trap doors"
- narrate "<gold>cauldron"
- narrate "<gold>throwing knives"
9:
Trigger: "/regex:(?i)(cook)/"
Script:
- narrate "<blue>Cooks can cook and bake all food items<&co>"
- narrate "<red>--- crafting list ---"
- narrate "<gold>all breads"
- narrate "<gold>all stew"
- narrate "<gold>all meat"
- narrate "<gold>all cake"
- narrate "<gold>all vegatables"
10:
Trigger: "/regex:(?i)(farmer)/"
Script:
- narrate "<blue>Farmers can tile dirt, plant and harvest all crops<&co>"
- narrate "<red>--- crafting list ---"
- narrate "<gold>wooden hoe"
11:
Trigger: "/regex:(?i)(alchemist)/"
Script:
- narrate "<blue>Alchemists can brew potions and alcohol<&co>"
- narrate "<red>--- crafting list ---"
- narrate "<gold>glass bottles"
12:
Trigger: "/regex:(?i)(hunter)/"
Script:
- narrate "<blue>hunteres hunt animals for food and leather<&co>"
- narrate "<red>--- crafting list ---"
- narrate "<gold>all leather armor"
- narrate "<gold>bows"
- narrate "<gold>arrows"
13:
Trigger: "/regex:(?i)(lumberjack)/"
Script:
- narrate "<blue>Lumberjacks cut down trees and crafts wooden items<&co>"
- narrate "<red>--- crafting list ---"
- narrate "<gold>all wooden tools"
- narrate "<gold>wooden swords"
- narrate "<gold>armor stand"
- narrate "<gold>wooden blocks, stairs and slabs"
- narrate "<gold>fences"
- narrate "<gold>wooden doors"
- narrate "<gold>wooden trapdoor"
- narrate "<gold>chests"
14:
Trigger: "/regex:(?i)(engineer)/"
Script:
- narrate "<blue>Engineers works with all things that needs tinkering.<&co>"
- narrate "<red>--- crafting list ---"
- narrate "<gold>keys"
- narrate "<gold>buttons and levers"
- narrate "<gold>pistons"
- narrate "<gold>repeaters (candles)"
- narrate "<gold>watches and compasses"
- narrate "<gold>item frames"
- narrate "<gold>pictures"
15:
Trigger: "/regex:(?i)(bye|nvm|nevermind|nothing)/"
Script:
- narrate "<aqua>[Angel] -> You<&co> <red>Alright, I wish you a good day!"
- despawn <npc>
16:
Trigger: "/regex:.+/"
Script:
- narrate "<aqua>[Angel] -> You<&co> <red>Sorry I can't help you with that."
proximity Trigger:
exit:
Script:
- if <player.flag[angel]> {
- flag server Angel:!
- narrate "<aqua>The angel fades away."
- despawn <npc>
}
Rename:
chat Trigger:
1:
Trigger: "/regex:.* .*/"
Script:
- narrate "<red>You cannot have spaces in your character name."
- narrate "<red>ONLY write your character name. Separate spaces with underscores. E.g. FirstName_LastName"
2:
Trigger: "/regex:(?i)(bye|nvm|nevermind|nothing)/"
Script:
- narrate "<aqua>[Angel] -> You<&co> <red>Alright, I wish you a good day!"
- flag server Angel:!
- despawn <npc>
3:
Trigger: "/regex:(?i)(anus|anal|fuck|shit|balls|penis|arse|dick|lol|bitch|boner|arithia|douche|damn|dildo|fag|dumbass|dumass|cunt|nigger|niggah|pussy|queef|queer|skank|slut|testicle|titties|titty|vagina|whore|fatass|fat_ass|faggot|erection|god|jesus|bieber|person|bacon|bing|pong|asshat|ass_hat|assmunch|ass_munch|genital|clam|hairy|tampon|vulva|snatch|clit|cunnilingus|moose|bongos|fart|phalus|troll|throbb|ramrod|dingle|spunk|shoot|twat|sperm|twink|moning|moan|trouser|snake|snack|fanny|head|gobble|choke|shower|spank|dominatrix|drugs|cooter|beaver|tunnel|suck|hole|vibrator|furry|mound|biscuit|horny|meat|groin|joystick|love|kock|pimp|swag|yolo|gandalf|satan|death|juicy)/"
Script:
# Check if they have already been warned about choosing a name like this
# if they have, just ban them
- if <player.flag[Name_Warning]> {
- execute as_server "ban <player.name> For choosing an inapropiate name (<context.message>) containing (<context.keyword>), this is automated so if you feel this is unjustified please contact staff on www.arithia.com"
# adds 1 to the swear filter statistics
- yaml id:Names set statistics.banned:++
- yaml id:Names set statistics.swear_filter:++
# adds what name the player was banned for and the keyword that triggered it.
- yaml id:Names set Players.<player.name>.banned.<context.message>:<context.keyword>
- queue clear
}
# If they havn't gotten a warning, give them 1 chance to choose another word.
- if !<player.flag[Name_Warning]> {
- narrate "<&4>--=== WARNING ===--"
- narrate "<red>Please choose an approiate rp name!"
- narrate "<red>If you think <context.message> is approiate for a serious character name, contact staff!"
- narrate "<red>Write your character name. Seperate spaces with underscores. E.g. Firstname_Lastname"
- flag player Name_Warning
- zap step:2
- yaml id:Names set statistics.warned:++
- yaml id:Names set statistics.swear_filter:++
- yaml id:Names set Players.<player.name>.swear_filter.<context.message>:<context.keyword>
}
# titles filter
4:
Trigger: "/regex:(?i)(king|queen|prince|slayer|champion|ripper|paladin|princess|emperor|empress|master|lord|dwarf|mage|wizard|hero|assasin|cleric|sir|lady|baron|maquise|captain|major|doctor|mr|child|teen|adult|old|slave)/"
Script:
- narrate "<red>You cannot name your character <context.message>, Please don't use titles in your character name."
- narrate "<red>Write your character name. Seperate spaces with underscores. E.g. Firstname_Lastname"
- zap step:2
- yaml id:Names set statistics.titles_filter:++
- yaml id:Names set Players.<player.name>.titles_filter.<context.message>:<context.keyword>
# Number filter
5:
Trigger: "/regex:(\d+)/"
Script:
- narrate "<red>You cannot have numbers in your character name."
- narrate "<red>Write your character name. Seperate spaces with underscores. E.g. Firstname_Lastname"
- zap step:2
- yaml id:Names set statistics.number_filter:++
- yaml id:Names set Players.<player.name>.number_filter.<context.message>:<context.keyword>
# Other violating filters
5:
Trigger: "/regex:(?i)(wonderdude|drem|monkey|staff|moderator|event|Scripter|Plugin|owner|admin|creative|)/"
Script:
- narrate "<red>You cannot have numbers in your character name."
- narrate "<red>Write your character name. Seperate spaces with underscores. E.g. Firstname_Lastname"
- zap step:2
- yaml id:Names set statistics.other_filter:++
- yaml id:Names set Players.<player.name>.other_filter.<context.message>:<context.keyword>
6:
Trigger: "/regex:.+/"
Script:
- if <context.message.contains[_]> {
# Define a few keywords for the name changing
- define Player <player.name>
- define Character <player.flag[Character]>
# We have to figure out the number, to change the name of the character instead of making a new one
- define Char_Number <yaml[Players].list_keys[Players.%Player%.Characters].find[%Character%]>
- define New_Name <context.message>
# Saving their old name in case they back out of it.
- flag player Old_Name %Character%
# changing their name ingame
- execute as_server "name <player.name> %New_Name%"
# Setting their name in the file
- yaml id:Players set players.%Player%.Characters[%Char_Number%]:%New_Name%
# Changing their character flag to that name
- flag player Character:%New_Name%
- narrate "<red>Are you sure you want to name your character %New_Name%?"
- zap step:ConfirmName
} else {
- narrate "<red>Your character, must have a first name and a last name."
- wait 1
- narrate "<red>Write your character name. Seperate spaces with underscores. E.g. Firstname_Lastname"
- yaml id:Names set statistics.underscore_filter:++
# This one adds it to the list of succesful names a player have had.
- yaml id:Names set Players.<player.name>.names.<context.message>
}
proximity Trigger:
exit:
Script:
- if <player.flag[angel]> {
- flag server Angel:!
- narrate "<aqua>The angel fades away."
- despawn <npc>
}
ConfirmName:
chat Trigger:
1:
Trigger: "/regex:(?i)(yes|yeah|okay|sure|alright)/"
Script:
- narrate "<aqua>[Angel] -> You<&co> <red>Your character name has been changed to <player.flag[Character]>"
- zap step:1
- despawn <npc>
2:
Trigger: "/regex:.+/"
Script:
- execute as_server "removename <player.name>"
- narrate "<red>Write your character name. Separate spaces with underscores. E.g. Firstname_Lastname"
- zap step:Rename
proximity Trigger:
exit:
Script:
- if <player.flag[angel]> {
- flag server Angel:!
- narrate "<aqua>The angel fades away."
# Define a few keywords for the name changing
- define Player <player.name>
- define Character <player.flag[Character]>
# We have to figure out the number, to change the name of the character instead of making a new one
- define Char_Number <yaml[Players].list_keys[Players.%Player%.Characters].find[%Character%]>
# getting their old name
- define Old_Name <player.flag[Old_Name]>
# changing their name ingame
- execute as_server "name <player.name> %Old_Name%"
# Setting their name in the file
- yaml id:Players set players.%Player%.Characters[%Char_Number%]:%Old_Name%
- wait 1
- narrate "<red>Your renaming has been cancelled and you've gotten your old name<&co> <gold>%Old_Name% <red>back."
- flag player Old_Name:!
- despawn <npc>
}