Skip to content
Permalink
Browse files
Fix missing newlines in register_command example
  • Loading branch information
Pieter12345 committed Dec 3, 2020
1 parent a96d3af commit bd2bfd0
Showing 1 changed file with 3 additions and 3 deletions.
@@ -330,8 +330,8 @@ public ExampleScript[] examples() throws ConfigCompileException {
+ "\t'noPermMsg': 'You do not have permission to give hugs to players (Sorry :o).',\n"
+ "\t'tabcompleter':\n"
+ "\t\tclosure(@alias, @sender, @args) {\n"
+ "\t\t\t// This replicates the default tabcompleter for registered commands."
+ "\t\t\t// If no tabcompleter is set, this behavior is used."
+ "\t\t\t// This replicates the default tabcompleter for registered commands.\n"
+ "\t\t\t// If no tabcompleter is set, this behavior is used.\n"
+ "\t\t\t@input = @args[-1];\n"
+ "\t\t\treturn(array_filter(all_players(), closure(@key, @value) {\n"
+ "\t\t\t\treturn(length(@input) <= length(@value)\n"
@@ -342,7 +342,7 @@ public ExampleScript[] examples() throws ConfigCompileException {
+ "\t'executor':\n"
+ "\t\tclosure(@alias, @sender, @args) {\n"
+ "\t\t\tif(array_size(@args) == 1) {\n"
+ "\t\t\t\t@target = @args[0];"
+ "\t\t\t\t@target = @args[0];\n"
+ "\t\t\t\tif(ponline(@target)) {\n"
+ "\t\t\t\t\tbroadcast(colorize('&4'.@sender.' &6hugs &4'.@target));\n"
+ "\t\t\t\t} else {\n"

0 comments on commit bd2bfd0

Please sign in to comment.