Solved offline players in a group

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

Ariuw

Member
Sep 6, 2017
42
1
8
30
Hello...

I need to get rid of a command cooldown. But I don't have any idea of how to remove the cooldown if the player is offline. What I need is this:
  • When I use /crab remove I want it to remove the cooldown from all players in the same group
How can I do it? I got it working for online players that have the same permission. But not for offline ones, please help :/
 
maybe you could run the check for their permission on the leave event, and add them to a list of people with the perm. Then check that list to remove the cooldown? Don't believe you can check an offline player's perms. May be inncorect as I've never tried to.
 
maybe you could run the check for their permission on the leave event, and add them to a list of people with the perm. Then check that list to remove the cooldown? Don't believe you can check an offline player's perms. May be inncorect as I've never tried to.
Can you send me an example to see if it works?
 
code_language.skript:
on leave:
    if player has permission "banana":
        add "%player%" to {bananagroup.withperm::*}
Ok then what I want to remove all the players that are in that group?

Code:
command /forcedelete:
    delete {bananagroup.withperm::*}
 
Ok then what I want to remove all the players that are in that group?

Code:
command /forcedelete:
    delete {bananagroup.withperm::*}
That will delete that list, yes.
[doublepost=1515601323,1515601217][/doublepost]On quit, not on leave btw, I derped. lol
 
That will delete that list, yes.
[doublepost=1515601323,1515601217][/doublepost]On quit, not on leave btw, I derped. lol
Yeah it's okay lol.

I have a problem, they have a countdown that I want to remove when I use a command like /forcedelete. Any Idea of how to do it?
 
Last edited:
If I understand what you want correctly, you want to remove the lastused cooldown variable, yes?
If so, loop the offline people with perm list you created, and delete the variable with the loop value:
code_language.skript:
loop {crab.withperm::*}:
    delete {crab.%loop-value%.lastused}
 
If I understand what you want correctly, you want to remove the lastused cooldown variable, yes?
If so, loop the offline people with perm list you created, and delete the variable with the loop value:
code_language.skript:
loop {crab.withperm::*}:
    delete {crab.%loop-value%.lastused}
Yes!!! it works. Thank you so much!, I'll have to delete the code but thank you <3
 
Status
Not open for further replies.