Solved how to track how long someone has been idle for?

  • 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.
Try this:
Code:
Every 5 minutes:
  If {position.%player%} is player's position:
    #Do a really cool command
  Else:
    Set {position.%player%} to player's location
 
Try this:
Code:
Every 5 minutes:
  If {position.%player%} is player's position:
    #Do a really cool command
  Else:
    Set {position.%player%} to player's location

I guess that would work, I would just get a random event, while player's location = location in the beginning add 1 second to a timer.
 
Try this:
Code:
Every 5 minutes:
  If {position.%player%} is player's position:
    #Do a really cool command
  Else:
    Set {position.%player%} to player's location
im getting errors when i try to run this code
 
Try this:
Code:
Every 5 minutes:
  If {position.%player%} is player's position:
    #Do a really cool command
  Else:
    Set {position.%player%} to player's location

I agree with @barrybtw, but to be more precise:
1. You don't have to capitalize the first letter, it just looks ugly
2. There is no player in a periodical event, you have to loop all players and then use the loop-player for your code
3. Switch from the normal variables {var.%player%} to list variables {var::%player%}
4. Even if your code would work... it does not make any sense
 
Status
Not open for further replies.