Display Text, Table Cell Value?

Hello GS community,
I have a table with 1 column and 10 rows. They are booleans all set to false. I have a button that when touch is pressed change column 1, row 1 to false. I want to display if its current state is true or false to make sure everything is working correctly. I select "Display Text" select tableCellValue and insert the table name, row, & col that I want it to display. When previewing it all it says is invalid expression and doesn't display if it is true or false. What am I doing wrong here and how to fix this? Thank you in advance!

Comments

  • KevinCrossKevinCross London, UKMember Posts: 1,894
    I don't think you can display Boolean values. It's not a table thing.
  • VolontaArtsVolontaArts Member Posts: 510
    edited September 2013
    I don't think you can display Boolean values. It's not a table thing.
    @kevincross
    maybe if he made an attribute thats equal to the boolean value???

    i believe booleans can also be written as 0 and 1

    0=false

    and

    1=True
  • KillerPenguinStudiosKillerPenguinStudios Member Posts: 1,291
    I don't think you can display Boolean values. It's not a table thing.
    You can display booleans. If you just create a boolean attribute and tell it to display that boolean, It will show if it is true or false.

  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited September 2013

    @killerpenguins

    Strange you couldn't get it to work; one workaround is to put the table result into a text boolean and then display that:

    Rule: When touch is pressed
    Change Attribute TValue to tableCellValue(YourTable, 1,1)

    Display Text: scene.TValue

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    maybe table booleans are treated differently than attribute booleans?
  • KevinCrossKevinCross London, UKMember Posts: 1,894
    I remember now, you can't show booleans when there's text in the expression left or right of it I.e.

    "value "..game.boolean variable.

    I sure that gave me an error last time.

    If not then I stand corrected, it was a while back when I noticed it.
  • KillerPenguinStudiosKillerPenguinStudios Member Posts: 1,291
    edited September 2013
    @KevinCross @gyroscope & @jonmulcahy Thank you for your responses. I figured it out!!! In the "Display Text" behavior, in the expression editor you have to select "tableCellValue" which I was doing. Where it says table, I was putting the tables name which WON'T work. You have to select "GAME" in the drop down, then scroll down to the table you wan't then select it. Then put in the row and column you wish then it will display it. Thanks again and now you all know it can be done and how! Thanks!
  • bjandthekatzbjandthekatz Orlando, FlMember Posts: 1,375
    Glad you fixed your problem. Tables are grouped into the attributes section when searching for them. It is always a good measure to prefix them Tb- so you can tell the difference from a table for scores and an attribute for scores.
Sign In or Register to comment.