public char getChar(int strIndex) {
            if ( index + strIndex >= string.length () )
                return '\0';
            else
                return string.charAt ( index + strIndex );
        }
Only works with non-negative numbers
main/src/main/java/cgeo/geocaching/wherigo/kahlua/stdlib/StringLib.java