Having an issue with effectively using tables to display a certain row

WeswogWeswog Member Posts: 1,171
edited July 2013 in Working with GS (Mac)
So basically I want to be able to display text from a an entire row when the row is randomly selected the row has 2 columns in it, so whenever I want it to that whenever I press a button it randomly selects an entire row and displays the 2 columns separately in different parts of the screen. Not sure if this is possible or not, but any help would be greatly appreciated.

Thanks, Weswog.

Comments

  • zoopezoope Member Posts: 210
    edited July 2013
    @Weswog Not sure if this is what you're looking for ?

    I tried creating a table called test with two columns, and can display values from the first and second column together like this

    Using Display Text:

    tableCellValue( game.test ,1,1).. tableCellValue( game.test ,1,2)
  • WeswogWeswog Member Posts: 1,171
    Yea but I need them to be random for the rows and the rows have to matchup with both columns, I mean i can manually do each table cell but I am pretty sure there is a more efficient way.
  • zoopezoope Member Posts: 210
    How about this

    Create an integer rand

    change attribute to random(1,5)

    tableCellValue( game.test , self.rand ,1).. tableCellValue( game.test , self.rand ,2)
  • WeswogWeswog Member Posts: 1,171
    Ahh... true, didn't think of that haha. Thanks!
Sign In or Register to comment.