Question about display Text
steve86
Member Posts: 806
Hi guys
Quick question I want to display the time it took the player to complete the level. I have in a fix variable the time it took the player to complete the level, and I'm using the display text behavior to let the user know the time.
Im trying to put this in the display text area and when I run it is says invalid expresion:
"Total Time"..game.totalTime.."Seconds".
Any idea whats wrong with that expression?
Quick question I want to display the time it took the player to complete the level. I have in a fix variable the time it took the player to complete the level, and I'm using the display text behavior to let the user know the time.
Im trying to put this in the display text area and when I run it is says invalid expresion:
"Total Time"..game.totalTime.."Seconds".
Any idea whats wrong with that expression?
Comments
The question is how to display text and a constraint value using a single display text behavior.
for instance in Java you could use "Total Time:"+totaltimevariable"+"Seconds". Im asking what is the command in game salad that would so the same. Because if I put this in the text area of the display text behavior it will say invalid expression.
"Total Time"..game.totalTime.."Seconds"
would be correct.
Yes I did and i got it to display the following "Totaltime9.41312Seconds" Without spaces between the text and the attribute.
For some reason when I select the attribute into the display text area it wont let me put spaces between words anymore, and also it adds a lot of decimal numbers to the attributed.
I only want to display two decimals and if I display just the attribute it displays two decimals just fine, but when I add text and attributes to the display text area its when it gets weird by not letting me put spaces between words and it adds a lot of decimals.
any idea what is going on?
thanks a lot in advance