• 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.

CloudLess_

New Member
Jan 3, 2020
5
0
0
20
Hello script community!

I want to do a Skirpt, which counts how many players with a certain permission are on the server.

Can someone help me there?
 
code_language.skript:
command EXCMD:
    trigger:
        loop all players:
            if loop-player has permission "Your Perm":
                add 1 to {Amount::%player%}
                add loop-player to {Players::%player%::*}
        send "&aThere is %{Amount::%player%}% online!"
        loop {Players::%player%::*}:
            send "- %loop-value%"
        clear {Amount::%player%}
        clear {Players::%player%::*}
 
Try
Code:
size of (all players where [input has permission "test.permission"])
 
Status
Not open for further replies.