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!

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

Sign with number of players

Discussion in 'Requests' started by powershooter83, Apr 20, 2018.

  1. powershooter83

    Joined:
    Apr 20, 2018
    Messages:
    19
    Likes Received:
    0
    Hey! How can I make the sign show the number of players in a world?
     
  2. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,183
    Likes Received:
    234
    You could try something like this
    obviously set the location, to the location of your sign, and change it to whichever line you would like

    Code (Skript):
    1. on load:
    2.     set {login.count} to 0
    3.  
    4. on join:
    5.     add 1 to {login.count}
    6.     set line 1 of block located at 0, 0, 0 in world "world" to "%{login.count}%/100"
    7.  
    8. on quit:
    9.     subtract 1 from {login.count}
    10.     set line 1 of block located at 0, 0, 0 in world "world" to "%{login.count}%/100"
    11.  
     
  3. powershooter83

    Joined:
    Apr 20, 2018
    Messages:
    19
    Likes Received:
    0
    Not bad, but it gives 2 errors.
    1. 59, 70, -8 in world "plots" is not a text
    2. 59, 70, -8 in world "plots" is not a text
     
  4. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,183
    Likes Received:
    234
    sorry i typed it wrong

    Code (Skript):
    1. on join:
    2.     add 1 to {login.count}
    3.     set line 1 of block at location at 0, 0, 0 in world "world" to "%{login.count}%"
    4.  
    5. on quit:
    6.     subtract 1 from {login.count}
    7.     set line 1 of block at location at 0, 0, 0 in world "world" to "%{login.count}%"
    8.  
     
  5. powershooter83

    Joined:
    Apr 20, 2018
    Messages:
    19
    Likes Received:
    0
    It goes but there is 0 but I am in the world
     
  6. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,183
    Likes Received:
    234
    try log out, restart your skript, then log back in
     
  7. powershooter83

    Joined:
    Apr 20, 2018
    Messages:
    19
    Likes Received:
    0
    Or can you say my how I can make a join sign?
    On the sign must stand the players in the world an when I make right click will I teleport to the world?
     
  8. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,183
    Likes Received:
    234
    Im sorry I do not quite understand what you are saying, but if you are meaning if they click on a sign in TPs them somewhere,
    try this
    Code (Skript):
    1. on right-click on sign:
    2.     if event-location is location at 0, 0, 0 in world "world":
    3.         teleport the player to location at 0, 0, 0 in world "other world here"
    4.  
     

Share This Page

Loading...