-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathse.sc
2939 lines (2588 loc) · 149 KB
/
se.sc
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
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
//ScarpetEdit
import('math','_round', '_euclidean_sq', '_vec_length');
//# New commands format:
//# [command_for_carpet, interpretation_for_carpet, false] (will hide it from help menu)
//# [command_for_carpet, interpretation_for_carpet, [optional_arguments_since, description, description_tooltip, description_action]]
//# optional_arguments_since is the position of the first arg to make optional (<arg> to [arg]). If none, use -1
//#
//# Suggestion is derived from command_for_carpet, everything before the first `<`.
//# Command prefix (/se) is automatically added to description_action
//# description_action accepts both execute and suggest actions, by prefixing it with either `!` or `?` (needed)
//# Both description and description_tooltip must be a language string, or a lambda if string needs args.
//# Try to fit each entry in a single line (help menu) for proper pagination (until something is done).
base_commands_map = [
['', _()->_help(1), false],
['help', _()->_help(1), false],
['help <page>', '_help', [0, 'help_cmd_help', null, null]],
['lang', ['_change_lang',null], false],
['lang <lang>', '_change_lang', [0, 'help_cmd_lang', _()->_translate('help_cmd_lang_tooltip',_get_lang_list()), null]],
['set <block>', ['set_in_selection',null,null], false],
['set <block> <replacement>', ['set_in_selection',null], [1, 'help_cmd_set', 'help_cmd_set_tooltip', null]],
['set <block> f <flag>', _(block,flag)->set_in_selection(block,null,flag), false], //TO-DO Help for flags
['set <block> <replacement> f <flag>', 'set_in_selection', false],
['walls <block>', ['walls', 'xz', null, null], false],
['walls <block> <sides>', ['walls', null, null], false],
['walls <block> <sides> <replacement>', ['walls', null], [1, 'help_cmd_walls', 'help_cmd_walls_tooltip', null]],
['walls <block> f <flags>', _(block,flags)->walls(block,'xz',null,flags), false],
['walls <block> <sides> f <flags>', _(block,sides,flags)->walls(block,sides,null,flags), false],
['walls <block> <sides> <replacement> f <flags>', 'walls', false],
['outline_selection <block>', ['outline_sel', null, null], false],
['outline_selection <block> <replacement>', ['outline_sel', null], [1, 'help_cmd_outline', null, null]],
['outline_selection <block> f <flags>', _(block,flags)->outline_sel(block,null,flags), false],
['outline_selection <block> <replacement> f <flags>', 'outline_sel', false],
['undo', ['undo', 1, null], false],
['undo <moves>', ['undo', null], [0, 'help_cmd_undo', null, null]],
['undo all', ['undo', 0, null], [-1, 'help_cmd_undo_all', null, null]],
['undo f <flag>', _(flag) -> undo(1, flag), false],
['undo <moves> f <flag>', 'undo', false],
['undo all f <flag>', _(flag) -> undo(0, flag), false],
['undo history', 'print_history', [-1, 'help_cmd_undo_history', null, null]],
['redo', ['redo', 1, null], false],
['redo <moves>', ['redo', null], [0, 'help_cmd_redo', 'help_cmd_redo_tooltip', null]],
['redo all', ['redo', 0, null], [-1, 'help_cmd_redo_all', null, null]],
['redo f <flag>', _(flag) -> redo(1, flag), false],
['redo <moves> f <flag>', 'redo', false],
['redo all f <flag>', _(flag) -> redo(0, flag), false],
['wand', ['_set_or_give_wand',null], [-1, 'help_cmd_wand', null, null]],
['wand <wand>', '_set_or_give_wand', [-1, 'help_cmd_wand_2', null, null]],
['angel', '_give_angel_block_item', [-1, 'help_cmd_angel_give', null, null]],
['angel new', '_set_angel_block_item', [-1, 'help_cmd_angel_new', null, null]],
['angel clear', '_clear_angel_block_item', [-1, 'help_cmd_angel_clear', null, null]],
['rotate <pos> <degrees>', ['rotate', 'y', null], false],//will replace old stuff if need be
['rotate <pos> <degrees> f <flag>', _(pos, deg, flag) -> rotate(pos, deg, 'y', flag), false],//will replace old stuff if need be
['rotate <pos> <degrees> <axis>', ['rotate', null], [2, 'help_cmd_rotate', 'help_cmd_rotate_tooltip', null]],//will replace old stuff if need be
['rotate <pos> <degrees> <axis> f <flag>', 'rotate', false],//will replace old stuff if need be
['stack', ['stack',1,null,null], false],
['stack <count>', ['stack',null,null], false],
['stack <count> <direction>', ['stack',null], [0, 'help_cmd_stack', 'help_cmd_stack_tooltip', null]],
['stack f <flag>', _(flags)->stack(1,null,flags), false], //TODO here too Help for flags
['stack <count> f <flag>', _(count,flags)->stack(count,null,flags), false],
['stack <count> <direction> f <flag>', 'stack', false],
['expand <pos> <magnitude>', 'expand', [-1, 'help_cmd_expand', 'help_cmd_expand_tooltip', null]],
['move <pos>', ['move',null], [-1, 'help_cmd_move', null, null]],
['move <pos> f <flag>', 'move', false], //TODO flags help
['copy clear_clipboard',_()->(global_clipboard=[];_print(player(),'clear_clipboard',player())),[-1,'help_cmd_clear_clipboard',null,null]],
['copy',['_copy',null, false],false],
['copy force',['_copy',null, true],false],
['copy <pos>',['_copy', false],[-1,'help_cmd_copy','help_cmd_copy_tooldtip',null]],
['copy <pos> force',['_copy', true],false],
['paste',['paste', null, null],[-1,'help_cmd_paste',null,null]],
['paste f <flag>',_(flags)->paste(null, flags),false],//todo flags help
['paste <pos>',['paste', null],false],
['paste <pos> f <flag>','paste',false],//todo last flags help
['selection clear', 'clear_selection', false], //TODO help for this and below
['selection expand', _()->selection_expand(1), false],
['selection expand <amount>', 'selection_expand', false],
['selection move', _() -> selection_move(1, null), false],
['selection move <amount>', _(n)->selection_move(n, null), false],
['selection move <amount> <direction>', 'selection_move',false],
['hollow', ['_hollow', null, null], false],
['hollow <block>', ['_hollow', null], [0, 'help_cmd_hollow', 'help_cmd_hollow_tooltip', null]],
['hollow f <flag>', _(flag) -> _hollow(null, flag), false],
['hollow <block> f <flag>', '_hollow', false],
['outline <block>', ['_outline', null, false, null], false],
['outline <block> <outline_block>', ['_outline', false, null], [1, 'help_cmd_outline', 'help_cmd_outline_tooltip', false]],
['outline <block> <outline_block> force', ['_outline', true, null], [1, 'help_cmd_outline_force', 'help_cmd_outline_tooltip', false]],
['outline <block> f <flag>', _(block, flag) -> _outline(block, null, false, flag), false],
['outline <block> <outline_block> f <flag>', _(block, out, flag) -> _outline(block, out, false, flag), false],
['outline <block> <outline_block> force f <flag>', _(block, out, flag) -> _outline(block, out, true, flag), false],
['flood <block>', ['flood_fill', null, null, null], false],
['flood <block> <axis>', ['flood_fill', null, null], false],
['flood <block> none', ['flood_fill', null, null, null], false],
['flood <block> <axis> <radius>', ['flood_fill', null], [1, 'help_cmd_flood', 'help_cmd_flood_tooltip', null]],
['flood <block> none <radius>', _(block, radius) -> flood_fill(block, null, radius, null), false],
['flood <block> f <flag>', _(block,flag) -> flood_fill(block, null, null, flag), false],
['flood <block> <axis> f <flag>', _(block, axis, flag) -> flood_fill(block, axis, null, flag), false],
['flood <block> none f <flag>', _(block, flag) -> flood_fill(block, null, null, flag), false],
['flood <block> <axis> <radius> f <flag>', 'flood_fill', false],
['flood <block> none <radius> f <flag>', _(block, radius, flag) -> flood_fill(block, null, radius, flag), false],
['drain', ['_drain', null, null], false],
['drain <radius>', ['_drain', null], [1, 'help_cmd_drain', 'help_cmd_drain_tooltip', null]],
['drain f <flag>', _(flag)->_drain(null, flag), false],
['drain <radius> f <flag>', '_drain', false],
['up', ['tp_up', 0], [-1,'help_cmd_up', 'help_cmd_up_tooltip', null]],
['up <amount>', 'tp_up', [-1,'help_cmd_up', 'help_cmd_up_tooltip', null]],
['brush clear', ['brush', 'clear', null], false],
['brush clear <brush>', _(brush)-> brush('clear', null, brush), [0, 'help_cmd_brush_clear', null, null]],
['brush list', ['brush', 'list', null], [-1, 'help_cmd_brush_list', null, null]],
['brush info', ['brush', 'info', null], false],
['brush info <brush>', _(brush)-> brush('info', null, brush), [0, 'help_cmd_brush_info', null, null]],
['brush reach', ['brush', 'reach', null], false],
['brush reach <length>', _(length)-> brush('reach', null, length), [0, 'help_cmd_brush_reach', null, null]],
['brush cube <block> <size>', _(block, size_int) -> brush('cube', null, block, size_int, null), false],
['brush cube <block> <size> f <flag>', _(block, size_int, flags) -> brush('cube', flags, block, size_int, null), false],
['brush cube <block> <size> <replacement>', _(block, size_int, replacement) -> brush('cube', null, block, size_int, replacement),
[2, 'help_cmd_brush_cube', 'help_cmd_brush_generic', null]],
['brush cube <block> <size> <replacement> f <flag>', _(block, size_int, replacement, flags) -> brush('cube', flags, block, size_int, replacement), false],
['brush cuboid <block> <x_size> <y_size> <z_size>', _(block, x_int, y_int, z_int) -> brush('cuboid', null, block, [x_int, y_int, z_int], null), false],
['brush cuboid <block> <x_size> <y_size> <z_size> f <flag>', _(block, x_int, y_int, z_int, flags) -> brush('cuboid', flags, block, [x_int, y_int, z_int], null), false],
['brush cuboid <block> <x_size> <y_size> <z_size> <replacement>', _(block, x_int, y_int, z_int, replacement) -> brush('cuboid', null, block, [x_int, y_int, z_int], replacement),
[4, 'help_cmd_brush_cuboid', 'help_cmd_brush_generic', null]],
['brush cuboid <block> <x_size> <y_size> <z_size> <replacement> f <flag>', _(block, x_int, y_int, z_int, replacement, flags) -> brush('cuboid', flags, block, [x_int, y_int, z_int], replacement), false],
['brush diamond <block> <size>', _(block, size_int) -> brush('diamond', null, block, size_int, null), false],
['brush diamond <block> <size> f <flag>', _(block, size_int, flags) -> brush('diamond', flags, block, size_int, null), false],
['brush diamond <block> <size> <replacement>', _(block, size_int, replacement) -> brush('diamond', null, block, size_int, replacement),
[2, 'help_cmd_brush_diamond', 'help_cmd_brush_generic', null]],
['brush diamond <block> <size> <replacement> f <flag>', _(block, size_int, replacement, flags) -> brush('diamond', flags, block, size_int, replacement), false],
['brush sphere <block> <radius>', _(block, radius) -> brush('sphere', null, block, radius, null), false],
['brush sphere <block> <radius> f <flag>', _(block, radius, flags) -> brush('sphere', flags, block, radius, null), false],
['brush sphere <block> <radius> <replacement>', _(block, radius, replacement) -> brush('sphere', null, block, radius, replacement),
[2, 'help_cmd_brush_sphere', 'help_cmd_brush_generic', null]],
['brush sphere <block> <radius> <replacement> f <flag>', _(block, radius, replacement, flags) -> brush('sphere', flags, block, radius, replacement), false],
['brush ellipsoid <block> <x_radius> <y_radius> <z_radius>', _(block, xr, yr, zr) -> brush('ellipsoid', null, block, [xr, yr, zr], null), false],
['brush ellipsoid <block> <x_radius> <y_radius> <z_radius> f <flag>', _(block, xr, yr, zr, flags) -> brush('ellipsoid', flags, block, [xr, yr, zr], null), false],
['brush ellipsoid <block> <x_radius> <y_radius> <z_radius> <replacement>', _(block, xr, yr, zr, replacement) -> brush('ellipsoid', null, block, [xr, yr, zr], replacement),
[2, 'help_cmd_brush_sphereellipsoid', 'help_cmd_brush_generic', null]],
['brush ellipsoid <block> <x_radius> <y_radius> <z_radius> <replacement> f <flag>', _(block, xr, yr, zr, replacement, flags) -> brush('ellipsoid', flags, block, [xr, yr, zr], replacement), false],
['brush cylinder <block> <radius> <height>', _(block, radius, height) -> brush('cylinder', null, block, radius, height, 'y', null), false],
['brush cylinder <block> <radius> <height> f <flag>', _(block, radius, height, flags) -> brush('cylinder', flags, block, radius, height, 'y', null), false],
['brush cylinder <block> <radius> <height> <axis>', _(block, radius, height, axis) -> brush('cylinder', null, block, radius, height, axis, null), false],
['brush cylinder <block> <radius> <height> <axis> f <flag>', _(block, radius, height, axis, flags) -> brush('cylinder', flags, block, radius, height, axis, null), false],
['brush cylinder <block> <radius> <height> <axis> <replacement>', _(block, radius, height, axis, replacement) -> brush('cylinder', null, block, radius, height, axis, replacement),
[2, 'help_cmd_brush_cylinder', 'help_cmd_brush_generic', null]],
['brush cylinder <block> <radius> <height> <axis> <replacement> f <flag>', _(block, radius, height, axis, replacement, flags) -> brush('cylinder', flags, block, radius, height, axis, replacement), false],
['brush cone <block> <radius> <height>', _(block, radius, height) -> brush('cone', null, block, radius, height, '+y', null), false],
['brush cone <block> <radius> <height> f <flag>', _(block, radius, height, flags) -> brush('cone', flags, block, radius, height, '+y', null), false],
['brush cone <block> <radius> <height> <saxis>', _(block, radius, height, axis) -> brush('cone', null, block, radius, height, axis, null), false],
['brush cone <block> <radius> <height> <saxis> f <flag>', _(block, radius, height, axis, flags) -> brush('cone', flags, block, radius, height, axis, null), false],
['brush cone <block> <radius> <height> <saxis> <replacement>', _(block, radius, height, axis, replacement) -> brush('cone', null, block, radius, height, axis, replacement),
[2, 'help_cmd_brush_cone', 'help_cmd_brush_generic', null]],
['brush cone <block> <radius> <height> <saxis> <replacement> f <flag>', _(block, radius, height, axis, replacement, flags) -> brush('cone', flags, block, radius, height, axis, replacement), false],
['brush pyramid <block> <side_size> <height>', _(block, radius, height) -> brush('cone', null, block, radius, height, '+y', null), false],
['brush pyramid <block> <side_size> <height> f <flag>', _(block, radius, height, flags) -> brush('cone', flags, block, radius, height, '+y', null), false],
['brush pyramid <block> <side_size> <height> <saxis>', _(block, radius, height, axis) -> brush('cone', null, block, radius, height, axis, null), false],
['brush pyramid <block> <side_size> <height> <saxis> f <flag>', _(block, radius, height, axis, flags) -> brush('cone', flags, block, radius, height, axis, null), false],
['brush pyramid <block> <side_size> <height> <saxis> <replacement>', _(block, radius, height, axis, replacement) -> brush('cone', null, block, radius, height, axis, replacement),
[2, 'help_cmd_brush_cone', 'help_cmd_brush_generic', null]],
['brush pyramid <block> <side_size> <height> <saxis> <replacement> f <flag>', _(block, radius, height, axis, replacement, flags) -> brush('cone', flags, block, radius, height, axis, replacement), false],
['brush flood <block>', _(block) -> brush('flood', null, block, null, null), false],
['brush flood <block> f <flag>', _(block, flags) -> brush('flood', flags, block, null, null), false],
['brush flood <block> <radius>', _(block, radius) -> brush('flood', null, block, radius, null), false],
['brush flood <block> <radius> f <flag>', _(block, radius, flags) -> brush('flood', flags, block, radius, null), false],
['brush flood <block> <radius> <axis>', _(block, radius, axis) -> brush('flood', null, block, radius, axis),
[1, 'help_cmd_brush_flood', 'help_cmd_brush_generic', null]],
['brush flood <block> <radius> <axis> f <flag>', _(block, radius, axis, flags) -> brush('flood', flags, block, radius, axis), false],
['brush flood <block> <radius> none', _(block, radius) -> brush('flood', null, block, radius, null), false],
['brush flood <block> <radius> none f <flag>', _(block, radius, flags) -> brush('flood', flags, block, radius, null), false],
['brush hollow', _() -> brush('hollow', null, 50), false],
['brush hollow <radius>', _(radius) -> brush('hollow', null, radius), [0, 'help_cmd_brush_hollow', 'help_cmd_brush_generic', false]],
['brush hollow f <flag>', _(flag) -> brush('hollow', flag, 50), false],
['brush hollow <radius> f <flag>', _(radius, flag) -> brush('hollow', flag, radius), false],
['brush outline <block>', _(block) -> brush('outline', null, block, 50, false), false],
['brush outline <block> <radius>', _(block, radius) -> brush('outline', null, block, radius, false), [1, 'help_cmd_brush_outline', 'help_cmd_brush_generic', false]],
['brush outline <block> f <flag>', _(block, flag) -> brush('outline', flag, block, 50, false), false],
['brush outline <block> <radius> f <flag>', _(block, radius, flag) -> brush('outline', flag, block, radius, false), false],
['brush outline <block> force', _(block) -> brush('outline', null, block, 50, true), false],
['brush outline <block> <radius> force', _(block, radius) -> brush('outline', null, block, radius, true), [1, 'help_cmd_brush_outline_force', 'help_cmd_brush_generic', false]],
['brush outline <block> force f <flag>', _(block, flag) -> brush('outline', flag, block, 50, true), false],
['brush outline <block> <radius> force f <flag>', _(block, radius, flag) -> brush('outline', flag, block, radius, true), false],
['brush line <block>', _(block) -> brush('line', null, block, null, null), false],
['brush line <block> f <flag>', _(block, flags) -> brush('line', flags, block, null, null), false],
['brush line <block> <length> ', _(block, length) -> brush('line', null, block, length, null), false],
['brush line <block> <length> f <flag>', _(block, length, flags) -> brush('line', flags, block, length, null), false],
['brush line <block> <length> <replacement>', _(block, length, replacement) -> brush('line', null, block, length, replacement),
[2, 'help_cmd_brush_line', 'help_cmd_brush_generic', null]],
['brush line <block> <length> <replacement> f <flag>', _(block, length, replacement, flags) -> brush('line', flags, block, length, replacement), false],
['brush paste ', _() -> brush('paste_brush', null), [-1, 'help_cmd_brush_paste', 'help_cmd_brush_generic', null]],
['brush paste f <flag>', _(flags) -> brush('paste_brush', flags), false],
['brush polygon prism <block> <radius> <height> <points>',
_(block, radius, height, n_points) -> brush('prism_polygon', null, block, radius, height, n_points, 'y', 0, null), false],
['brush polygon prism <block> <radius> <height> <points> f <flag>',
_(block, radius, height, n_points, flags) -> brush('prism_polygon', flags, block, radius, height, n_points, 'y', 0, null), false],
['brush polygon prism <block> <radius> <height> <points> <axis>',
_(block, radius, height, n_points, axis) -> brush('prism_polygon', null, block, radius, height, n_points, axis, 0, null), false],
['brush polygon prism <block> <radius> <height> <points> <axis> f <flag>',
_(block, radius, height, n_points, axis, flags) -> brush('prism_polygon', flags, block, radius, height, n_points, axis, 0, null), false],
['brush polygon prism <block> <radius> <height> <points> <axis> <degrees>',
_(block, radius, height, n_points, axis, rotation) -> brush('prism_polygon', null, block, radius, height, n_points, axis, rotation, null), false],
['brush polygon prism <block> <radius> <height> <points> <axis> <degrees> f <flag>',
_(block, radius, height, n_points, axis, rotation, flags) -> brush('prism_polygon', flags, block, radius, height, n_points, axis, rotation, null), false],
['brush polygon prism <block> <radius> <height> <points> <axis> <degrees> <replacement>',
_(block, radius, height, n_points, axis, rotation, replacement) -> brush('prism_polygon', null, block, radius, height, n_points, axis, rotation, replacement),
[4, 'help_cmd_brush_polygon', 'help_cmd_brush_generic', null]],
['brush polygon prism <block> <radius> <height> <points> <axis> <degrees> <replacement> f <flag>',
_(block, radius, height, n_points, axis, rotation, replacement, flags) -> brush('prism_polygon', flags, block, radius, height, n_points, axis, rotation, replacement), false],
['brush polygon pyramid <block> <radius> <height> <points>',
_(block, radius, height, n_points) -> brush('pyramid_polygon', null, block, radius, height, n_points, '+y', 0, null), false],
['brush polygon pyramid <block> <radius> <height> <points> f <flag>',
_(block, radius, height, n_points, flags) -> brush('pyramid_polygon', flags, block, radius, height, n_points, '+y', 0, null), false],
['brush polygon pyramid <block> <radius> <height> <points> <saxis>',
_(block, radius, height, n_points, saxis) -> brush('pyramid_polygon', null, block, radius, height, n_points, saxis, 0, null), false],
['brush polygon pyramid <block> <radius> <height> <points> <saxis> f <flag>',
_(block, radius, height, n_points, saxis, flags) -> brush('pyramid_polygon', flags, block, radius, height, n_points, saxis, 0, null), false],
['brush polygon pyramid <block> <radius> <height> <points> <saxis> <degrees>',
_(block, radius, height, n_points, saxis, rotation) -> brush('pyramid_polygon', null, block, radius, height, n_points, saxis, rotation, null), false],
['brush polygon pyramid <block> <radius> <height> <points> <saxis> <degrees> f <flag>',
_(block, radius, height, n_points, saxis, rotation, flags) -> brush('pyramid_polygon', flags, block, radius, height, n_points, saxis, rotation, null), false],
['brush polygon pyramid <block> <radius> <height> <points> <saxis> <degrees> <replacement>',
_(block, radius, height, n_points, saxis, rotation, replacement) -> brush('pyramid_polygon', null, block, radius, height, n_points, saxis, rotation, replacement),
[4, 'help_cmd_brush_polygon_pyramid', 'help_cmd_brush_generic', null]],
['brush polygon pyramid <block> <radius> <height> <points> <saxis> <degrees> <replacement> f <flag>',
_(block, radius, height, n_points, saxis, rotation, replacement, flags) -> brush('pyramid_polygon', flags, block, radius, height, n_points, saxis, rotation, replacement), false],
['brush star prism <block> <outer_radius> <inner_radius> <height> <points>',
_(block, outer_radius, inner_radius, height, n_points) -> brush('prism_star', null, block, outer_radius, inner_radius, height, n_points, 'y', 0, null), false],
['brush star prism <block> <outer_radius> <inner_radius> <height> <points> f <flag>',
_(block, outer_radius, inner_radius, height, n_points, flags) -> brush('prism_star', flags, block, outer_radius, inner_radius, height, n_points, 'y', 0, null), false],
['brush star prism <block> <outer_radius> <inner_radius> <height> <points> <axis>',
_(block, outer_radius, inner_radius, height, n_points, axis) -> brush('prism_star', null, block, outer_radius, inner_radius, height, n_points, axis, 0, null), false],
['brush star prism <block> <outer_radius> <inner_radius> <height> <points> <axis> f <flag>',
_(block, outer_radius, inner_radius, height, n_points, axis, flags) -> brush('prism_star', flags, block, outer_radius, inner_radius, height, n_points, axis, 0, null), false],
['brush star prism <block> <outer_radius> <inner_radius> <height> <points> <axis> <degrees>',
_(block, outer_radius, inner_radius, height, n_points, axis, rotation) -> brush('prism_star', null, block, outer_radius, inner_radius, height, n_points, axis, rotation, null), false],
['brush star prism <block> <outer_radius> <inner_radius> <height> <points> <axis> <degrees> f <flag>',
_(block, outer_radius, inner_radius, height, n_points, axis, rotation, flags) -> brush('prism_star', flags, block, outer_radius, inner_radius, height, n_points, axis, rotation, null), false],
['brush star prism <block> <outer_radius> <inner_radius> <height> <points> <axis> <degrees> <replacement>',
_(block, outer_radius, inner_radius, height, n_points, axis, rotation, replacement) -> brush('prism_star', null, block, outer_radius, inner_radius, height, n_points, axis, rotation, replacement),
[5, 'help_cmd_brush_star', 'help_cmd_brush_generic', null]],
['brush star prism <block> <outer_radius> <inner_radius> <height> <points> <axis> <degrees> <replacement> f <flag>',
_(block, outer_radius, inner_radius, height, n_points, axis, rotation, replacement, flags) -> brush('prism_star', flags, block, outer_radius, inner_radius, height, n_points, axis, rotation, replacement), false],
['brush star pyramid <block> <outer_radius> <inner_radius> <height> <points>',
_(block, outer_radius, inner_radius, height, n_points) -> brush('pyramid_star', null, block, outer_radius, inner_radius, height, n_points, '+y', 0, null), false],
['brush star pyramid <block> <outer_radius> <inner_radius> <height> <points> f <flag>',
_(block, outer_radius, inner_radius, height, n_points, flags) -> brush('pyramid_star', flags, block, outer_radius, inner_radius, height, n_points, '+y', 0, null), false],
['brush star pyramid <block> <outer_radius> <inner_radius> <height> <points> <saxis>',
_(block, outer_radius, inner_radius, height, n_points, saxis) -> brush('pyramid_star', null, block, outer_radius, inner_radius, height, n_points, saxis, 0, null), false],
['brush star pyramid <block> <outer_radius> <inner_radius> <height> <points> <saxis> f <flag>',
_(block, outer_radius, inner_radius, height, n_points, saxis, flags) -> brush('pyramid_star', flags, block, outer_radius, inner_radius, height, n_points, saxis, 0, null), false],
['brush star pyramid <block> <outer_radius> <inner_radius> <height> <points> <saxis> <degrees>',
_(block, outer_radius, inner_radius, height, n_points, saxis, rotation) -> brush('pyramid_star', null, block, outer_radius, inner_radius, height, n_points, saxis, rotation, null), false],
['brush star pyramid <block> <outer_radius> <inner_radius> <height> <points> <saxis> <degrees> f <flag>',
_(block, outer_radius, inner_radius, height, n_points, saxis, rotation, flags) -> brush('pyramid_star', flags, block, outer_radius, inner_radius, height, n_points, saxis, rotation, null), false],
['brush star pyramid <block> <outer_radius> <inner_radius> <height> <points> <saxis> <degrees> <replacement>',
_(block, outer_radius, inner_radius, height, n_points, saxis, rotation, replacement) -> brush('pyramid_star', null, block, outer_radius, inner_radius, height, n_points, saxis, rotation, replacement),
[5, 'help_cmd_brush_star_pyramid', 'help_cmd_brush_generic', null]],
['brush star pyramid <block> <outer_radius> <inner_radius> <height> <points> <saxis> <degrees> <replacement> f <flag>',
_(block, outer_radius, inner_radius, height, n_points, saxis, rotation, replacement, flags) -> brush('pyramid_star', flags, block, outer_radius, inner_radius, height, n_points, saxis, rotation, replacement), false],
['brush feature <feature> ', _(feature) -> brush('feature', null, feature), [-1, 'help_cmd_brush_feature', 'help_cmd_brush_generic', null]],
['brush drain', _()->brush('drain', null, 30), false],
['brush drain <radius>', _(radius)->brush('drain', null, radius), [0, 'help_cmd_brush_drain', 'help_cmd_brush_generic', null]],
['brush drain f <flag>', _(flag)->brush('drain', flag, 30), false],
['brush drain <radius> f <flag>', _(radius, flag)->brush('drain', flag, radius), [0, 'help_cmd_brush_drain', 'help_cmd_brush_generic', null]],
['brush spray <block>', _(block) -> brush('spray', null, block, 12, 100, null), false],
['brush spray <block> <size_degrees>', _(block, size) -> brush('spray', null, block, size, 100, null), false],
['brush spray <block> <size_degrees> <count>', _(block, size, count) -> brush('spray', null, block, size, count, null), false],
['brush spray <block> f <flag>', _(block, flag) -> brush('spray', flag, block, 12, 100, null), false],
['brush spray <block> <size_degrees> f <flag>', _(block, size, flag) -> brush('spray', flag, block, size, 100, null), false],
['brush spray <block> <size_degrees> <count> f <flag>', _(block, size, count, flag) -> brush('spray', flag, block, size, count, null), false],
['brush spray held_item', _() -> brush('spray', null, null, 12, 100, null), false],
['brush spray held_item <size_degrees>', _(size) -> brush('spray', null, null, size, 100, null), false],
['brush spray held_item <size_degrees> <count>', _(size, count) -> brush('spray', null, null, size, count, null), false],
['brush spray held_item f <flag>', _(flag) -> brush('spray', flag, null, 12, 100, null), false],
['brush spray held_item <size_degrees> f <flag>', _(size, flag) -> brush('spray', flag, null, size, 100, null), false],
['brush spray held_item <size_degrees> <count> f <flag>', _(size, count, flag) -> brush('spray', flag, null, size, count, null), false],
['brush spray <block> <size_degrees> <count> <replacement>', _(block, size, count, replacement) -> brush('spray', null, block, size, count, replacement), [1, 'help_cmd_brush_spray', 'help_cmd_brush_generic', null]],
['brush spray <block> <size_degrees> <count> <replacement> f <flag>', _(block, size, count, replacement, flag) -> brush('spray', flag, block, size, count, replacement), false],
['brush spray held_item <size_degrees> <count> <replacement>', _(size, count, replacement) -> brush('spray', null, null, size, count, replacement), [0, 'help_cmd_brush_spray_held', 'help_cmd_brush_generic', null]],
['brush spray held_item <size_degrees> <count> <replacement> f <flag>', _(size, count, replacement, flag) -> brush('spray', flag, null, size, count, replacement), false],
['shape cube <pos> <block> <size>', _(pos, block, size_int) -> shape('cube', pos, [block, size_int, null], null), false],
['shape cube <pos> <block> <size> f <flag>', _(pos, block, size_int, flags) -> shape('cube', pos, [block, size_int, null], flags), false],
['shape cube <pos> <block> <size> <replacement>', _(pos, block, size_int, replacement) -> shape('cube', pos, [block, size_int, replacement], null),
[2, 'help_cmd_brush_cube', null, null]],
['shape cube <pos> <block> <size> <replacement> f <flag>', _(pos, block, size_int, replacement, flags) -> shape('cube', pos, [block, size_int, replacement], flags), false],
['shape cuboid <pos> <block> <x_size> <y_size> <z_size>', _(pos, block, x_int, y_int, z_int) -> shape('cuboid', pos, [block, [x_int, y_int, z_int], null], null), false],
['shape cuboid <pos> <block> <x_size> <y_size> <z_size> f <flag>', _(pos, block, x_int, y_int, z_int, flags) -> shape('cuboid', pos, [block, [x_int, y_int, z_int], null], flags), false],
['shape cuboid <pos> <block> <x_size> <y_size> <z_size> <replacement>', _(pos, block, x_int, y_int, z_int, replacement) -> shape('cuboid', pos, [block, [x_int, y_int, z_int], replacement], null),
[4, 'help_cmd_brush_cuboid', 'help_cmd_brush_generic', null]],
['shape cuboid <pos> <block> <x_size> <y_size> <z_size> <replacement> f <flag>', _(pos, block, x_int, y_int, z_int, replacement, flags) -> shape('cuboid', pos, [block, [x_int, y_int, z_int], replacement], flags), false],
['shape diamond <pos> <block> <size>', _(pos, block, size_int) -> shape('diamond', pos, [block, size_int, null], null), false],
['shape diamond <pos> <block> <size> f <flag>', _(pos, block, size_int, flags) -> shape('diamond', pos, [block, size_int, null], flags), false],
['shape diamond <pos> <block> <size> <replacement>', _(pos, block, size_int, replacement) -> shape('diamond', pos, [block, size_int, replacement], null),
[2, 'help_cmd_brush_diamond', null, null]],
['shape sphere <pos> <block> <radius>', _(pos, block, radius) -> shape('sphere', pos, [block, radius, null], null), false],
['shape sphere <pos> <block> <radius> f <flag>', _(pos, block, radius, flags) -> shape('sphere', pos, [block, radius, null], flags), false],
['shape sphere <pos> <block> <radius> <replacement>', _(pos, block, radius, replacement) -> shape('sphere', pos, [block, radius, replacement], null),
[2, 'help_cmd_brush_sphere', 'help_cmd_brush_generic', null]],
['shape sphere <pos> <block> <radius> <replacement> f <flag>', _(pos, block, radius, replacement, flags) -> shape('sphere', pos, [block, radius, replacement], flags), false],
['shape ellipsoid <pos> <block> <x_radius> <y_radius> <z_radius>', _(pos, block, xr, yr, zr) -> shape('ellipsoid', pos, [block, [xr, yr, zr], null], null), false],
['shape ellipsoid <pos> <block> <x_radius> <y_radius> <z_radius> f <flag>', _(pos, block, xr, yr, zr, flags) -> shape('ellipsoid', pos, [block, [xr, yr, zr], null], flags), false],
['shape ellipsoid <pos> <block> <x_radius> <y_radius> <z_radius> <replacement>', _(pos, block, xr, yr, zr, replacement) -> shape('ellipsoid', pos, [block, [xr, yr, zr], replacement], null),
[2, 'help_cmd_brush_sphereellipsoid', 'help_cmd_brush_generic', null]],
['shape ellipsoid <pos> <block> <x_radius> <y_radius> <z_radius> <replacement> f <flag>', _(pos, block, xr, yr, zr, replacement, flags) -> shape('ellipsoid', pos, [block, [xr, yr, zr], replacement], flags), false],
['shape cylinder <pos> <block> <radius> <height>', _(pos, block, radius, height) -> shape('cylinder', pos, [block, radius, height, 'y', null], null), false],
['shape cylinder <pos> <block> <radius> <height> f <flag>', _(pos, block, radius, height, flags) -> shape('cylinder', pos, [block, radius, height, 'y', null], flags), false],
['shape cylinder <pos> <block> <radius> <height> <axis>', _(pos, block, radius, height, axis) -> shape('cylinder', pos, [block, radius, height, axis, null], null), false],
['shape cylinder <pos> <block> <radius> <height> <axis> f <flag>', _(pos, block, radius, height, axis, flags) -> shape('cylinder', pos, [block, radius, height, axis, null], flags), false],
['shape cylinder <pos> <block> <radius> <height> <axis> <replacement>', _(pos, block, radius, height, axis, replacement) -> shape('cylinder', pos, [block, radius, height, axis, replacement], null),
[2, 'help_cmd_brush_cylinder', 'help_cmd_brush_generic', null]],
['shape cylinder <pos> <block> <radius> <height> <axis> <replacement> f <flag>', _(pos, block, radius, height, axis, replacement, flags) -> shape('cylinder', pos, [block, radius, height, axis, replacement], flags), false],
['shape cone <pos> <block> <radius> <height>', _(pos, block, radius, height) -> shape('cone', pos, [block, radius, height, '+y', null], null), false],
['shape cone <pos> <block> <radius> <height> f <flag>', _(pos, block, radius, height, flags) -> shape('cone', pos, [block, radius, height, '+y', null], flags), false],
['shape cone <pos> <block> <radius> <height> <saxis>', _(pos, block, radius, height, axis) -> shape('cone', pos, [block, radius, height, axis, null], null), false],
['shape cone <pos> <block> <radius> <height> <saxis> f <flag>', _(pos, block, radius, height, axis, flags) -> shape('cone', pos, [block, radius, height, axis, null], flags), false],
['shape cone <pos> <block> <radius> <height> <saxis> <replacement>', _(pos, block, radius, height, axis, replacement) -> shape('cone', pos, [block, radius, height, axis, replacement], null),
[2, 'help_cmd_brush_cone', 'help_cmd_brush_generic', null]],
['shape pyramid <pos> <block> <side_size> <height>', _(pos, block, radius, height) -> shape('pyramid', pos, [block, radius, height, '+y', null], null), false],
['shape pyramid <pos> <block> <side_size> <height> f <flag>', _(pos, block, radius, height, flags) -> shape('pyramid', pos, [block, radius, height, '+y', null], flags), false],
['shape pyramid <pos> <block> <side_size> <height> <saxis>', _(pos, block, radius, height, axis) -> shape('pyramid', pos, [block, radius, height, axis, null], null), false],
['shape pyramid <pos> <block> <side_size> <height> <saxis> f <flag>', _(pos, block, radius, height, axis, flags) -> shape('pyramid', pos, [block, radius, height, axis, null], flags), false],
['shape pyramid <pos> <block> <side_size> <height> <saxis> <replacement>', _(pos, block, radius, height, axis, replacement) -> shape('pyramid', pos, [block, radius, height, axis, replacement], null),
[2, 'help_cmd_brush_cone', 'help_cmd_brush_generic', null]],
['shape polygon prism <pos> <block> <radius> <height> <points>',
_(pos, block, radius, height, n_points) -> shape('prism_polygon', pos, [block, radius, height, n_points, 'y', 0, null], null), false],
['shape polygon prism <pos> <block> <radius> <height> <points> f <flag>',
_(pos, block, radius, height, n_points, flags) -> shape('prism_polygon', pos, [block, radius, height, n_points, 'y', 0, null], flags), false],
['shape polygon prism <pos> <block> <radius> <height> <points> <axis>',
_(pos, block, radius, height, n_points, axis) -> shape('prism_polygon', pos, [block, radius, height, n_points, axis, 0, null], null), false],
['shape polygon prism <pos> <block> <radius> <height> <points> <axis> f <flag>',
_(pos, block, radius, height, n_points, axis, flags) -> shape('prism_polygon', pos, [block, radius, height, n_points, axis, 0, null], flags), false],
['shape polygon prism <pos> <block> <radius> <height> <points> <axis> <degrees>',
_(pos, block, radius, height, n_points, axis, rotation) -> shape('prism_polygon', pos, [block, radius, height, n_points, axis, rotation, null], null), false],
['shape polygon prism <pos> <block> <radius> <height> <points> <axis> <degrees> f <flag>',
_(pos, block, radius, height, n_points, axis, rotation, flags) -> shape('prism_polygon', pos, [block, radius, height, n_points, axis, rotation, null], flags), false],
['shape polygon prism <pos> <block> <radius> <height> <points> <axis> <degrees> <replacement>',
_(pos, block, radius, height, n_points, axis, rotation, replacement) ->shape('prism_polygon', pos, [block, radius, height, n_points, axis, rotation, replacement], null),
[4, 'help_cmd_brush_polygon', 'help_cmd_brush_generic', null]],
['shape polygon prism <pos> <block> <radius> <height> <points> <axis> <degrees> <replacement> f <flag>',
_(pos, block, radius, height, n_points, axis, rotation, replacement, flags) -> shape('prism_polygon', pos, [block, radius, height, n_points, axis, rotation, replacement], flags), false],
['shape polygon pyramid <pos> <block> <radius> <height> <points>',
_(pos, block, radius, height, n_points) -> shape('pyramid_polygon', pos, [block, radius, height, n_points, '+y', 0, null], null), false],
['shape polygon pyramid <pos> <block> <radius> <height> <points> f <flag>',
_(pos, block, radius, height, n_points, flags) -> shape('pyramid_polygon', pos, [block, radius, height, n_points, '+y', 0, null], flags), false],
['shape polygon pyramid <pos> <block> <radius> <height> <points> <saxis>',
_(pos, block, radius, height, n_points, saxis) -> shape('pyramid_polygon', pos, [block, radius, height, n_points, saxis, 0, null], null), false],
['shape polygon pyramid <pos> <block> <radius> <height> <points> <saxis> f <flag>',
_(pos, block, radius, height, n_points, saxis, flags) -> shape('pyramid_polygon', pos, [block, radius, height, n_points, saxis, 0, null], flags), false],
['shape polygon pyramid <pos> <block> <radius> <height> <points> <saxis> <degrees>',
_(pos, block, radius, height, n_points, saxis, rotation) -> shape('pyramid_polygon', pos, [block, radius, height, n_points, saxis, rotation, null], null), false],
['shape polygon pyramid <pos> <block> <radius> <height> <points> <saxis> <degrees> f <flag>',
_(pos, block, radius, height, n_points, saxis, rotation, flags) -> shape('pyramid_polygon', pos, [block, radius, height, n_points, saxis, rotation, null], flags), false],
['shape polygon pyramid <pos> <block> <radius> <height> <points> <saxis> <degrees> <replacement>',
_(pos, block, radius, height, n_points, saxis, rotation, replacement) ->shape('pyramid_polygon', pos, [block, radius, height, n_points, saxis, rotation, replacement], null),
[4, 'help_cmd_brush_polygon_pyramid', 'help_cmd_brush_generic', null]],
['shape polygon pyramid <pos> <block> <radius> <height> <points> <saxis> <degrees> <replacement> f <flag>',
_(pos, block, radius, height, n_points, saxis, rotation, replacement, flags) -> shape('pyramid_polygon', pos, [block, radius, height, n_points, saxis, rotation, replacement], flags), false],
['shape star prism <pos> <block> <outer_radius> <inner_radius> <height> <points>',
_(pos, block, outer_radius, inner_radius, height, n_points) -> shape('prism_star', pos, [block, outer_radius, inner_radius, height, n_points, 'y', 0, null], null), false],
['shape star prism <pos> <block> <outer_radius> <inner_radius> <height> <points> f <flag>',
_(pos, block, outer_radius, inner_radius, height, n_points, flags) -> shape('prism_star', pos, [block, outer_radius, inner_radius, height, n_points, 'y', 0, null], flags), false],
['shape star prism <pos> <block> <outer_radius> <inner_radius> <height> <points> <axis>',
_(pos, block, outer_radius, inner_radius, height, n_points, axis) -> shape('prism_star', pos, [block, outer_radius, inner_radius, height, n_points, axis, 0, null], null), false],
['shape star prism <pos> <block> <outer_radius> <inner_radius> <height> <points> <axis> f <flag>',
_(pos, block, outer_radius, inner_radius, height, n_points, axis, flags) -> shape('prism_star', pos, [block, outer_radius, inner_radius, height, n_points, axis, 0, null], flags), false],
['shape star prism <pos> <block> <outer_radius> <inner_radius> <height> <points> <axis> <degrees>',
_(pos, block, outer_radius, inner_radius, height, n_points, axis, rotation) -> shape('prism_star', pos, [block, outer_radius, inner_radius, height, n_points, axis, rotation, null], null), false],
['shape star prism <pos> <block> <outer_radius> <inner_radius> <height> <points> <axis> <degrees> f <flag>',
_(pos, block, outer_radius, inner_radius, height, n_points, axis, rotation, flags) -> shape('prism_star', pos, [block, outer_radius, inner_radius, height, n_points, axis, rotation, null], flags), false],
['shape star prism <pos> <block> <outer_radius> <inner_radius> <height> <points> <axis> <degrees> <replacement>',
_(pos, block, outer_radius, inner_radius, height, n_points, axis, rotation, replacement) ->shape('prism_star', pos, [block, outer_radius, inner_radius, height, n_points, axis, rotation, replacement], null),
[4, 'help_cmd_brush_star', 'help_cmd_brush_generic', null]],
['shape star prism <pos> <block> <outer_radius> <inner_radius> <height> <points> <axis> <degrees> <replacement> f <flag>',
_(pos, block, outer_radius, inner_radius, height, n_points, axis, rotation, replacement, flags) -> shape('prism_star', pos, [block, outer_radius, inner_radius, height, n_points, axis, rotation, replacement], flags), false],
['shape star pyramid <pos> <block> <outer_radius> <inner_radius> <height> <points>',
_(pos, block, outer_radius, inner_radius, height, n_points) -> shape('pyramid_star', pos, [block, outer_radius, inner_radius, height, n_points, '+y', 0, null], null), false],
['shape star pyramid <pos> <block> <outer_radius> <inner_radius> <height> <points> f <flag>',
_(pos, block, outer_radius, inner_radius, height, n_points, flags) -> shape('pyramid_star', pos, [block, outer_radius, inner_radius, height, n_points, '+y', 0, null], flags), false],
['shape star pyramid <pos> <block> <outer_radius> <inner_radius> <height> <points> <saxis>',
_(pos, block, outer_radius, inner_radius, height, n_points, saxis) -> shape('pyramid_star', pos, [block, outer_radius, inner_radius, height, n_points, saxis, 0, null], null), false],
['shape star pyramid <pos> <block> <outer_radius> <inner_radius> <height> <points> <saxis> f <flag>',
_(pos, block, outer_radius, inner_radius, height, n_points, saxis, flags) -> shape('pyramid_star', pos, [block, outer_radius, inner_radius, height, n_points, saxis, 0, null], flags), false],
['shape star pyramid <pos> <block> <outer_radius> <inner_radius> <height> <points> <saxis> <degrees>',
_(pos, block, outer_radius, inner_radius, height, n_points, saxis, rotation) -> shape('pyramid_star', pos, [block, outer_radius, inner_radius, height, n_points, saxis, rotation, null], null), false],
['shape star pyramid <pos> <block> <outer_radius> <inner_radius> <height> <points> <saxis> <degrees> f <flag>',
_(pos, block, outer_radius, inner_radius, height, n_points, saxis, rotation, flags) -> shape('pyramid_star', pos, [block, outer_radius, inner_radius, height, n_points, saxis, rotation, null], flags), false],
['shape star pyramid <pos> <block> <outer_radius> <inner_radius> <height> <points> <saxis> <degrees> <replacement>',
_(pos, block, outer_radius, inner_radius, height, n_points, saxis, rotation, replacement) ->shape('pyramid_star', pos, [block, outer_radius, inner_radius, height, n_points, saxis, rotation, replacement], null),
[4, 'help_cmd_brush_star_pyramid', 'help_cmd_brush_generic', null]],
['shape star pyramid <pos> <block> <outer_radius> <inner_radius> <height> <points> <saxis> <degrees> <replacement> f <flag>',
_(pos, block, outer_radius, inner_radius, height, n_points, saxis, rotation, replacement, flags) -> shape('pyramid_star', pos, [block, outer_radius, inner_radius, height, n_points, saxis, rotation, replacement], flags), false],
// we need a better way of changing 'settings'
['settings quick_select <bool>', _(b) -> global_quick_select = b, false],
['settings max_iterations <int>', _(int) -> global_max_iter = i, false],
['structure list',['structure',null,'list',null],false],//todo help for this
['structure load <structure>',['structure','load',null],false],
['structure load <structure> f <flag>',_(s,f)->structure(s, 'load', {'flags'->f}),false],
['structure load <structure> <pos>',_(s,p)->structure(s,'load',{'pos'->p}),false],
['structure load <structure> <pos> f <flag>',_(s,p,f)->structure(s,'load',{'pos'->p,'flags'->f})],
['structure delete <structure>',['structure','delete',null],false],
['structure save <name>',['structure','save',null],false],
['structure save <name> force',['structure','save',{'force'->true}],false],
['structure save <name> entities',['structure','save',{'include_entities'->true}],false],
['structure save <name> entities force',['structure','save',{'force'->true,'include_entities'->true}],false],
['structure save <name> clipboard',['structure','save_clipboard',{'clipboard'->true}],false],
['structure save <name> clipboard force',['structure','save_clipboard',{'clipboard'->true,'force'->true}],false],
['structure copy <name>',['structure','copy',null],false],
['structure copy <name> force',['structure','copy',{'force'->true}],false],
];
// Proccess commands map for Carpet
global_commands_map = {};
for(base_commands_map,
global_commands_map:(_:0) = _:1;
);
// Proccess commands map for help
global_help_commands = [];
for(base_commands_map,
if(_:2, //Check it's not skipped (aka false)
visible_command = _:0;
suggestion = reduce(split(visible_command),if((_ == '<'),break(),_a+_),'');
if((search_pos = _:2:0) != -1, // Proccess arguments
current_pos = [-1, -1];
visible_command = reduce(map(split(visible_command),
if(_ == '<', current_pos:0 += 1; if(current_pos:0 >= search_pos, '[', _)
,_ == '>', current_pos:1 += 1; if(current_pos:1 >= search_pos, ']', _) ,_ ) ),
_a+_,'');
);
global_help_commands += ['g - '+visible_command, suggestion, _:2:1, _:2:2, _:2:3];
)
);
get_features_list() -> (
features = plop():'features';
put(features, null, , 'extend');
put(features, null, plop():'scarpet_custom', 'extend');
features;
);
__config()->{
'commands'-> global_commands_map,
'arguments'->{
'replacement'->{'type'->'blockpredicate'},
'moves'->{'type'->'int','min'->1,'suggest'->[1]},//todo decide on whether or not to add max undo limit
'degrees'->{'type'->'float','suggest'->[0,90]},
'axis'->{'type'->'term','options'->['x','y','z']},
'saxis'->{'type'->'term', 'options'->['+x', '-x', '+y', '-y', '+z', '-z']},
'sides'->{'type'->'term', 'options'->['x', 'y', 'z', 'xy', 'xz', 'yz', 'xyz']},
'wand'->{'type'->'item','suggest'->['wooden_sword','wooden_axe']},
'direction'->{'type'->'term','options'->['north','south','east','west','up','down']},
'count'->{'type'->'int','min'->1,'suggest'->[]},
'flag' -> {
'type' -> 'term',
'suggester' -> _(args) -> (
typed = if(args:'flag', args:'flag', '-');
typed_list = split(typed);
checked_list = [];
for(typed_list,
if((global_flags~_ == null || checked_list~_ != null) && (_i != 0 || _ != '-'),
return([]);
);
put(checked_list,length(checked_list),_);
);
filtered_flags = filter(global_flags,!(typed_list~_));
map(filtered_flags,typed+_);
),
},
'amount'->{'type'->'int'},
'magnitude'->{'type'->'float','suggest'->[1,2,0.5]},
'lang'->{'type'->'term','suggester'->_(ignored)->_get_lang_list()},
'page'->{'type'->'int','min'->1,'suggest'->[1,2,3]},
'name'->{'type'->'string','suggest'->[]},
'structure'->{
'type'->'term',
'suggester' -> _(args) -> map(list_files('structures','nbt'),_-'structures/'),
},
'radius'->{'type'->'int','min'->1,'suggest'->[5, 10, 30]},
'height'->{'type'->'int','min'->1,'suggest'->[5, 10, 30]},
'size'->{'type'->'int','min'->1,'suggest'->[5, 10, 30]},
'length'->{'type'->'int','min'->1,'suggest'->[5, 10, 30]},
'points'->{'type'->'int', 'min'->3 ,'suggest'->[3, 5, 7]},
'feature'->{'type'->'term','options'-> get_features_list()},
'brush'->{'type'->'term', 'suggester'->_(ignored)->keys(global_brushes)},
}
};
//player globals
global_wand = 'wooden_sword';
global_history = [];
global_undo_history = [];
global_quick_select = true;
global_clipboard = [];
global_debug_rendering = false;
global_reach = 4.5;
global_default_trace_type = 'blocks';
global_liquid_trace_type = 'liquids';
global_max_iter = 20000;
//Extra boilerplate
global_affected_blocks=[];
global_added_entities=[];
global_removed_entities=[];
//Block-selection
global_cursor = null;
global_highlighted_marker = null;
global_selection = {}; // holds ids of two official corners of the selection
global_markers = {};
global_angel_block = null;
global_items_with_actions = {global_wand -> 'wand'};
global_command_name = '/'+system_info('app_name')+' ';
_help(page) -> (
// Header
print(format(_translate('help_header_prefix'), _translate('help_header_title'), _translate('help_header_suffix')));
// Help entries are generated on top, in the commands map. Check docs there
// Hardcoded help entries (info)
// Syntax: [pre-arrow, pre-arrow command to suggest, post-arrow text, post-arrow tooltip (lang string/lambda), post-arrow action]
help_entries = [
[null, null, 'help_welcome', 'help_welcome_tooltip', null],
[if(length(global_selection) > 1,_translate('help_your_selection')), '', if(length(global_selection) > 1,
_()->_translate('help_selection_bounds', _get_marker_position(global_selection:'from'), _get_marker_position(global_selection:'to'))
,'help_make_selection'), null, '?wand '],
[_translate('help_selected_wand'), 'wand ', _()->_translate('help_selected_wand_item',title(replace(global_wand, '_', ' '))), 'help_sel_wand_tooltip', '?wand '],
[_translate('help_app_lang'), 'lang ', _()->_translate('help_app_lang_selected', _translate('language')), 'help_app_lang_tooltip', '?lang '],
[_translate('help_list_title'), 'help', null, null]
];
for(global_help_commands,
help_entries += _;
);
remaining_to_display = 8;
current_entry = ((page-1)*8);
entry_number = length(help_entries);
while(remaining_to_display != 0 && current_entry < entry_number, entry_number,
entry = help_entries:current_entry;
//Allow different desc actions
if(slice(entry:4,0,1) == '!',
description_action = '!'+global_command_name+slice(entry:4,1);
, slice(entry:4,0,1) == '?',
description_action = '?'+global_command_name+slice(entry:4,1);
);
if(entry:2 != null, arrow = 'd -> ');
//print(entry:2);
print(format(entry:0, '?'+global_command_name+entry:1, arrow,
if(type(entry:2) == 'function', call(entry:2), _translate(entry:2)),
'^'+if(type(entry:3) == 'function', call(entry:3), _translate(entry:3)),description_action)
);
current_entry += 1;
remaining_to_display += -1;
description_action = arrow = null;
);
// Footer
footer = format('');
if (page < 10, // In case we reach this, make it still be centered
footer += ' ';
);
footer += format(_translate('help_pagination_prefix'));
if (page != 1,
footer += format('d [<<]',
'^'+_translate('help_pagination_first'),
'!'+global_command_name+'help');
footer += ' ';
footer += format('d [<]',
'^'+_translate('help_pagination_prev',page-1),
'!'+global_command_name+'help '+(page-1));
,
footer += format('g [<<]');
footer += ' ';
footer += format('g [<]');
);
footer += ' ';
footer += format(_translate('help_pagination_page',page));
if ((8*page) < entry_number,
last_page = ceil((entry_number)/8);
footer += format('d [>]',
'^'+_translate('help_pagination_next',page+1),
'!'+global_command_name+'help '+(page+1));
footer += ' ';
footer += format('d [>>]',
'^'+_translate('help_pagination_last',last_page),
'!'+global_command_name+'help '+last_page);
,
footer += format('g [>]');
footer += ' ';
footer += format('g [>>]');
);
footer += format(_translate('help_pagination_suffix'));
print(footer);
);
clear_markers(... ids) ->
(
if (!ids, ids = keys(global_markers));
for (ids,
(e = entity_id(_)) && modify(e, 'remove');
delete(global_markers:_);
)
);
_create_marker(pos, block) ->
(
marker = create_marker(null, pos+0.5, block, false);
modify(marker, 'effect', 'glowing', 72000, 0, false, false);
modify(marker, 'fire', 32767);
id = marker ~ 'id';
global_markers:id = {'pos' -> pos, 'id' -> id};
id;
);
_get_marker_position(marker_id) -> global_markers:marker_id:'pos';
clear_selection() ->
(
for(values(global_selection), clear_markers(_));
global_selection = {};
);
selection_move(amount, direction) ->
(
[from, to] = _get_current_selection(player());
point1 = _get_marker_position(global_selection:'from');
point2 = _get_marker_position(global_selection:'to');
p = player();
if (p == null && direction == null, _error(player, 'move_selection_no_player_error'));
translation_vector = if(direction == null, p~'look'*amount, pos_offset([0,0,0],direction, amount));
clear_markers(global_selection:'from', global_selection:'to');
point1 = point1 + translation_vector;
point2 = point2 + translation_vector;
global_selection = {
'from' -> _create_marker(point1, 'lime_concrete'),
'to' -> _create_marker(point2, 'blue_concrete')
};
);
selection_expand(amount) ->
(
[from, to] = _get_current_selection(player());
point1 = _get_marker_position(global_selection:'from');
point2 = _get_marker_position(global_selection:'to');
for (range(3),
size = to:_-from:_+1;
c_amount = if (size >= -amount, amount, floor(size/2));
if (point1:_ > point2:_, c_amount = - c_amount);
point1:_ += -c_amount;
point2:_ += c_amount;
);
clear_markers(global_selection:'from', global_selection:'to');
global_selection = {
'from' -> _create_marker(point1, 'lime_concrete'),
'to' -> _create_marker(point2, 'blue_concrete')
};
);
__on_tick() ->
(
if (p = player(),
// put your catchall checks here
global_highlighted_marker = null;
reach = if(
(held = p~'holds':0)==global_wand, global_reach,
global_angel_block && held==global_angel_block, brush=true; global_reach, // brush=true is used so that the selection doesn't linger, need to make this better
has(global_brushes, held), brush=true; global_brush_reach
);
if(brush && length(global_selection)<2, clear_selection());
new_cursor = if ( reach && p~'gamemode'!='spectator',
// support for tracing liquids with brushes
global_trace_type = if(has(global_liquid_brush, held), global_liquid_trace_type, global_default_trace_type);
// get traced block
if (marker = _trace_marker(p, global_reach),
global_highlighted_marker = marker;
_get_marker_position(marker)
,
_get_player_look_at_block(p, reach) )
);
// delete old marker if new one isn't the same
if (global_cursor && new_cursor != global_cursor,
draw_shape('box', 0, 'from', global_cursor, 'to', global_cursor+1, 'fill', 0xffffff22);
);
// render new marker or refresh old one
if (new_cursor,
draw_shape('box', 50, 'from', new_cursor, 'to', new_cursor+1, 'fill', 0xffffff22);
);
global_cursor = new_cursor;
)
);
__on_player_swings_hand(player, hand) ->
(
if(player~'holds':0==global_wand,
if (global_quick_select,
_set_selection_point('from')
, // else
if (length(global_selection)<2,
_set_selection_point(if(!global_selection, 'from', null ));
)
)
)
);
__on_player_uses_item(player, item_tuple, hand) ->
(
if( (held = player~'holds':0)==global_wand,
if (global_quick_select,
_set_selection_point('to')
, // else
if (length(global_selection)<2,
//cancel selection
clear_selection();
,
//grab marker
marker = global_highlighted_marker;
if (marker,
selection_marker = first(global_selection, global_selection:_ == marker);
if (selection_marker,
// should be one really
clear_markers(global_selection:selection_marker);
delete(global_selection:selection_marker);
)
)
)
),
has(global_brushes, held), // TODO: make it so that if brush is a block, placing is not processed
pos = _get_player_look_at_block(player, global_brush_reach);
_brush_action(pos, held),
held==global_angel_block,
pos = _get_player_look_at_block(player, global_reach);
_place_angel_block(pos)
)
);
_trace_marker(player, distance) ->
(
precision = 0.5;
initial_position = pos(player)+[0,player~'eye_height',0];
look_vec = player ~ 'look';
marker_id = null;
while(!marker_id, distance/precision,
rnd_pos = map(initial_position, floor(_));
markers = filter(values(global_markers), _:'pos' == rnd_pos);
if (markers,
marker_id = markers:0:'id',
,
initial_position = initial_position + look_vec * precision;
if (global_debug_rendering, particle('end_rod', initial_position, 1, 0, 0));
);
);
marker_id
);
_set_selection_point(which) ->
(
if (global_highlighted_marker,
clear_markers(global_highlighted_marker);
);
which = which || if(has(global_selection:'from'), 'to', 'from');
if (global_selection:which,
clear_markers(global_selection:which)
);
marker = _create_marker(global_cursor, if(which =='from', 'lime_concrete', 'blue_concrete'));
global_highlighted_marker = marker;
global_selection:which = marker;
if (!global_rendering_selection, _render_selection_tick());
);
global_rendering_selection = false;
_render_selection_tick() ->
(
if (!global_selection,
global_rendering_selection = false;
return()
);
global_rendering_selection = true;
active = (length(global_selection) == 1);
start_marker = global_selection:'from';
start = if(
start_marker, _get_marker_position(start_marker),
global_cursor
);
end_marker = global_selection:'to';
end = if(
end_marker, _get_marker_position(end_marker),
global_cursor
);
if (start && end,
zipped = map(start, [_, end:_i]);
from = map(zipped, min(_));
to = map(zipped, max(_));
draw_shape('box', if(active, 1, 12), 'from', from, 'to', to+1, 'line', 3, 'color', if(active, 0x00ffffff, 0xAAAAAAff));
if (!end_marker, draw_shape('box', 1, 'from', end, 'to', end+1, 'line', 1, 'color', 0x0000FFFF, 'fill', 0x0000FF55 ));
if (!start_marker, draw_shape('box', 1, 'from', start, 'to', start+1, 'line', 1, 'color', 0x3fff00FF, 'fill', 0x3fff0055 ));
);
schedule(if(active, 1, 10), '_render_selection_tick');
);
_get_player_look_at_block(player, range) ->
(
block = query(player, 'trace', range, global_trace_type);
if (block,
pos(block)
,
map(pos(player)+player~'look'*range+[0, player~'eye_height', 0], floor(_));
)
);
_get_current_selection(player)->
(
if( length(global_selection) < 2,
_error(player, 'no_selection_error',player)
);
start = _get_marker_position(global_selection:'from');
end = _get_marker_position(global_selection:'to');
zipped = map(start, [_, end:_i]);
[map(zipped, min(_)), map(zipped, max(_))]
);
//Misc functions
_set_or_give_wand(wand) -> (
p = player();
if(wand,//checking if player specified a wand to be added
wand = wand:0; //because it comes as a [item, count, nbt] tuple
if( (['tools', 'combat']~item_category(wand)) != null,
new_action_item(wand, 'wand');
delete(global_items_with_actions, global_wand);
global_wand = wand;
_print(p, 'new_wand', wand);
return(),
//else, can't set as wand
_error(p, 'invalid_wand')
)
);//else, if just ran '/se wand' with no extra args
//give player wand if hand is empty
if( (held_item_tuple = p~'holds') == null,
slot = inventory_set(p, p~'selected_slot', 1, global_wand);
return()
);
//else, set current held item as wand, if valid
held_item = held_item_tuple:0;
if( (['tools', 'combat']~item_category(held_item)) != null,
new_action_item(held_item, 'wand');
delete(global_items_with_actions, global_wand);
global_wand = held_item;
_print(p, 'new_wand', held_item),
//else, can't set as wand
_error(p, 'invalid_wand')
)
);
global_flags = ['w','a','e','h','u','b','p','d','s','g','l'];
//FLAGS:
//w waterlog block if previous block was water(logged) too
//a don't paste air
//e consider entities as well
//h make shapes hollow
//u set blocks without updates
//b set biome
//p only replace air
//d "dry" out the pasted structure (remove water and waterlogged)
//s keep block states of replaced block, if new block matches
//g when replacing air or water, some greenery gets repalced too
//l when used in a brush, the brush will trace for liquids as well as blocks
_parse_flags(flags) ->(
if(!flags, return({}));
if(type(flags)=='map',return(flags));
symbols = split(flags);
if(symbols:0 != '-', return({}));
flag_set = {};
for(split(flags),
if(_~'[A-Z,a-z]',flag_set+=_);
);
flag_set;
);
volume_blocks(pos1,pos2)->(
retlist=[];
volume(pos1,pos2,retlist+=_);
retlist
);
//Config Parser
_parse_config(config) -> (
if(type(config) != 'list', config = [config]);
ret = {};
for(config,
if(_ ~ '^\\w+ ?= *.+$' != null,
key = _ ~ '^\\w+(?= ?= *.+)';
value = _ ~ str('(?<=%s ?= ?) *([^ ].*)',key);
ret:key = value
)
);
ret
);
//Translations
global_lang_id='en_us';//default en_us (and fill it below)
global_lang_keys = global_default_lang = {
'language_code' -> 'en_us',
'language' -> 'English',
'help_header_prefix' -> 'c ----------------- [ ',
'help_header_title' -> 'd ScarpetEdit Help',
'help_header_suffix' -> 'c ] -----------------',
'help_welcome' -> 'c Welcome to the ScarpetEdit app\'s help!',
'help_welcome_tooltip' -> 'y Hooray!',
'help_your_selection' -> 'c Your selection',
'help_selection_bounds' -> 'l From %s to %s',
'help_make_selection' -> 'c Use your wand to select with a start and final position',
'help_selected_wand' -> 'c Selected wand', //Could probably be used in more places
'help_selected_wand_item' -> 'l %s',
'help_sel_wand_tooltip' -> 'g Use the wand command to change',
'help_app_lang' -> 'c App Language ', //Could probably be used in more places, todo decide whether to hardcode this
'help_app_lang_selected' -> 'l %s',
'help_app_lang_tooltip' -> 'g Use the lang command to change it',
'help_list_title' -> 'y Command list (without prefix):',
'help_pagination_prefix' -> 'c --------------- ',
'help_pagination_page' -> 'y Page %d ',
'help_pagination_suffix' -> 'c ---------------',
'help_pagination_first' -> 'g Go to first page',
'help_pagination_prev' -> 'g Go to previous page (%d)',
'help_pagination_next' -> 'g Go to next page (%d)',
'help_pagination_last' -> 'g Go to last page (%d)',
'help_cmd_help' -> 'l Shows this help menu, or a specified page',
'help_cmd_lang' -> 'l Changes current app\'s language to [lang]',
'help_cmd_lang_tooltip'-> 'g Available languages are %s',
'help_cmd_set' -> 'l Set selection to block, filterable',
'help_cmd_set_tooltip' -> 'g You can use a tag in the replacement argument',
'help_cmd_undo' -> 'l Undoes last n moves, one by default',
'help_cmd_undo_all' -> 'l Undoes the entire action history',
'help_cmd_undo_history' -> 'l Shows the history of undone actions',
'help_cmd_redo' -> 'l Redoes last n undoes, one by default',
'help_cmd_redo_tooltip' -> 'g Also shows up in undo history',
'help_cmd_redo_all' -> 'l Redoes the entire undo history',
'help_cmd_wand' -> 'l Sets held item as wand or gives it if hand is empty',
'help_cmd_wand_2' -> 'l Changes the current wand item',
'help_cmd_rotate' -> 'l Rotates [deg] about [pos]',
'help_cmd_rotate_tooltip' -> 'g Axis must be x, y or z, defaults to y',
'help_cmd_stack' -> 'l Stacks selection n times in dir',
'help_cmd_stack_tooltip' -> 'g If not provided, direction is player\'s view direction by default',
'help_cmd_expand' -> 'l Expands sel [magn] from pos', //This is not understandable
'help_cmd_expand_tooltip' -> 'g Expands the selection [magnitude] from [pos]',
'help_cmd_move' -> 'l Moves selection to <pos>',
'help_cmd_hollow' -> 'l Hollows out all connex shapes inside selection',
'help_cmd_hollow_tooltip' -> 'g Specify [block] to hollow out only shapes of that material',
'help_cmd_outline' -> 'l Outline all blocks within selection with <block>',
'help_cmd_outline_force' -> 'l Replaces non air blocks too',
'help_cmd_outline_tooltip' -> 'g Specify [outline_block] to only outline shapes of that material',
'help_cmd_clear_clipboard' -> 'l Clears current clipboard',
'help_cmd_copy' -> 'l Copy current selection to clipboard',
'help_cmd_copy_tooldtip' -> 'g Uses [pos] or player position as origin for the copied structure',
'help_cmd_paste' -> 'l Paste clipboard',
'help_cmd_drain' -> 'l Drains liquid you are standing on',
'help_cmd_drain_tooltip' -> 'g Acts in a radius or withing the selection',
'help_cmd_flood' -> 'l Perferoms a 3D flood fill out of [block]',
'help_cmd_flood_tooltip' -> 'g Use [axis] to make a flat fill',
'help_cmd_walls' -> 'l Set walls of the selection',
'help_cmd_walls_tooltip' -> 'l Use [sides] to choose which sides to generate',
'help_cmd_outline' -> 'l Outlines the selection with <block>',
'help_cmd_up' -> 'l Teleport up specified ammount of block',
'help_cmd_up_tooltip' -> 'g Generate a glass block under you if there was nothing there',
'help_cmd_brush_clear' -> 'l Unregisters current item as brush',
'help_cmd_brush_list' -> 'l Lists all currently regiestered brushes and their actions',
'help_cmd_brush_info' -> 'l Gives detailed info of currently held brush',
'help_cmd_brush_generic' -> 'l Hold item to turn into brush',
'help_cmd_brush_hollow' -> 'l Register brush to hollow out shapes',
'help_cmd_brush_outline' -> 'l Register brush to outline shapes',
'help_cmd_brush_outline_force'-> 'l Register brush to outline replacing non air too',
'help_cmd_brush_cube' -> 'l Register brush to create a cube of side length [size] out of [block]',
'help_cmd_brush_cuboid' -> 'l Register brush to create a cuboid of dimensions [x] [y] and [z] out of [block]',
'help_cmd_brush_diamond' -> 'l Register brush to create a diamond with diagonal [size] out of [block]',
'help_cmd_brush_sphere' -> 'l Register brush to create a sphere of radius [size] out of [block]',
'help_cmd_brush_ellipsoid' -> 'l Register brush to create a ellipsoid with radii [x_radius], [y_radius] and [z_radius] out of [block]',