Skip to content

Commit 03e8507

Browse files
committed
Split some excessive short function descriptions
1 parent 8f7b8f5 commit 03e8507

File tree

5 files changed

+13
-14
lines changed

5 files changed

+13
-14
lines changed

src/main/java/com/laytonsmith/core/functions/Enchantments.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ public String docs() {
156156
+ " enchantment array may be given. If slot is null, the currently selected slot is used."
157157
+ " If an enchantment cannot be applied to the specified item, an EnchantmentException is thrown."
158158
+ " The enchantment array must have the enchantment as keys and levels as the values."
159-
+ " (eg. array('unbreaking': 1)) The level parameter can be a number or a roman numeral."
159+
+ " (eg. array('unbreaking': 1)) The level parameter can be a number or a roman numeral. ---- "
160160
+ " The available enchantments are: " + StringUtils.Join(MCEnchantment.values(), ", ", ", and ")
161161
+ ".";
162162
}

src/main/java/com/laytonsmith/core/functions/EntityManagement.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -983,7 +983,7 @@ private List<String> prepareTypes(Target t, List<String> types) {
983983
public String docs() {
984984
return "array {locationArray, distance, [type] | locationArray, distance, [arrayTypes]} Returns an array of"
985985
+ " all entities within the given distance from the location. Set type argument to filter entities"
986-
+ " to a specific entity type. You can pass an array of types. Valid types (case doesn't matter): "
986+
+ " to a specific entity type. You can pass an array of types. ---- Valid types: "
987987
+ StringUtils.Join(MCEntityType.types(), ", ", ", or ", " or ");
988988
}
989989

@@ -1128,7 +1128,7 @@ public String docs() {
11281128
+ " the death effect makes the mob invisible to players and"
11291129
+ " immune to melee attacks. When used on players, they are"
11301130
+ " shown the respawn menu, but because they are not actually"
1131-
+ " dead, they can only log out. Possible effects are: "
1131+
+ " dead, they can only log out. ---- Possible effects are: "
11321132
+ StringUtils.Join(MCEntityEffect.values(), ", ", ", or ", " or ");
11331133
}
11341134

src/main/java/com/laytonsmith/core/functions/Exceptions.java

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -300,9 +300,10 @@ public String docs() {
300300
exceptions += StringUtils.Join(ee, ", ", ", and ");
301301

302302
return "nothing {exceptionType, msg, [causedBy] | exception} This function causes an exception to be thrown."
303-
+ " The exceptionType may be any valid exception type."
304-
+ "\n\nThe core exception types are: " + exceptions
305-
+ "\n\nThere may be other exception types as well, refer to the documentation of any extensions you have installed.";
303+
+ " The exceptionType may be any valid exception type. ---- "
304+
+ "The core exception types are: " + exceptions
305+
+ "\n\nThere may be other exception types as well,"
306+
+ " refer to the documentation of any extensions you have installed.";
306307
}
307308

308309
@Override
@@ -512,9 +513,6 @@ public Mixed execs(Target t, Environment env, Script parent, ParseTree... nodes)
512513
// We need to define the exception in the variable table
513514
IVariableList varList = env.getEnv(GlobalEnv.class).GetVarList();
514515
IVariable var = (IVariable) assign.getChildAt(1).getData();
515-
// This should eventually be changed to be of the appropriate type. Unfortunately, that will
516-
// require reworking basically everything. We need all functions to accept Mixed, instead of Mixed.
517-
// This will have to do in the meantime.
518516
varList.set(new IVariable(CArray.TYPE, var.getVariableName(), e.getExceptionObject(), t));
519517
parent.eval(nodes[i + 1], env);
520518
varList.remove(var.getVariableName());

src/main/java/com/laytonsmith/core/functions/Minecraft.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -426,9 +426,10 @@ public Integer[] numArgs() {
426426
@Override
427427
public String docs() {
428428
return "void {locationArray, effect, [radius]} Plays the specified effect at the given location"
429-
+ " for all players within the radius (or 64 by default). The effect can be one of the following: "
430-
+ StringUtils.Join(MCEffect.values(), ", ", ", or ", " or ")
431-
+ ". ---- Some effects may require an applicable block at the specified location."
429+
+ " for all players within the radius (or 64 by default)."
430+
+ " ---- The effect can be one of the following: "
431+
+ StringUtils.Join(MCEffect.values(), ", ", ", or ", " or ") + "."
432+
+ " Some effects may require an applicable block at the specified location."
432433
+ " Additional data can be supplied with the syntax EFFECT:DATA.<br>"
433434
+ "<br>STEP_SOUND and PARTICLES_AND_SOUND_BRUSH_BLOCK_COMPLETE (Paper) take a block material name."
434435
+ "<br>RECORD_PLAY takes a record material name."

src/main/java/com/laytonsmith/core/functions/World.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1795,7 +1795,7 @@ public Boolean runAsync() {
17951795
public String docs() {
17961796
return "mixed {world, [gameRule]} Returns an associative array containing the values of all existing"
17971797
+ " gamerules for the given world. If the gameRule parameter is specified, the function only"
1798-
+ " returns that one value instead of an array."
1798+
+ " returns that one value instead of an array. ---- "
17991799
+ " The gameRule can be " + StringUtils.Join(MCGameRule.getGameRules(), ", ", ", or ", " or ") + ".";
18001800
}
18011801

@@ -1869,7 +1869,7 @@ public Boolean runAsync() {
18691869
@Override
18701870
public String docs() {
18711871
return "boolean {[world], gameRule, value} Sets the value of the gamerule for the specified world."
1872-
+ " If world is not given the value is set for all worlds. Returns true if successful."
1872+
+ " If world is not given the value is set for all worlds. Returns true if successful. ---- "
18731873
+ " The gameRule can be " + StringUtils.Join(MCGameRule.getGameRules(), ", ", ", or ", " or ") + ".";
18741874
}
18751875

0 commit comments

Comments
 (0)