Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: SanosVerd on February 18, 2018, 01:47:37 PM

Title: Adding prefabs to favourite list.
Post by: SanosVerd on February 18, 2018, 01:47:37 PM
G’day to you all. I need advise or just point out in to right direction. Well I am working on informational app with different places and description and trying to implement list of favorites. Player/user would have a plus button where he can add specific game object in to that favourite list. He can check his favourite list by pressing an icon in the corner, panel would appear with scrolling function and players added favourite would be in there, one after another, player will be able to remove that game object at any time (while panel with favourite GO is open).. Now I can’t figure out what actions would be most suitable for this functionality. I was thinking about adding a prefab or activating a game object (when player press plus button) but how do I position in in to horizontally scrollable list where one GO would be located after another.

Any tips or ideas?

Thank you
Title: Re: Adding prefabs to favourite list.
Post by: jeanfabre on February 19, 2018, 12:19:50 AM

you position items in lists by indexing them by their child index.

use the action SetTransformSiblingIndex from the ecosystem

if you search for sibling, you'll also find few more, liekt set as first sibling or set as last sibling.