1. 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!

  2. LOOKING FOR A VERSION OF SKRIPT?

    You can always check out our Wiki for downloads and any other information about Skript!

Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

List loop

Discussion in 'Skript' started by Hartvig, Dec 10, 2019.

Thread Status:
Not open for further replies.
  1. Hartvig

    Hartvig Member

    Joined:
    Apr 18, 2017
    Messages:
    39
    Likes Received:
    1
    Trying to make this work, currently it adds 4 reports when reporting a player, if i report multiple players with multiple reasons they will all have the same reason, reported by etc.

    No reload errors

    Skript Version (do not put latest): 2.4-beta7
    Skript Author: Hartvig
    Minecraft Version: 1.12

    Full Code:
    Code (Text):
    1. options:
    2.     mr: &cMissing reason, reasons: &7flyhack, nuker, reach
    3. command /report [<offline player>] [<text>]:
    4.     trigger:
    5.         if arg 1 is not set:
    6.             send "&cPlease do /report &7[&cplayer&7] &7[&creason&7]"
    7.         if arg 1 is set:
    8.             if arg 1 is a offline player:
    9.                 if arg 2 is set:
    10.                     if arg 2 is "flyhack", "nuker" or "reach":
    11.                         add skull of arg 1 to {reports::*}
    12.                         add arg 1 to {reports::*}
    13.                         add player to {reports::*}
    14.                         add arg 2 to {reports::*}
    15.                         send "&cReported &e&n%arg 1% &cfor &e&n%arg 2%"
    16.                     else:
    17.                         send "{@mr}"
    18.                 else:
    19.                     send "{@mr}"
    20. command /reports:
    21.     permission: "report.sk"
    22.     trigger:
    23.         set {_i} to chest inventory with 6 rows named  "&c&lReports"
    24.         wait 1 tick
    25.         open {_i} to player
    26.         set {_slot} to -1
    27.         loop {reports::*}:
    28.             add 1 to {_slot}
    29.             set slot {_slot} of {_i} to 1st element of {reports::*} named "&e&l%2nd element of {reports::*}%" with lore "&7Reported by &b%3rd element of {reports::*}%" and "&7Reason &c%4th element of {reports::*}%"
     
  2. novastosha

    novastosha Well-Known Member

    Joined:
    Jan 11, 2019
    Messages:
    344
    Likes Received:
    22
    Here you go bro :emoji_wink: I full ready skript
    .
    Permission for /reports (reports.hartvig)
    .
    Addons Needed: TuSKe
    --- Double Post Merged, Dec 10, 2019, Original Post Date: Dec 10, 2019 ---
    Fixed version :emoji_slight_smile:
     

    Attached Files:

    • Sk.sk
      File size:
      1.8 KB
      Views:
      154
    • Sk.sk
      File size:
      1.9 KB
      Views:
      151
    • Friendly Friendly x 1
  3. Hartvig

    Hartvig Member

    Joined:
    Apr 18, 2017
    Messages:
    39
    Likes Received:
    1
    Thank you, i do have some errors when i reload though
    error.png
    --- Double Post Merged, Dec 10, 2019 ---
    oh downloaded the non-fixed version. It looks great but i have the same issue as before when reporting multiple players the skull will remain of one person, it doesn't load the reason either
     
  4. novastosha

    novastosha Well-Known Member

    Joined:
    Jan 11, 2019
    Messages:
    344
    Likes Received:
    22
    aya fixxed version
     

    Attached Files:

    • Sk.sk
      File size:
      1.8 KB
      Views:
      151
  5. Hartvig

    Hartvig Member

    Joined:
    Apr 18, 2017
    Messages:
    39
    Likes Received:
    1
    yo i appreciate it but still quite not working, when reporting multiple people the reported by, reason, person stays the same
     
  6. novastosha

    novastosha Well-Known Member

    Joined:
    Jan 11, 2019
    Messages:
    344
    Likes Received:
    22
    Thats anti spam :emoji_slight_smile:
     
  7. Hartvig

    Hartvig Member

    Joined:
    Apr 18, 2017
    Messages:
    39
    Likes Received:
    1
    i meant, if reporting 2 different players, it will only take the value of 1 of them and duplicate it over to the other, so when reporting 3 different players you will have 3 reports with same reason, reported by, and reported player though it's different players
     
Thread Status:
Not open for further replies.

Share This Page

Loading...