-
What do you want to achieve?
I need a way to sort my tables (that are parts) -
What is the issue? Include screenshots / videos if possible!
Table that I get in output:
[1] = Node18,
[2] = Node21,
[3] = Node20,
[4] = Node19,
[5] = Node1,
[6] = Node2,
[7] = Node3,
[8] = Node4,
[9] = Node5,
[10] = Node6,
[11] = Node7,
[12] = Node8,
[13] = Node9,
[14] = Node10,
[15] = Node11,
[16] = Node12,
[17] = Node13,
[18] = Node14,
[19] = Node15,
[20] = Node16,
[21] = Node17,
[22] = Node22,
[23] = Node23,
[24] = Node24,
[25] = Node25
} - Server - MoveNpcBetweenNodes:26
-
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
I’ve tried this:
table.sort(SortedTable,
function(Value1, Value2)
return Value1[2] > Value2[2]
end
)
but it gave me:
14:34:23.341 2 is not a valid member of Part "Workspace.TownNpc1Nodes.WalkToPackage.WalkTo.Node25"
Please help me