How to put K instead of 1000
Zeus Company
Member Posts: 12
Why do Gamesalad says that this is an invalid expression?
tableCellValue( game.money /1000,1,1).."K"
Thanks
Best Answer
-
Armelline Posts: 5,369
I was actually wrong.
Needs to be:
(tableCellValue(game.money,1,1)/1000).."K"
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
Answers
tableCellValue( game.money is the money you currently have, by the way
game.Money is the name of the table, so you can't divide that by 1000. If the amount you want to divide is in cell 1,1, you need to do:
tableCellValue(game.money,1,1)/1000.."K"
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
Is your table name "money /1000"?
I assume it´s not called that, and that´s the problem. You can only have the selected table in the 'table' part of TableCellValue.
Example: If your table is called Money, it needs to be TableCellValue((game.Money),1,1)
Mental Donkey Games
Website - Facebook - Twitter
It still says Invalid expression
Please post a screen shot of the rule.
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
Well it's picked from Game>Money at the Display Text expression editor
Double-check your parentheses and commas. What @Armelline is correct:
Also make sure that game.money is in fact a table (in the Tables tab of the Home screen) and that you're selecting game.money from the drop-down Attribute Browser and not just typing it in.
If that doesn't work, upload a screenshot to a file-sharing site and then embed/post the link here.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Is game.Money definitely a table?
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
i1285.photobucket.com/albums/a594/Mariecolo/Sin_t_tulo__zpsa4hf1z74.png
where "Dinero Actual" is money. I changed it so you can understand it.
Can we also see a screen shot of the table?
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
That's the only column i have
do this:
(tableCellValue(game.money,1,1)/1000).."K"
where game.money is a table name, and (tableCellValue(game.money,1,1) actually returns an numeric value.
can you post a screenshot of your table setup, as well as what happens when you display text (tableCellValue(game.money,1,1)
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
YES! Thank you very much!