Text Dialog and lists
Jeffm2
Member, PRO Posts: 148
Hey all,
I have dialog text being pulled from a table. Is there anyway to do a bulleted list from the table to be included in the dialog? So when the character makes reference to the list of things, its not all on one line or they don't have to keep hitting "next"?
Comments
Use line breaks. See this thread. http://forums.gamesalad.com/discussion/81238/an-illustrated-guide-to-the-display-text-behaviour/p1
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
How is your table data formatted? Is it one list item per table cell like this:
apples
oranges
lemons
?
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Tatiang, It is one statement per row. I am using the GS One dialog mechanics. SO my character is talking and makes reference to a list of things (example, apple, oranges, ect) and i would like for them to appear in that statement as a list like what you have typed. Example: Today you must go to the store. Some things you could get are
•Apples
•Oranges
and this would be all one statement.
Use this expression:
"Today you must go to the store. Some things you could get are".."\n".."•"..tableCellValue(tableName,1,1).."\n".."•"..tableCellValue(tableName,2,1)
You can also simplify the expression to:
"Today you must go to the store. Some things you could get are\n•"..tableCellValue(tableName,1,1).."\n•"..tableCellValue(tableName,2,1)
If you have a bunch of cells to list, you can use the tableMergeValues function to create a shorter expression (use "\n•" as the separator). Just a warning that that function is a bit tricky to get right!
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User