utfLen | Multi Theft Auto: Wiki Skip to content

utfLen

Client-side
Server-side
Shared

This page is incomplete! Help wanted!

Please finish this page using the corresponding Old Wiki article.
Go to Contribution guidelines for more information.


The function gets the real length of a string, in characters.

Syntax

utfLen ( )

Code Examples

server

This example adds a commandrussian_text_lengthwhich prints out a length russian text.

addCommandHandler( 'russian_text_length',
function( )
outputChatBox( string.format( 'Russian text length is: %d', utfLen( 'Текст' ) ) )
end
)