Game Development Community

CharAt()?

by Jeremy Tilton · in Torque Game Builder · 03/24/2005 (6:17 pm) · 2 replies

Is there a charAt(%string, %int) or similar in TorqueScript?

#1
03/24/2005 (6:24 pm)
Found this:

getSubStr(%string, %index, %index+1);

Anything better?
#2
03/24/2005 (6:29 pm)
Thats it... though remember you can make your own sub functions...

function charAt(%string, %int)
{
     return getSubStr(%string, %int, 1);
}