Raised This Month: $1944 Target: $400
 486% 

MatterAMXX: Chat relay between many services [Includes API]


Post New Thread Reply   
 
Thread Tools Display Modes
Gabe Iggy
Veteran Member
Join Date: Mar 2011
Location: Chile
Old 11-07-2019 , 20:47   Re: MatterAMXX
Reply With Quote #11

Hello, a new version was released
  • 1.2
    • Added new console variable: amx_matter_bridge_outgoing_join_delay
      • Specify how many seconds the server has to wait before sending Join messages.
    • Added new console variable: amx_matter_bridge_outgoing_quit_ignore_interm ission
      • Specify if the server shouldn't send quit messages if the server reached the intermission state
    • Added new console variable: amx_matter_bridge_outgoing_display_map
      • Display the current map at the start of every session
    • Added new console variable: amx_matter_bridge_outgoing_joinquit_count
      • Display playercount on each Join/Quit message
    • Added API support!
      • The API allows other plugins to use MatterAMXX features
      • New stock: matteramxx_send_message
      • New forward: matteramxx_print_message
    • The plugin can now be set up to compile without the HamSandwich module.
    • Adjusted some code, using newer DEFINEs.

Minor revision to 1.2
  • 1.2.1
    • Fixed a bug where the attacker and victim were reversed in the non-HamSandwich version.
    • Fixed a bug where the leave message should show the player count before the player actually left.
__________________

Last edited by Gabe Iggy; 11-07-2019 at 21:28.
Gabe Iggy is offline
Gabe Iggy
Veteran Member
Join Date: Mar 2011
Location: Chile
Old 03-01-2020 , 19:16   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #12

Hello, a new version was released

1.3
  • Added new console variable: amx_matter_incoming_update_time
    • Specify how many seconds the server has to wait before querying new messages
  • Decreased default value of amx_matter_bridge_outgoing_join_delay (from 30.0 to 15.0)
  • Fixed a bug where it would not display when a new map has started
  • Added new debug information (requires the plugin to be running on debug mode)
    • Currently it only supports outgoing messages
  • Added new console variable: amx_matter_autogenerate_avatar
    • Allows avatar support for unauthenticated users (LAN, Pending IDs and other uses I won't mention)
    • You need to supply an URL to generate an image from Text, where %s is a URL parsed nickname of the user
  • MatterAMXX will now display the external username in color (only if the game is a version of Counter-Strike)

Current TO-DOs:
  • Display scoreboard at the end of each map
  • Create ignore message list
  • Call an admin in-game
__________________

Last edited by Gabe Iggy; 03-01-2020 at 19:40.
Gabe Iggy is offline
Gabe Iggy
Veteran Member
Join Date: Mar 2011
Location: Chile
Old 04-01-2020 , 01:02   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #13

Hello, a minor revision to 1.3 was released
  • 1.3.1
    • Tried to fix a case where multiple pending messages would cause them to not send due to AMXX limits. Further testing is required
    • Fixed a bug where it would always see any ID as a valid Steam ID
__________________
Gabe Iggy is offline
Gabe Iggy
Veteran Member
Join Date: Mar 2011
Location: Chile
Old 04-08-2020 , 10:51   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #14

Hello, a minor revision to 1.3 was released
  • 1.3.2
    • Extended buffers to allow more complex messages to be sent/received
    • Leave messages now work in 1.8.2
__________________
Gabe Iggy is offline
Gabe Iggy
Veteran Member
Join Date: Mar 2011
Location: Chile
Old 07-29-2020 , 18:15   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #15

Hello, a new version of the plugin was released.
  • 1.4
    • The matteramxx_print_message() forward now includes the user's avatar and protocol.
    • Fixed the Killed Hamsandwich hook in TFC that was not working as it should.
    • Added multilingual support.
      • Many thanks to the language contributors:
        • Romanian: tom .
        • Turkish: Snake.
        • Albanian: thEsp
        • Russian: Natsheh
    • The following console variables are now protected:
      • amx_matter_bridge_token
      • amx_matter_bridge_gateway
      • amx_matter_bridge_url
      • amx_matter_player_avatar
      • amx_matter_autogenerate_avatar
      • amx_matter_system_avatar
    • Added new console variable: amx_matter_bridge_outgoing_chat_zwsp_at
      • This controls if the plugin should add a ZWSP character after the at symbol (@) to prevent unintentional or malicious pinging.
    • Added new console variable: amx_matter_bridge_incoming_chat_protocol
      • This controls if the plugin should add the message protocol in incoming messages.
    • The plugin (and subplugins) now pause when disabled.
    • Code cleanup.
    • New subplugins released to showcase the power of the MatterAMXX Api:
      • MatterAMXX Lagchecker
        • This plugin will notify a configured user if the CPU/FPS increase/fall past/below a defined threshold.
        • This will be triggered if any user says "lag".
        • This will also output the current values to the users notifying them if the server is not lagging.
        • Requires Orpheu and Orpheu Signatures.
      • MatterAMXX RCON
        • This plugin will allow you to control the server's console from any messaging protocol, with full console output.
        • You can configure which users are allowed to send commands to the server console.
        • Requires Orpheu and Orpheu Signatures.
__________________
Gabe Iggy is offline
Gabe Iggy
Veteran Member
Join Date: Mar 2011
Location: Chile
Old 07-29-2020 , 18:16   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #16

[ALL] MatterAMXX Plugins

The MatterAMXX API allow plugin creators to capture and send messages via MatterAMXX, you can see the plugin in action in the following plugins!

MatterAMXX Lag Checker


This plugin will notify a configured user if the CPU/FPS increase/fall past/below a defined threshold. Triggered if someone says "lag" on the server.

If the user says "lag" and the server is not lagging he will be notified along with the FPS and CPU values.

Requirements:
Console Variables:
  • amx_matter_lagchecker_enabled
    Enables the plugin.
    Default 1.
  • amx_matter_lagchecker_ping_this_person
    Determines the person/s who should be pinged on alert.
    Should be a pingable string, for example "@username" for Telegram or "<@12345678910>" for Discord ID.
    Default [blank string].
  • amx_matter_lagchecker_cpu_threshold
    If the CPU goes over this percentage, an alert should be sent.
    Default 75.
  • amx_matter_lagchecker_fps_threshold
    If the FPS goes below this percentage (based on sys_ticrate), an alert should be sent..
    Default 25.

Changelog:
  • 1.4
    • Initial Release

MatterAMXX RCON

Control the server from anywhere.

This plugin will allow you to control the server's console from any messaging protocol, with full console output.

You can configure which users are allowed to send commands to the server console.

Requirements:
Configuration:

By default the plugin won't accept commands from any user, to do so you need to edit the matteramxx_rcon_accounts.ini file in your AMXX config folder.
Code:
; Add all accounts to have access to Matteramxx RCON
; Any account not on this list will be denied from executing commands
;
; Syntax: username§protocol

;Gabe Iggy#9999§discord
The format is username§protocol. Both are required to disallow impersonation.

Console Variables:
  • amx_matter_rcon_enable
    Enables the plugin.
    Default 1.
  • amx_matter_rcon_dont_ignore_list
    Determines if the plugin should NOT ignore the master account list and accept commands from any user
    Dangerous! A badly configured bridge will allow to anyone to get access to the game console. Set it to 1 unless you really know what are you doing.
    Default 1.
  • amx_matter_rcon_prefix
    The bot prefix to send commands to the console
    Default "!rcon "
  • amx_matter_rcon_hide_cvars
    Determines if the plugin should redact protected cvars. (like rcon_password)
    Default 1.
  • amx_matter_rcon_hide_ips
    Determines if the plugin should redact IPs.
    Default 1.
  • amx_matter_rcon_code_block
    Determines if the plugin should send the output in a code block
    Note that not every protocol supports this feature
    Default 1.

Changelog:
  • 1.4
    • Initial Release

Installation instructions
  • Download all requirements, plus the .sma file.
  • Place include files, in the /scripting/includes directory.
  • Compile the plugin and install the newly generated .amxx files. (Remember to install the latest version of MatterAMXX in your server)
Attached Files
File Type: zip MatterAMXX Lag Checker.zip (1.7 KB, 3 views)
File Type: zip MatterAMXX RCON.zip (3.7 KB, 3 views)
__________________

Last edited by Gabe Iggy; 07-29-2020 at 18:46.
Gabe Iggy is offline
Gabe Iggy
Veteran Member
Join Date: Mar 2011
Location: Chile
Old 07-30-2020 , 14:03   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #17

Moving the conversation from another thread to help other people set up the plugin.

Quote:
Originally Posted by MaNaReaver View Post
So, I put the executable and .toml file in a folder, and added gRIP module. I also compiled matteramxx, but the relay isn't happening. Also, what do I need to have in amx_matter_bridge_url? Should it be my server url or something else?

This is my toml file:

Code:
[api.myserver1]
BindAddress="35.200.152.63:27010"
Token="token"
Buffer=1000
RemoteNickFormat="{NICK}"

[api.myserver2]
BindAddress="35.200.152.63:27020"
Token="token"
Buffer=1000
RemoteNickFormat="{NICK}"

[discord]
[discord.mydiscord]
Token="token"
Server="server-id"
#Server="Crimson Demons Multimod"
WebhookURL="webhookurl"

[[gateway]]
name="cstrike"
enable=true

[[gateway.inout]]
account="discord.mydiscord"
channel="discussion"

[[gateway.inout]]
account="api.myserver1"
channel="api"

[[gateway.inout]]
account="api.myserver2"
channel="api"
Best regards.
amx_matter_bridge_url is where you are hosting the matterbridge instance.

For example: "http://(ipofyourserver):27010/"

If you're hosting MatterBridge on the same machine as your gameservers you can use localhost ("http://localhost:27010/"). If not, you must use the external IP of the server that's hosting MatterBridge.

Quote:
[api.myserver1]
BindAddress="35.200.152.63:27010"
Token="token"
Buffer=1000
RemoteNickFormat="{NICK}"

[api.myserver2]
BindAddress="35.200.152.63:27020"
Token="token"
Buffer=1000
RemoteNickFormat="{NICK}"
Change BindAddress to 0.0.0.0, it must be a local, this makes it so the API will be listening to the local IP.

You can use any port providing is it not being used.

For reference I will put my own configuration of one of my servers:
matterbridge.toml
PHP Code:
[discord.spanish]
    
# You can get your token by following the instructions on
    # https://github.com/42wim/matterbridge/wiki/Discord-bot-setup
    # If you want roles/groups mentions to be shown with names instead of ID, 
    # you'll need to give your bot the "Manage Roles" permission.
    
Token="(REDACTED)"
    
Server="450507265657798656" # picked from guilds the bot is connected to
    
RemoteNickFormat="{NICK} @ {LABEL}"
    
ShowEmbeds=false
    UseUserName
=true
    UseDiscriminator
=true
    EditDisable
=true
    EditSuffix
=" (edited)"
    
Label="discord"

[api.hldm_arcadeflorida]
    
BindAddress="0.0.0.0:4243"
    
Token="(REDACTED)"
    
Buffer=1000
    RemoteNickFormat
="{NICK}"
    
Label="valve"

[[gateway]]
    
name="hldm_arcadeflorida"
    
enable=true
    
[[gateway.inout]]
        
account="discord.spanish"
        
channel="ID:698718732897484841"
        
[gateway.inout.options]
            
WebhookURL="https://discordapp.com/api/webhooks/(REDACTED)"
    
[[gateway.inout]]
        
account="api.hldm_arcadeflorida"
        
channel="api" 
cvars:
Code:
amx_matter_bridge_url "http://(redacted):4243"
amx_matter_bridge_gateway "hldm_arcadeflorida"
amx_matter_bridge_token "(redacted)"
amx_matter_bridge_outgoing_system_username "* Server"
amx_matter_bridge_outgoing_kills "0"
amx_matter_bridge_outgoing_join "1"
amx_matter_bridge_outgoing_quit "1"
amx_matter_bridge_incoming_chat_protocol 1
__________________

Last edited by Gabe Iggy; 07-30-2020 at 14:14.
Gabe Iggy is offline
MaNaReaver
Member
Join Date: Apr 2020
Location: India
Old 07-30-2020 , 15:30   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #18

Quote:
Originally Posted by Gabe Iggy View Post
Moving the conversation from another thread to help other people set up the plugin.



amx_matter_bridge_url is where you are hosting the matterbridge instance.

For example: "http://(ipofyourserver):27010/"

If you're hosting MatterBridge on the same machine as your gameservers you can use localhost ("http://localhost:27010/"). If not, you must use the external IP of the server that's hosting MatterBridge.



Change BindAddress to 0.0.0.0, it must be a local, this makes it so the API will be listening to the local IP.

You can use any port providing is it not being used.

For reference I will put my own configuration of one of my servers:
matterbridge.toml
PHP Code:
[discord.spanish]
    
# You can get your token by following the instructions on
    # https://github.com/42wim/matterbridge/wiki/Discord-bot-setup
    # If you want roles/groups mentions to be shown with names instead of ID, 
    # you'll need to give your bot the "Manage Roles" permission.
    
Token="(REDACTED)"
    
Server="450507265657798656" # picked from guilds the bot is connected to
    
RemoteNickFormat="{NICK} @ {LABEL}"
    
ShowEmbeds=false
    UseUserName
=true
    UseDiscriminator
=true
    EditDisable
=true
    EditSuffix
=" (edited)"
    
Label="discord"

[api.hldm_arcadeflorida]
    
BindAddress="0.0.0.0:4243"
    
Token="(REDACTED)"
    
Buffer=1000
    RemoteNickFormat
="{NICK}"
    
Label="valve"

[[gateway]]
    
name="hldm_arcadeflorida"
    
enable=true
    
[[gateway.inout]]
        
account="discord.spanish"
        
channel="ID:698718732897484841"
        
[gateway.inout.options]
            
WebhookURL="https://discordapp.com/api/webhooks/(REDACTED)"
    
[[gateway.inout]]
        
account="api.hldm_arcadeflorida"
        
channel="api" 
cvars:
Code:
amx_matter_bridge_url "http://(redacted):4243"
amx_matter_bridge_gateway "hldm_arcadeflorida"
amx_matter_bridge_token "(redacted)"
amx_matter_bridge_outgoing_system_username "* Server"
amx_matter_bridge_outgoing_kills "0"
amx_matter_bridge_outgoing_join "1"
amx_matter_bridge_outgoing_quit "1"
amx_matter_bridge_incoming_chat_protocol 1
I tried out http://localhost:80, http://localhost:27010, http://localhost:27020, and my IP addresses as bridge, but I was receiving the error: "[MatterAMXX] Invalid message arrived, ignoring."

I set the token for both servers and gateway was set to cstrike. Maybe my bridge is the fault here, should it be an accessible link for the bridge or it's fine as long as it's accessing the bridge from the server?
__________________
MaNaReaver is offline
Gabe Iggy
Veteran Member
Join Date: Mar 2011
Location: Chile
Old 07-30-2020 , 15:41   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #19

Can you connect to your bridges via a web browser?

If they're protected by a token you should get a "missing key in request header" message.
__________________
Gabe Iggy is offline
MaNaReaver
Member
Join Date: Apr 2020
Location: India
Old 07-30-2020 , 16:45   Re: MatterAMXX: Chat relay between many services [Includes API]
Reply With Quote #20

Quote:
Originally Posted by Gabe Iggy View Post
Can you connect to your bridges via a web browser?

If they're protected by a token you should get a "missing key in request header" message.
Yeah, the matterbridge.toml and executable are accessable through the web, but the same error message pops up. I've changed the BindAddress to 0.0.0.0:27010 and 27020. My gateway name's cstrike, and my bridge is set to http://<IP excluding Port>/<Directory of MatterBridge>/ .
__________________

Last edited by MaNaReaver; 07-30-2020 at 17:35.
MaNaReaver 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 10:38.


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