How to make an expanding/collapsing "row" sort of like accordion

Hello all,

I'm having difficulty figuring out the best way to do this, so I thought I'd put it out there and see if anyone had any suggestions. I need to make a table (like an HTML table, not GS data table) with rows where you click on one and it expands to a certain "opened" height. Then when clicked again, it closes back to it's original height. There will be something like 100 rows like this in the table. It's sort of like an accordion menu, but where you can have any number of rows "opened" or closed at any time.

Now I realize this sort of thing is NOT optimal for gamesalad -- but the thing is, the rest of the game is very optimal for GS. So I'm trying to figure out the best way to do this.

So far, I've been trying to use a GS table to basically keep track of the Y position and opened heights of each row, then constraining each row actor's Y value to their row in the GS table. It works, sort of, but performance is an issue even with only a few rows.

I thought maybe using a collision/physics thing might enable any row to "push" the rest of the rows down smoothly, then maybe use gravity or something to pull them back up when they are closed. But the problem I'm having is that simply "growing" the row Y size when clicked doesn't trigger a collision right.. or so it seems. But maybe this isn't really the road I should be exploring.

Any ideas on how I could make this concept happen? TIA!

Comments

  • Braydon_SFXBraydon_SFX Member, Sous Chef, Bowlboy Sidekick Posts: 9,273
    We have a accordion menu system over on GSHelper.com. Check it out if you want.
  • KevinCrossKevinCross London, UKMember Posts: 1,894
    @Braydon_SFX can you link it please? Searching for "accordion" on the site doesn't return any results and I went through all of the templates, and most of the tutorials looking for it.
  • 95orange95orange PRO Posts: 18
    I couldn't find one on GSHelper either. I did see this one by Jason Nester on the Deep Blue Apps site: http://www.deepblueapps.com/jayleetemplates/

    But it's not free, and it doesn't quite look like what I need. Perhaps it can be expanded/scaled to do what I need, but it really depends on how it's implemented. Just hoping to exhaust some other ideas before buying a template that may or may not help.
Sign In or Register to comment.