A client for connecting to the Gossip MUD chat network. See https://grapevine.haus/docs for more information.
The package can be installed by adding gossip
to your list of dependencies in mix.exs
:
def deps do
[
{:gossip, "~> 0.6"},
]
end
Set the following in your mix project's configuration. Do not commit the client id and secret. These should be in a prod.secret.exs
file or similar that is ignored from your repo.
config :gossip, :client_id, "CLIENT ID"
config :gossip, :client_secret, "CLIENT SECRET"
config :gossip, :callback_modules,
core: Callbacks.Core,
players: Callbacks.Players,
tells: Callbacks.Tells,
games: Callbacks.Games
You can opt into specific support flags on Gossip by configuring callback modules that follow the specific behaviours.
See a sample set of callbacks by viewing the TestCallback
module for this client, here.
The channels
flag must be supported and can be set up by providing a callback module that has the Gossip.Client.Core
behaviour.
The players
flag can be set up by providing a callback module that has the Gossip.Client.Players
behaviour.
The tells
flag can be set up by providing a callback module that has the Gossip.Client.Tells
behaviour.
the games
flag can be set up by providing a callback module that has the gossip.client.games
behaviour.
[:gossip, :events, :channels, :broadcast]
- Received achannels/broadcast
event[:gossip, :events, :channels, :send, :request]
- Sending achannels/send
event[:gossip, :events, :core, :authenticate, :request]
- Received a response toauthenticate
[:gossip, :events, :core, :authenticate, :response]
- Sending anauthenticate
event[:gossip, :events, :core, :heartbeat, :request]
- Received aheartbeat
event[:gossip, :events, :core, :restart]
- Received arestart
event[:gossip, :events, :games, :connect]
- Received agames/connect
event[:gossip, :events, :games, :disconnect]
- Received agames/disconnect
event[:gossip, :events, :games, :status, :request]
- Sending agames/status
event[:gossip, :events, :games, :status, :response]
- Received a response togames/status
[:gossip, :events, :players, :sign_in]
- Received aplayers/sign-in
event[:gossip, :events, :players, :sign_out]
- Received aplayers/sign-out
event[:gossip, :events, :players, :status, :request]
- Sending aplayers/status
event[:gossip, :events, :players, :status, :response]
- Received a response toplayers/status
[:gossip, :events, :tells, :receive]
- Received atells/receive
event[:gossip, :events, :tells, :send, :request]
- Sending atells/send
event[:gossip, :events, :tells, :send, :response]
- Received a response totells/send