Thread: auto mute 718

Results 1 to 7 of 7
  1. #1 auto mute 718 
    You Own Me


    Join Date
    Jul 2015
    Posts
    193
    Thanks given
    68
    Thanks received
    35
    Rep Power
    206
    hey guys is there a trhead for a auto mute somewhere like one some one spem 6 lines nonstop they get muted. i could found it

    its for a 718 server
    Reply With Quote  
     

  2. #2  
    Registered Member
    Join Date
    May 2012
    Posts
    286
    Thanks given
    7
    Thanks received
    49
    Rep Power
    25
    This at the start of sendPublicChatMessage in Player.java

    Code:
    if(Utils.currentTimeMillis()-lastMessage > spamMessageTime){
                spamMessages++;
                if(spamMessages > 6) { //6 is the amount of spam to get muted
                    this.setMuted(3600000); // 1 hour (minutes * 60 * 1000)
                    sendMessage("You've been muted for 1 hour for spamming");
                    spamMessages = 0;
                }
            }else{
                spamMessages = 0;
            }
            lastMessage = Utils.currentTimeMillis();
    and these somewhere in Player.java (outside any methods)
    Code:
    int spamMessages = 0;
        long lastMessage = 0;
        final long spamMessageTime = 500; //in milliseconds (1000ms = 1s)
    Reply With Quote  
     

  3. Thankful users:


  4. #3  
    Donator


    Join Date
    Sep 2015
    Age
    24
    Posts
    532
    Thanks given
    68
    Thanks received
    115
    Rep Power
    414
    Quote Originally Posted by juuuuu View Post
    This at the start of sendPublicChatMessage in Player.java

    Code:
    if(Utils.currentTimeMillis()-lastMessage > spamMessageTime){
                spamMessages++;
                if(spamMessages > 6) { //6 is the amount of spam to get muted
                    this.setMuted(3600000); // 1 hour (minutes * 60 * 1000)
                    sendMessage("You've been muted for 1 hour for spamming");
                    spamMessages = 0;
                }
            }else{
                spamMessages = 0;
            }
            lastMessage = Utils.currentTimeMillis();
    and these somewhere in Player.java (outside any methods)
    Code:
    int spamMessages = 0;
        long lastMessage = 0;
        final long spamMessageTime = 500; //in milliseconds (1000ms = 1s)

    Thanks for this,
    useful i guess,
    Reply With Quote  
     

  5. #4  
    Registered Member
    Join Date
    May 2012
    Posts
    286
    Thanks given
    7
    Thanks received
    49
    Rep Power
    25
    Quote Originally Posted by GlamourGirl View Post
    Thanks for this,
    useful i guess,
    "useful you guess" ? I though he asked for that? :O

    Edit: oh he asked for a thread on that soz
    Reply With Quote  
     

  6. #5  
    Donator
    JTlr Frost's Avatar
    Join Date
    Oct 2014
    Posts
    649
    Thanks given
    69
    Thanks received
    254
    Rep Power
    34
    Quote Originally Posted by juuuuu View Post
    This at the start of sendPublicChatMessage in Player.java

    Code:
    if(Utils.currentTimeMillis()-lastMessage > spamMessageTime){
                spamMessages++;
                if(spamMessages > 6) { //6 is the amount of spam to get muted
                    this.setMuted(3600000); // 1 hour (minutes * 60 * 1000)
                    sendMessage("You've been muted for 1 hour for spamming");
                    spamMessages = 0;
                }
            }else{
                spamMessages = 0;
            }
            lastMessage = Utils.currentTimeMillis();
    and these somewhere in Player.java (outside any methods)
    Code:
    int spamMessages = 0;
        long lastMessage = 0;
        final long spamMessageTime = 500; //in milliseconds (1000ms = 1s)
    Putting this for public chat is kinda 'useless', it would be more helpful in friends chat, or yelling. I would also just put a delay between each message you can send, it would be better. Not an hour mute. Sounds kind of harsh for someone simply talking. Some people type fast and the text box is rather small to put alot into it. So gotta think about that.

    Speed Test
    Spoiler for The Hatred Group:


    Spoiler for Dapoosie:

    Attached image
    Attached image

    Attached image
    Reply With Quote  
     

  7. #6  
    Registered Member
    Join Date
    May 2012
    Posts
    286
    Thanks given
    7
    Thanks received
    49
    Rep Power
    25
    Quote Originally Posted by JTlr Frost View Post
    Putting this for public chat is kinda 'useless', it would be more helpful in friends chat, or yelling. I would also just put a delay between each message you can send, it would be better. Not an hour mute. Sounds kind of harsh for someone simply talking. Some people type fast and the text box is rather small to put alot into it. So gotta think about that.
    I think he can work out how to make it filter other chats aswell. And he asked to make them mute so you shouldn't be replying to me. And I don't think too many ppl write real messages in 0.5second 6 times in a row. Good points though
    Reply With Quote  
     

  8. #7  
    You Own Me


    Join Date
    Jul 2015
    Posts
    193
    Thanks given
    68
    Thanks received
    35
    Rep Power
    206
    sweet thx guys

    Quote Originally Posted by JTlr Frost View Post
    Putting this for public chat is kinda 'useless', it would be more helpful in friends chat, or yelling. I would also just put a delay between each message you can send, it would be better. Not an hour mute. Sounds kind of harsh for someone simply talking. Some people type fast and the text box is rather small to put alot into it. So gotta think about that.
    already added only for friendchat so its pretyy nice

    Quote Originally Posted by juuuuu View Post
    This at the start of sendPublicChatMessage in Player.java

    Code:
    if(Utils.currentTimeMillis()-lastMessage > spamMessageTime){
                spamMessages++;
                if(spamMessages > 6) { //6 is the amount of spam to get muted
                    this.setMuted(3600000); // 1 hour (minutes * 60 * 1000)
                    sendMessage("You've been muted for 1 hour for spamming");
                    spamMessages = 0;
                }
            }else{
                spamMessages = 0;
            }
            lastMessage = Utils.currentTimeMillis();
    and these somewhere in Player.java (outside any methods)
    Code:
    int spamMessages = 0;
        long lastMessage = 0;
        final long spamMessageTime = 500; //in milliseconds (1000ms = 1s)
    Thnx
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Auto Donation 718/742
    By Cya Forever in forum Help
    Replies: 0
    Last Post: 02-23-2013, 12:57 AM
  2. Auto mute for spammers
    By sheepmonger in forum Tutorials
    Replies: 6
    Last Post: 12-16-2012, 07:51 AM
  3. Auto Mute [PI]
    By Gretar in forum Snippets
    Replies: 20
    Last Post: 11-09-2012, 12:45 AM
  4. Word Filter ***! + auto mutes
    By budies2004 in forum Help
    Replies: 5
    Last Post: 05-04-2009, 04:32 AM
  5. Word Filter ! + auto mutes
    By budies2004 in forum Help
    Replies: 4
    Last Post: 05-04-2009, 04:29 AM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •