Methods on String objects

Gosu provides various methods to manipulate strings and characters. For example:

var str = "bat"
str = str.replace( "b", "c" )
print(str)

This code prints:

cat

Type "new String()" into the Gosu Scratchpad and then press period (.) to see the full list of methods.