Playmaker Forum

Playmaker Help & Tips => Playmaker Help => Topic started by: escpodgames on February 13, 2013, 05:28:39 PM

Title: ArrayMaker sort alphabetically by name[SOLVED]
Post by: escpodgames on February 13, 2013, 05:28:39 PM
Hi,

I need to sort an array list alphabetically, the Array list sort action only works with strings from what I can tell.

On game startup I add a bunch of positions to an array, these positions are taken from existing game object. Everything works as expected except the order of the positions eg,
position_03
position_01
position_04
position_02

I did found an old thread - http://hutonggames.com/playmakerforum/index.php?topic=2381.0

Any word on this jean?
Title: Re: ArrayMaker sort alphabetically by name
Post by: jeanfabre on February 15, 2013, 12:32:48 AM
Hi,

 I am not sure what to do cause I can't seem to find a working sample on the net to give me some hints as how to do it.

 I would suggest you save the gameObjects names and then sort them. Would that not work?

bye,

 Jean
Title: Re: ArrayMaker sort alphabetically by name
Post by: escpodgames on February 17, 2013, 07:23:25 PM
I think ill just manually add the positions to the array, not ideal but at least it will work.

Thanks anyways Jean :)
Title: Re: ArrayMaker sort alphabetically by name
Post by: jeanfabre on February 17, 2013, 10:46:35 PM
Hi,

 is it something you don't have to do at run time?

bye,

 Jean
Title: Re: ArrayMaker sort alphabetically by name
Post by: escpodgames on February 17, 2013, 11:23:08 PM
It doesn't have to be done at runtime but would make it a lot easier as each level would have a different amount of items in the array.

Title: Re: ArrayMaker sort alphabetically by name
Post by: jeanfabre on July 24, 2018, 01:09:25 AM
Hi,

 ok, the original thread now has a working action for this:

http://hutonggames.com/playmakerforum/index.php?topic=2381.msg10563#msg10563

 Bye,

 Jean