- D1 Meta Docs - Denizen Script -
Home Page / Pi to one million places / Contact mcmonkey / Donate / Paste Scripts / Denizen Help /
You are browsing as a guest.
Login | Register








The script repo is an archive of historical scripts. For modern scripts, or to post your own, please use the Scripts forum section.





CLANS


By Bruno
Created: 2016/01/17 23:04:31 UTC-08:00 (8 years and 341 days ago)
Edited: 2016/02/08 09:34:00 UTC-08:00 (8 years and 319 days ago)
Likes: 1

Denizen Version: 0.9.7 dev
Script Version: 1.0.2
Description:

##Clans By Bruno##
##In use at Brunos Realm##
##www.brunosrealm.com##
##ip for play is play.brunosrealm.com##
##version release 1.0.2##


Download script | View raw 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
29100

#version beta 1.0.2
clan:
  type: command
  debug: false
  name: clan
  description: Brunos Clan Command
  usage"/clan create/edit/list/roster/info/ally/war/kick/resources/invite/resign [input]"
  permission: bruno.adventurer
  permission message<&5>Zeus<&f> Sorry, <player.name>, you don't have permission to manipulate clans.
  allowed help:
  - determine <player.has_permission[bruno.clan.test]||player.is_op>
  script:
  - choose <context.args.size>:
    - case 1:
      - choose <c.args.get[1]>:
        - case list:
          - narrate "<&5>Zeus<&f> You Must Provide <&2>[INPUT]<&f>, List <&2>ALL<&f>|<&2>ENEMIES<&f>|<&2>ALLIES<&f>"
        - default:
          - narrate "<&5>Zeus<&f> You Must Provide <&2>[INPUT]<&f><script.yaml_key[usage]>"
    - case 2:
      - choose <c.args.get[1]>:
        - case create:
          - choose <c.args.get[2]>:
            - default:
              - narrate "<&5>Zeus<&f> You are creating a clan called <c.args.get[2]>"
              - define clan_leader <player.name>
              - define clan_leader_uuid <player.uuid>
              - define clan_leader_dname p@<player.name>
              - define clan_tag <c.args.get[2]>
              - choose <player.money.is[OR_MORE].than[25]><c.args.get[2].length.is[or_more].than[2]><c.args.get[2].length.is[or_less].than[11]><server.get_players_flagged[clan_leader].formatted.contains[%clan_leader%]><server.get_players_flagged[clan_member].formatted.contains[%clan_leader%]><server.flag[clan_name].as_list.contains[%clan_tag%]>:
                - case truetruetruefalsefalsefalse:
                  - take money quantity:25
                  - wait 1t
                  - narrate "<&5>Zeus<&f> <&6>$<&f>25 <&2>Bruno Bucks <&f>Have Been Deducted From Your Bank Account."
                  - define clan_leader_money <player.money>
                  - flag server clan_name:->:%clan_tag%
                  - wait 1t
                  - flag <player> clan_tag:%clan_tag%
                  - wait 1t
                  - announce "<&5>Zeus<&f> <&2>%clan_tag%<&f> registered as a <red> clan."
                  - wait 1t
                  - flag server clan_leader:->:%clan_leader%
                  - wait 1t
                  - flag server clan_leader_uuid:->:%clan_leader_uuid%
                  - wait 1t
                  - flag <player> clan_leader:true
                  - wait 1t
                  - flag server %clan_tag%_leaders:->:%clan_leader%
                  - wait 1t
                  - flag server %clan_tag%_leaders_uuid:->:%clan_leader_uuid%
                  - wait 15
                  - announce "<&5>Zeus<&f> <&2>%clan_leader%<&f> registered as the leader of <&2>%clan_tag%."
                  - flag server clan_members:->:%clan_leader%
                  - wait 1t
                  - flag server clan_members_uuid:->:%clan_leader_uuid%
                  - wait 1t
                  - flag <player> clan_member:true
                  - wait 1t
                  - flag server %clan_tag%_members:->:%clan_leader%
                  - wait 1t
                  - flag server %clan_tag%_members_uuid:->:%clan_leader_uuid%
                  - wait 1t
                  - narrate "<&5>Zeus<&f> <&2><&f>Member Registered to your clan."
                  - flag server clan_officers:->:%clan_leader%
                  - wait 1t
                  - flag server clan_officers_uuid:->:%clan_leader_uuid%
                  - wait 1t
                  - flag server %clan_tag%_officers:->:%clan_leader%
                  - wait 1t
                  - flag server %clan_tag%_officers_uuid:->:%clan_leader_uuid%
                  - wait 1t
                  - flag <player> clan_officer:true
                  - wait 1t
                  - narrate "<&5>Zeus<&f> <&a><&2>Officer <&f>Registered to your clan."
                  - flag server %clan_tag%_resources_money:->:%clan_leader_money%
                  - wait 1t
                  - narrate "<&5>Hermes<&f> <&6>$<&sp><&2><server.flag[%clan_tag%_resources_money].round_to[2]> Registered as Clan's Total Money Resources."
                - case truetruetruefalsefalsetrue:
                  - narrate "<&5>Zeus<&f> This clantag <&2><%clan_tag%><&f> is already in use or it is prohibited. Please choose another."
                - default:
                  - narrate "<&5>Zeus<&f> The requirements to create a clan<&6>You must have $25 Bruno Bucks. <&3>You must not be part of any other clan. <&e>Your clan tag must be 2 to 11 characters long."
                - case "":
                    - narrate "<&5>Zeus<&f> The requirements to create a clan<&2>Your clan tag must be 2 to 11 characters long."
                - default:
                    - narrate "<&5>Zeus<&f> <&4>UNKOWN ERROR"
        - case edit:
          - narrate "<&5>Zeus<&f> Edit Your Clan Is Not Available Yet"
        - case list:
          - choose <c.args.get[2]>:
            - case enemies:
              - narrate "<&5>Zeus<&f> I dont know your enemies yet."
            - case allies:
              - narrate "<&5>Zeus<&f> I dont know your allies yet."
            - case all:
              - narrate "<&5>Zeus<&f> All known clans are <&2><server.flag[clan_name].as_list.formatted||No Clans Found>"
            - case "":
              - narrate "<&5>Zeus<&f> All known clans are <&2><server.flag[clan_name].as_list.formatted||No Clans Found>"
            - default:
              - narrate "<&5>Zeus<&f> All known clans are <&2><server.flag[clan_name].as_list.formatted||No Clans Found>"
        - case roster:
          - define clan_tag <c.args.get[2]>
          - narrate "<&5>Zeus<&f> <server.flag[%clan_tag%_members].as_list.formatted||Clan<&sp>Does<&sp>Not<&sp>Exist>"
        - case info:
          - narrate "<&5>Zeus<&f> Clan Info Is Not Available Yet"
        - case ally:
          - narrate "<&5>Zeus<&f> Ally A Clan Is Not Available Yet"
        - case war:
          - narrate "<&5>Zeus<&f> Go To War With A Clan Is Not Available Yet"
        - case kick:
          - narrate "<&5>Zeus<&f> Kick A Clan Member Is Not  Available Yet"
        - case resources:
          - define clan_tag <c.args.get[2]>
          - narrate "<&5>Zeus<&f> <&2>%clan_tag%<&sp>Resources<&6>$<&2><&sp><server.flag[%clan_tag%_resources_money]||0.00>"
        - case invite:
          - define invited p@<c.args.get[2]>
          - define invited_name <c.args.get[2]>
          - define clan_leader <player.flag[clan_leader].contains[true]>
          - define clan_name <player.flag[clan_tag]>
          - choose <def[invited].is_online><def[invited].flag[clan_member].contains[false]>:
            - case truetrue:
              - narrate targets:%invited% "You've been invited to join %clan_name%. If you want to join type /clan join %clan_name%"
              - flag <def[invited]> clan_invite:->:%clan_name%
            - default:
              - narrate "<&5>Zeus<&f> That player, %invited%, is not available to be invited to your clan right now."
        - case join:
          - define clan_tag <c.args.get[2]>
          - define clan_member <player.name>
          - define clan_member_uuid <player.uuid>
          - define clan_members <server.list_online_players.filter[flag[clan_tag].contains[%clan_tag%]].formatted>
          - choose <player.flag[clan_invite].contains[%clan_tag%]||false><player.flag[clan_member].contains[false]||false>:
            - case truetrue:
              - flag <player> clan_member:true
              - wait 1t
              - flag <player> clan_tag:%clan_tag%
              - wait 1t
              - flag server clan_members:->:%clan_member%
              - wait 1t
              - flag server clan_members_uuid:->:%clan_member_uuid%
              - wait 1t
              - flag server %clan_tag%_members:->:%clan_member%
              - wait 1t
              - flag server %clan_tag%_members_uuid:->:%clan_member_uuid%
              - wait 1t
              - announce "<&5>Zeus<&f> <player.name> has become a member of %clan_tag%."
              - flag server %clan_tag%_resources_money:+:<player.money>
              - wait 1t
              - narrate "<&5>Zeus<&f> <server.flag[%clan_tag%_resources_money]> Registered as Clan's Total Money Resources. And %clan_member% is now a member of your clan!" targets:<server.get_online_players_flagged[%clan_tag%].formatted>||<player>>
            - case truefalse:
              - narrate "<&5>Zeus<&f> You must leave the clan you are in first. Type /clan resign."
            - case falsetrue:
              - narrate "<&5>Zeus<&f> You were not invited to that clan. And you must leave the clan you are in first. Type /clan resign."
            - case falsefalse:
              - narrate "<&5>Zeus<&f> You were not invited to that clan. Please check the spelling and try again or contact an officer of that clan for an invite."
            - default:
              - narrate "<&5>Zeus<&f> You were not invited to that clan. Please check the spelling and try again or contact an officer of that clan for an invite."
        - case resign:
          - define clan_member '<player.name>'
          - define clan_member_uuid '<player.uuid>'
          - define player_clan_tag '<player.flag[clan_tag]>'
          - define clan_member_money '<player.money>'
          - define clan_tag '<c.args.get[2]>'
          - choose <player.flag[clan_tag].contains[%clan_tag%]><server.flag[clan_name].as_list.contains[%clan_tag%]><server.get_online_players_flagged[clan_leader].contains[%clan_member_uuid%]>:
            - case truetruetrue:
              - flag server clan_name:<-:%clan_tag%
              - wait 1t
              - flag server clan_leader:<-:%clan_member%
              - wait 1t
              - flag server clan_leader_uuid:<-:%clan_member_uuid%
              - wait 1t
              - flag <player> clan_leader:false
              - wait 1t
              - flag server %clan_tag%_leaders:<-:%clan_member%
              - wait 1t
              - flag server %clan_tag%_leaders_uuid:<-:%clan_member_uuid%
              - wait 1t
              - flag server clan_officers:<-:%clan_member%
              - wait 1t
              - flag server clan_officers_uuid:<-:%clan_member_uuid%
              - wait 1t
              - flag server %clan_tag%_officers:<-:%clan_member%
              - wait 1t
              - flag server %clan_tag%_officers_uuid:<-:%clan_member_uuid%
              - wait 1t
              - flag <player> clan_officer:false
              - wait 1t
              - flag server %clan_tag%_resources_money:!
              - wait 1t
              - flag <player> clan_tag:!
              - wait 1t
              - flag server clan_members:<-:%clan_member%
              - wait 1t
              - flag server clan_members_uuid:<-:%clan_members_uuid%
              - wait 1t
              - flag server %clan_tag%_members:<-:%clan_member%
              - wait 1t
              - flag server %clan_tag%_members_uuid:<-:%clan_member_uuid%
              - wait 1t
              - flag <player> clan_member:false
              - wait 1t
              - narrate "<&5>Zeus<&f> <red>You are removed from this clan and it has been deleted. You have been refunded your $25."
              - give money quantity:25
            - case truetruefalse:
              - flag <player> clan_tag:!
              - wait 1t
              - flag server clan_members:<-:%clan_member%
              - wait 1t
              - flag server clan_members_uuid:<-:%clan_members_uuid%
              - wait 1t
              - flag server %clan_tag%_members:<-:%clan_member%
              - wait 1t
              - flag server %clan_tag%_members_uuid:<-:%clan_member_uuid%
              - wait 1t
              - flag <player> clan_member:false
              - wait 1t
              - flag server %clan_tag%_resources_money:-:%clan_member_money%
              - wait 1t
              - narrate "<&5>Zeus<&f> <server.flag[%clan_tag%_resources_money]> Registered as Clan's Total Money Resources because %clan_member% resigned." targets:<server.get_online_players_flagged[%clan_tag%]>
              - narrate "<&5>Zeus<&f> <red>You are removed from this clan."
            - case falsetruefalse:
              - narrate "<&5>Zeus<&f> <red>You are not part of that clan.falsetruefalse"
            - case falsetruetrue:
              - narrate "<&5>Zeus<&f> <red>You are not part of that clan."
            - case truefalsetrue:
              - narrate "<&5>Zeus<&f> <red>That clan doesnt exist."
            - case falsefalsetrue:
              - narrate "<&5>Zeus<&f> <red>You are not part of that clan or it doesnt exist."
            - case falsefalsefalse:
              - narrate "<&5>Zeus<&f> <red>You are not part of that clan or it doesnt exist."
            - default:
              - narrate "<&5>Zeus<&f> <red>You are not part of that clan or it doesnt exist."
        - case help:
          - narrate "<&5>Zeus<&f> HELP:<red><script.yaml_key[usage]>"
        - default:
          - narrate "<&5>Zeus<&f> HELP:<red><script.yaml_key[usage]> because <bold>default error."
manageclan:
  type: command
  debug: false
  name: manageclan
  description: Brunos Clan Command
  usage"/manageclan edit/kick/place/delete [input]"
  aliases: 
  - mclan
  permission: bruno.clan.manage
  permission message<&5>Zeus<&f> Sorry, <player.name>, you don't have permission to manipulate clans.
  allowed help:
  - determine <player.has_permission[bruno.clan.test]||player.is_op>
  script:
  - if !<player.has_permission[bruno.clan.manage]||<context.server>> {
    - narrate "<&5>Zeus<&f> <red>You do not have permission do use this command."
    }
  - choose <c.args.get[1]>:
    - case delete:
      - define clan_tag <c.args.get[2]>
      - define clan_leader <server.list_players_flagged[clan_leader]>
      - if !<server.flag[clan_name].contains[%clan_tag%]> {
        - narrate "<&5>Zeus<&f> <red>This clantag is not in use. Please choose another."
        } else {
        - flag server clan_name:<-:%clan_tag%
        - wait 1t
        - flag server %clan_tag%_leader:!
        - wait 1t
        - flag server %clan_tag%_members:!
        - wait 1t
        - flag server %clan_tag%_officers:!
        - wait 1t
        - flag server %clan_tag%_resources_money:!
        - flag %clan_leader% clan_leader:false
        }
    - case edit:
      - narrate "<&5>Zeus<&f> Edit <c.args.get[2]> Is Not Available Yet"
    - case place:
      - narrate "<&5>Zeus<&f> place <c.args.get[2]||A Player> To <c.args.get[3]> Is Not Available Yet"
    - case kick:
      - narrate "<&5>Zeus<&f> Kick is not available yet"
#     - define clan_tag <c.args.get[3]>
#     - define clan_player <c.args.get[2]>
#     - define clan_player_money <c.args.get[2].money>
#     - if !<server.flag[%clan_tag%_members].contains[%clan_player%]> {
#       - narrate "<red>%clan_player% is not a member of %clan_tag% or %clan_tag% does not exist."
#       } else {
#       - flag server %clan_tag%_members:<-:%clan_player%
#       - flag server %clan_tag%_officers:<-:%clan_player%
#       - flag server %clan_tag%_resources:-:%clan_player_money%
#       }
    - case help:
      - narrate "<&5>Zeus<&f> <script.yaml_key[usage]>"
    - default:
      - narrate "<&5>Zeus<&f> <script.yaml_key[usage]>"







View History