Raised This Month: $32 Target: $400
 8% 

[ANY] Cross servers chat (No database)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Arkarr
Veteran Member
Join Date: Sep 2012
Location: Just behind my PC screen
Plugin ID:
4791
Plugin Version:
1.0
Plugin Category:
General Purpose
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    This plugin send messages on all other servers ! Let's spam !
    Old 08-22-2015 , 06:36   [ANY] Cross servers chat (No database)
    Reply With Quote #1




    Description :
    As the title say, this plugin send the message from your servers to other one !
    This plugin also supprot MORECOLORS !
    Original request : https://forums.alliedmods.net/showthread.php?t=269627

    For the developers who don't know how to use sockets, or a just intersted on how I did that, I wrote this :
    https://forums.alliedmods.net/showthread.php?p=2336943


    Screenshots & Videos :


    If someone wanna do a video / pictures about this plugin, you can send me the link and I will post it here.

    Cvar & installation

    Cvar : READ IT PLEASE ! Carefully.

    "sm_csc_is_master_server" "0"
    Is this server the master chat server ? 1 = yes | 0 = no
    Note : ONLY 1 SERVER SHOULD HAVE THIS VALUE TO 1, others should have 0. It doesn't matter wich server have the value 1.

    "sm_csc_master_chat_server_ip" "123.467.89.10"
    IP of the master chat server, the server who have 'sm_csc_is_master_server' to 1.

    "sm_csc_connection_port" "2001"
    On wich port should the plugin read & send the messages ? This value should be the same on ALL servers. Also, the port need to be forwarded. CAN NOT ME THE SERVER PORT (usually, 27015)

    "sm_csc_message_key" "[PASSWORD]" //Exemple of good password : 786%*ç%)=)&/, you don't need to remember it.
    Wich key should the plugin use to send messages, KEEP PRIVATE !!!

    "sm_csc_reconnect_time" "45.00"
    After how much time a connection should try to reconnect disconnected sockets ?

    "sm_csc_server_tag" "[REMOTE MSG]" //Support more colors ! Use {green} or what you prefer !
    Tag before messages coming from outside of the actual server

    "sm_csc_mark_to_send" "+"
    Tag before chat messages to send to all other servers

    "sm_csc_admin_flag" "NONE"
    Putting a flag as value will restrict the usage to all players who hvae this flag, putting NONE don't restrict the acces.

    "sm_csc_message_format" "{red}[SERVER TAG] {purple}->{default} {pink}[SENDER NAME]{default} {purple}said{default} [MESSAGE]"
    Format of the message. Use the tag [SERVER TAG] to represent the value of 'CVAR_ServerTag', [SENDER NAME] for the player name who send the message, and [MESSAGE] to represent the message of teh player.

    Commands :

    sm_msg [MESSAGE] - Send a message to all servers produce smae effect as +[message] but, +[message] doesn't work on some servers 'cause of simple chat processor.
    Exemple : sm_msg Hello everybody !
    Admin command :

    sm_cscgag [TARGET] - Block / Unblock a player from sending messages to other servers.

    Installation :

    1) Put CrossServerChat.smx in your plugins folder.
    2) Download and install the socket extension. Update if you already have it installed.
    3) Read and configure the config file 'CrossServerChat.cfg' and put it in your cfg/sourcemod folder !
    4) Restart all your servers.

    For those who wanna compille the plugin manually, you will need :
    • Socket extension
    • Multicolors

    Configuration

    A configuration file is created at the first start, in the cfg/sourcemod/ folder ! The same as the attached one, below.

    Bugs :


    When a socket fail to connect, produce strange things on reconnect. -> FIXED !

    Request & to do:


    Nothing, feel free to ask.

    Logs :
    ------
    1.0 : First public release.
    1.1 : Added the tag support thing.
    1.2 : Added a new command, sm_cscgag. ( See admin command )
    1.3 : Added a new CVAR, to restrict who can send messages, and who can't.
    1.4 : Removed the start order restriciton. cleaned a bit the code.
    1.5 : Even more clean up, also, fixed some strange bugs occuring rarelly.
    1.6 : Added a new command.
    -------

    IMPORTANT NOTE:
    Take a very good look at the cvar.
    Attached Files
    File Type: cfg CrossServerChat.cfg (1.7 KB, 709 views)
    File Type: smx CrossServerChat.smx (21.5 KB, 618 views)
    File Type: sp Get Plugin or Get Source (CrossServerChat.sp - 799 views - 17.3 KB)
    __________________
    Want to check my plugins ?

    Last edited by Arkarr; 09-01-2015 at 13:11.
    Arkarr is offline
    BatyaMedic
    Member
    Join Date: Sep 2014
    Old 08-22-2015 , 09:00   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #2

    i love it.
    __________________
    BatyaMedic is offline
    Arkarr
    Veteran Member
    Join Date: Sep 2012
    Location: Just behind my PC screen
    Old 08-22-2015 , 09:05   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #3

    Quote:
    Originally Posted by BatyaMedic View Post
    i love it.
    No problem mate !
    __________________
    Want to check my plugins ?
    Arkarr is offline
    Mr.Halt
    Junior Member
    Join Date: Sep 2014
    Location: Korea, Republic of
    Old 08-22-2015 , 10:48   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #4

    This plugin is AWESOME! I really love this plugin.
    By the way, does this plugin need to use command when players' chat transfer to other servers?
    I mean... when players typed chat, is it should be like '!command chat' when players' chat transfer to other servers?

    Actually, if you are busy, you don't need to answer this question.
    Mr.Halt is offline
    Send a message via Skype™ to Mr.Halt
    Arkarr
    Veteran Member
    Join Date: Sep 2012
    Location: Just behind my PC screen
    Old 08-22-2015 , 10:51   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #5

    Quote:
    Originally Posted by Mr.Halt View Post
    This plugin is AWESOME! I really love this plugin.
    By the way, does this plugin need to use command when players' chat transfer to other servers?
    I mean... when players typed chat, is it should be like '!command chat' when players' chat transfer to other servers?

    Actually, if you are busy, you don't need to answer this question.
    First, thanks, really appreciate.

    Then, yes.
    Quote:
    "sm_csc_mark_to_send" "+"
    Tag before chat messages to send to all other servers
    You can define a charactere (here '+') and if it's in the first position of the message, the message will be sent on all connected servers, for exemple :
    +send my message to everyone ! YAY!
    Will send the message everywhere
    do not send my message
    Will stay on the server, 'cause the '+' char isn't found.

    Hope it helps.

    NOTE:
    You have to re-download the smx, I updated things. Also, morecolors supported in server tag as well ! (see CVAR)
    __________________
    Want to check my plugins ?

    Last edited by Arkarr; 08-22-2015 at 10:52.
    Arkarr is offline
    Mr.Halt
    Junior Member
    Join Date: Sep 2014
    Location: Korea, Republic of
    Old 08-22-2015 , 10:55   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #6

    Quote:
    Originally Posted by Arkarr View Post
    First, thanks, really appreciate.

    Then, yes.

    You can define a charactere (here '+') and if it's in the first position of the message, the message will be sent on all connected servers, for exemple :
    +send my message to everyone ! YAY!
    Will send the message everywhere
    do not send my message
    Will stay on the server, 'cause the '+' char isn't found.

    Hope it helps.

    NOTE:
    You have to re-download the smx, I updated things. Also, morecolors supported in server tag as well ! (see CVAR)
    Thanks to answer of it. It really helps me.
    Mr.Halt is offline
    Send a message via Skype™ to Mr.Halt
    Arkarr
    Veteran Member
    Join Date: Sep 2012
    Location: Just behind my PC screen
    Old 08-22-2015 , 10:56   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #7

    Quote:
    Originally Posted by Mr.Halt View Post
    Thanks to answer of it. It really helps me.
    If you have any other troubles, just message here, I don't have anything else to do... :¬|
    __________________
    Want to check my plugins ?
    Arkarr is offline
    404UserNotFound
    BANNED
    Join Date: Dec 2011
    Old 08-22-2015 , 11:00   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #8

    Looking at the setup instructions, I see that there's a specific startup order required. I was going to try this, but since I use a combination of Dr. McKay's Auto Steam Update plugin, and the Server Crontab plugin (automatic restart of servers on a pushed update + a daily 3AM restart), the servers tend to restart in whatever order they restart in, which is impossible for me to control.

    If you can figure out a way for startup order to not be needed for the setup of this, then it'd be perfect.
    404UserNotFound is offline
    Arkarr
    Veteran Member
    Join Date: Sep 2012
    Location: Just behind my PC screen
    Old 08-22-2015 , 11:08   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #9

    @abrandnewday
    In fact, in this state, the plugin is unbale to send message for X seconds after the server started (X = sm_csc_reconnect_time). Wich is not perfect.
    So, why shouldn't we lower the value of sm_csc_reconnect_time to something like 3.0 sec ?
    'cause it would create (3.00 * timeout of the first request) connections. Wich is bad.

    So, the only thing you can do to fix your problem now, is to set the value of 'sm_csc_reconnect_time' to 60.0 or 90.0 seconds, so you would be sure there is only 1 connection between client server and master server. Wich also means, that after you started your server, the global chat won't be able to be used after those 60-90 seconds.

    Working on a better fix.
    __________________
    Want to check my plugins ?
    Arkarr is offline
    m_bNightstalker
    Senior Member
    Join Date: Jan 2015
    Location: JWD
    Old 08-22-2015 , 11:28   Re: [ANY] Cross servers chat (No database)
    Reply With Quote #10

    please use this: https://github.com/Bara20/Multi-Colors

    otherwise it's not for [ANY] game
    m_bNightstalker is offline
    Reply


    Thread Tools
    Display Modes

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 02:39.


    Powered by vBulletin®
    Copyright ©2000 - 2024, vBulletin Solutions, Inc.
    Theme made by Freecode