CharCodeAt
Last updated
Last updated
The CharCodeAt Node outputs the ASCII code of a character at a given index in a String. It takes as inputs a String and the index of the character whose code is to be obtained, and it ouputs the ASCII code of said character.
The characters' indices in the String start from zero.
If the index given is greater than the String length, the output is -1
.
Scope: Project, Scene, Function, Prefab.
Attribute | Type | Description |
---|---|---|
| String | The String from which the characters' codes are to be obtained, if none is given in the Input Socket. |
| Int | The index of the character whose ASCII code is to be obtained, if none is given in the Input Socket. |
Input | Type | Description |
---|---|---|
Pulse Input (►) | Pulse | A standard Input Pulse, to trigger the execution of the Node. |
| String | The String from which the characters' codes are to be obtained. |
| Int | The index of the character whose ASCII code is to be obtained. |
Output | Type | Description |
---|---|---|
Pulse Output (►) | Pulse | A standard Output Pulse, to move onto the next Node along the Logic Branch, once this Node has finished its execution. |
| Int | The ASCII code of the character at position |
ASCII on Wikipedia.
HTML ASCII Reference on W3Schools.