Extra split effect option
3meraldK opened this issue ยท 0 comments
Suggestion
As of now, Skript's split effect splits a text with limit set to -1 as shown here. Add an option to discard trailing empty lines, by simply changing the limit from -1 to 0.
Proposed syntax would look like: split %string% (at|using|by) [[the] delimiter] %string% [case:with case sensitivity] [with empty lines (discarded|removed|deleted)]
Why?
Sometimes it may be confusing for a user when they split a word at empty delimiter (""). The example word "test" split at "" spits out an array ["t", "e", "s", "t", ""]. When checking for length, a user expects it to be 4, while it is 5.
Other
No response
Agreement
- I have read the guidelines above and affirm I am following them with this suggestion.