Skip to reading
GDScript Programming & Godot

StringLength()

Edition 0.86.4.1 HF1

0.86.4.1 Hotfix 1 edition. Earlier lessons and screenshots retain their original version context; revised references and supplements describe the newer behavior.

Download PDFView PDF page
On this page
Code example
StringLength(value: Variant) -> int

Convert the value to text and count its characters.

Returns: Integer.

Code example
StringLength("Archive")

This is not an array-size helper. Use array.size or native len for containers.

StringSplit()#

Code example
StringSplit(value: Variant, delimiter: String = " ", allow_empty: bool = true) ->
PackedStringArray

Convert to text and split at a delimiter.

Returns: PackedStringArray.

Code example
StringSplit("key,note", ",", false)

Split has a similar purpose but returns Array[String].

Lower()#

Code example
Lower(value: Variant) -> String

Convert to lowercase text.

Returns: String.

Code example
Lower("OPEN")

Upper()#

Code example
Upper(value: Variant) -> String

Convert to uppercase text.

Returns: String.

Code example
Upper("archive")
Page 81 of 378Permalink
Go to page