Solved Can someone explains list with more than 1 index?

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

Mich

Active Member
Jul 15, 2020
148
6
18
23
I want to understand list with more than one index for example: {list::index 1:: index 2}
and how I can take advantage of this types of list using loops like example: loop {list::index 1::*}
 
lists like that are mostly used to keep track of where something is, a good example is:
Code:
{stats::strength::%player's uuid%}
{stats::defense::%player's uuid%}

but you can also use it to make a list that containts list, which is basically what i typed above

so instead of having:

Code:
{backpack1::%player's uuid%}
{backpack2::%player's uuid%}
{backpack3::%player's uuid%}

you will have:

Code:
{backpack::1::%player's uuid%}
{backpack::2::%player's uuid%}
{backpack::3::%player's uuid%}

OR

Code:
{backpack::page1::%player's uuid%}
{backpack::page2::%player's uuid%}
{backpack::page3::%player's uuid%}

the index doesnt need to be an integer, it can be a string and skript will give it an index to sort it out

so if you were to use the last example i showed above, if the backpack::* list had nothing and then we added those 3 sublists, the first one will have the index 1 and so on.

I may have flipped over some of the info about this so please check some tutorials on the SkUnity or SkriptHub tutorials before applying anything i said.
Hope this helped.
 
  • Like
Reactions: Mich
Status
Not open for further replies.