Converts a variable to a String. There are different versions of BuildString for the various types of variables like integer, float, boolean and vector. It also receives as parameters other strings to be used in the formation of the final string.Input
- Append To: String that will be used at the beginning of the final string.
- Prefix: String that will be used after the "Append To" in the final string.
- In type: Variable that will be converted to string and inserted after "Prefix".
- Suffix: String that will be inserted after the value of the variable.
- Return Value: String resulting from joining the input parameters: AppendTo + Prefix + Intype + Suffix.
In the example below, the "BuildScoreBoard" event prepares a string called "ScoreBoardString" that contains the name and score of each player in a match to be displayed on a scoreboard. This scoreboard is represented by a "Text Render" component. The "ForEachLoop" action is used to traverse the Array that holds the players' data. After completing the "ForEachLoop", the "Text Render" component defines its contents using the value of the "ScoreBoardString" variable.
|Click to enlarge|
The "BuildString" action creates a scoreboard line. The "Text Render" component interprets the <br> tag as line break.
Each line created is appended to the content of the "ScoreBoardString" variable using the "Append" action. These actions are repeated for each player.