Skip to content

Commit 6d4582e

Browse files
authored
Nicer description for EffSort. (#7058)
1 parent 45ce386 commit 6d4582e

File tree

1 file changed

+7
-22
lines changed

1 file changed

+7
-22
lines changed

src/main/java/ch/njol/skript/effects/EffSort.java

Lines changed: 7 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,3 @@
1-
/**
2-
* This file is part of Skript.
3-
*
4-
* Skript is free software: you can redistribute it and/or modify
5-
* it under the terms of the GNU General Public License as published by
6-
* the Free Software Foundation, either version 3 of the License, or
7-
* (at your option) any later version.
8-
*
9-
* Skript is distributed in the hope that it will be useful,
10-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12-
* GNU General Public License for more details.
13-
*
14-
* You should have received a copy of the GNU General Public License
15-
* along with Skript. If not, see <http://www.gnu.org/licenses/>.
16-
*
17-
* Copyright Peter Güttinger, SkriptLang team and contributors
18-
*/
191
package ch.njol.skript.effects;
202

213
import ch.njol.skript.Skript;
@@ -48,10 +30,13 @@
4830
import java.util.Set;
4931

5032
@Name("Sort")
51-
@Description({
52-
"Sorts a list variable using either the natural ordering of the contents or the results of the given expression.",
53-
"Be warned, this will overwrite the indices of the list variable."
54-
})
33+
@Description("""
34+
Sorts a list variable using either the natural ordering of the contents or the results of the given expression.
35+
Be warned, this will overwrite the indices of the list variable.
36+
37+
When using the full <code>sort %~objects% (by|based on) &lt;expression&gt;</code> pattern,
38+
the input expression can be used to refer to the current item being sorted.
39+
(See input expression for more information.)""")
5540
@Examples({
5641
"set {_words::*} to \"pineapple\", \"banana\", \"yoghurt\", and \"apple\"",
5742
"sort {_words::*} # alphabetical sort",

0 commit comments

Comments
 (0)