Simple (?) Parser

Blitz3D Forums/Blitz3D Beginners Area/Simple (?) Parser

Hello,

I am trying to create a function that will look through a string and return values based on the characters present in the string.

For example, I have the following name stored in playername$.

 playername$ = "Mouse" 


Basically, I want the code to look through each letter, and return a number based on the letter. If letter = M, return "2"; if letter = "o" return "6"; if letter = "u" then return "12" and so forth. Eventually I want it to look like this:

Mouse
261245

I am pretty sure it is just a matter of incorporating the Len command with a few others, but I am not really sure where to begin.

Any suggestions are much appreciated. Thanks.