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.

Solved Skript Help, Team Chat

Discussion in 'Skript' started by Hjaller, Nov 10, 2017.

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

    Hjaller Member

    Joined:
    Nov 10, 2017
    Messages:
    14
    Likes Received:
    0
    I have made a team script, and now I have made a team chat, but I have no idea how to do it: The command it must be / tc:
    I hope you can help.
    Write if you need more information

    - Hjaller
     
  2. EricDasBrot

    EricDasBrot Member

    Joined:
    Jun 1, 2017
    Messages:
    26
    Likes Received:
    0
    Code (Skript):
    1. command /tc [<text>]:
    2.     trigger:
    3.         if arg-1 is not set:
    4.             message "&cPlease use: /tc <message>"
    5.             stop
    6.            
    7.         else:
    8.             loop all players:
    9.                 if loop-player has permission "tc.getmessage":
    10.                     message "&4&l%player% &7>>> %arg-1%" to loop-player
    i hope this is what you need! :emoji_slight_smile:
     
  3. Hjaller

    Hjaller Member

    Joined:
    Nov 10, 2017
    Messages:
    14
    Likes Received:
    0
    Yes, but anyone who has permission to receive the message may have it
    --- Double Post Merged, Nov 10, 2017, Original Post Date: Nov 10, 2017 ---
    Sry for my bad English
     
  4. EricDasBrot

    EricDasBrot Member

    Joined:
    Jun 1, 2017
    Messages:
    26
    Likes Received:
    0
    what do you mean? i don't understand... xD
    and my english is also not very good.. :emoji_grinning:
     
  5. Hjaller

    Hjaller Member

    Joined:
    Nov 10, 2017
    Messages:
    14
    Likes Received:
    0
    What I think is that everyone with that permission can write to each other. One should only be able to write with his team
     
  6. EricDasBrot

    EricDasBrot Member

    Joined:
    Jun 1, 2017
    Messages:
    26
    Likes Received:
    0
    Code (Skript):
    1. command /tc [<player>] [<text>]:
    2.     permission: tc.send
    3.     permission message: &cYou don't have permission to do this!
    4.     trigger:
    5.        
    6.         if arg-1 is not set:
    7.             message "&cPlease use: /tc <player> <message>"
    8.             stop
    9.          
    10.         if arg-2 is not set:
    11.             message "&cPlease use: /tc <player> <message>"
    12.             stop  
    13.          
    14.         else:
    15.             loop all players:
    16.                 if loop-player has permission "tc.getmessage":
    17.                     if arg-1 has permission "tc.getmessage":
    18.                         message "&4&l%player% &7>>> %arg-2%" to arg-1
    19.                         stop
    20.                     else:
    21.                         message "&cThe player &6%arg-1% &cdoesn't have"
    22.                         message "&cenough permissions, to get the message."
    23.                         stop
    24.                        
    25. command /tcall [<text>]:
    26.     permission: tc.all
    27.     permission message: &cYou don't have permission to do this!
    28.     trigger:
    29.         if arg-1 is not set:
    30.             message "&c/tcall <message>"
    31.             stop
    32.         else:
    33.             loop all players:
    34.                 if loop-player has permission "tc.getmessage":
    35.                     message "&4&l%player% &7>>> &6%arg-1%" to loop-player
    36.                
    is this what you mean? if not, can you give me your server ip? :emoji_grinning:
     
  7. Hjaller

    Hjaller Member

    Joined:
    Nov 10, 2017
    Messages:
    14
    Likes Received:
    0
    What I mean is that you should be able to communicate with your entire team in the team chat.
    My server runs local.
     
  8. Pikachu

    Supporter Addon Developer

    Joined:
    Jan 25, 2017
    Messages:
    871
    Likes Received:
    139
    Medals:
    There's literally no way anyone can do this without seeing how your teams script is setup.
     
  9. EricDasBrot

    EricDasBrot Member

    Joined:
    Jun 1, 2017
    Messages:
    26
    Likes Received:
    0
    my brain is death xD.
    if you want you can join the server ericdasbrot.mygs.co .
    we can test what you want!

    and i don't have a server normaly... xD
     
  10. Hjaller

    Hjaller Member

    Joined:
    Nov 10, 2017
    Messages:
    14
    Likes Received:
    0
  11. Pikachu

    Supporter Addon Developer

    Joined:
    Jan 25, 2017
    Messages:
    871
    Likes Received:
    139
    Medals:
    Somewhere in there should be a variable that has a players team and the players on that team. Send chat to that
     
  12. ChisleLP

    ChisleLP Well-Known Member

    Joined:
    Jan 26, 2017
    Messages:
    789
    Likes Received:
    60
    #Found this in line 300


    Code (Skript):
    1.  if arg 1 is "tc" or "chat":
    2.             set {_arg2} to {team::%uuid of player%}
    3.             if {team::%uuid of player%} is set:
    4.                     send "Im sending: %arg-2%" to {_arg2}
     
  13. Hjaller

    Hjaller Member

    Joined:
    Nov 10, 2017
    Messages:
    14
    Likes Received:
    0
    The code you have sent is not work
    --- Double Post Merged, Nov 11, 2017, Original Post Date: Nov 11, 2017 ---
    there is no errors with the code you have sent, but the message is not sending to the team..
    --- Double Post Merged, Nov 11, 2017 ---
    I hope anyone can help me.
    --- Double Post Merged, Nov 12, 2017 ---
    Anyone there can help me please.
    --- Double Post Merged, Nov 12, 2017 ---
    I've got help :emoji_slight_smile: Thanks for your help :emoji_slight_smile:

    command /tc <text>:
    trigger:
    if {team::%uuid of player%} is not set:
    send "{@prefix} &cDu er ikke med i noget i team"
    else:
    loop all players:
    {team::%uuid of loop-player%} is {team::%uuid of command sender%}
    send "&8[ &a&lTEAM &8] &6%command sender% &7> &e%arg-1%" to loop-player
     
Thread Status:
Not open for further replies.

Share This Page

Loading...