ord
Returns the numeric value of the given character
[...] = optional ... = your value
[var $... = ]call ord $val=...
Example code
Show in textarea<!--parser:xtscript-->
var $input =X
var $output = call ord $val=$input
print input = $input<br />
print output = $output
<!--/parser:xtscript-->
Show in textarea Example output