Skip to content

Commit

Permalink
Merge pull request #137 from nwesterhausen/dev
Browse files Browse the repository at this point in the history
Add some configuration for positional data and new variable for world name.
  • Loading branch information
nwesterhausen authored Nov 23, 2022
2 parents a6bdf5e + cf11096 commit 721693e
Show file tree
Hide file tree
Showing 25 changed files with 785 additions and 357 deletions.
17 changes: 16 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
{
"cSpell.words": ["Leaderboard", "leaderboards"]
"cSpell.words": [
"Digitalroot",
"discordconnector",
"ipify",
"Leaderboard",
"leaderboards",
"PLAYERID",
"PUBLICIP",
"r2modman",
"Roadmap",
"Spidey",
"STEAMID",
"thedefside",
"Valheim",
"Xithyr"
]
}
28 changes: 20 additions & 8 deletions Metadata/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,18 @@ A full changelog for reference.

## History

### Version 2.0.5

Features:

- Adds a config option to format how position data is formatted
- Adds a config option to format how the automatically-appended position data is formatted
- Adds a new variable which can be used in any messages: `%WORLD_NAME%` turns into the name of the world.

Changes:

- `%POS%` now renders without the enclosing parentheses.

### Version 2.0.4

Features:
Expand All @@ -14,7 +26,7 @@ Features:

Other Changes:

- Set BepInEx depencency to eactly 5.4.19 instead of 5.* (this stops a warning from showing up)
- Set BepInEx dependency to exactly 5.4.19 instead of 5.* (this stops a warning from showing up)

### Version 2.0.2

Expand All @@ -30,7 +42,7 @@ With this update, we bring back Steam_ID variable inclusion and leaderboard mess

Fixes:

- Periodic leaderboard messages sending will now respect your config value intead of never sending
- Periodic leaderboard messages sending will now respect your config value instead of never sending
- The STEAMID variable works again. An alias is the PLAYERID variable, which does the same thing -- they both provide the full player id, so `Steam_<SteamID>` or `XBox_<XBoxID>`

Breaking changes:
Expand All @@ -45,7 +57,7 @@ Breaking changes:

- Removed steamid variable (internally) and tracking stats by steamid. This broke with the PlayFab changes to Valheim. It will be a bit involved to figure out how to deliver the same thing again, so if you have an idea or seen it done in another mod, please reach out with a Github Issue or ping on Discord.
- Leaderboard records will reset and a new database with suffix '-records2.db' will be saved anew. This is because what is being tracked is changed (used to be steamid, now it is using the character id).
- Perodic leaderboard messages will not send, ignoring the setting in the config (for now). This is until a more reliable method of determining players apart.
- Periodic leaderboard messages will not send, ignoring the setting in the config (for now). This is until a more reliable method of determining players apart.

### Version 1.8.0

Expand Down Expand Up @@ -160,7 +172,7 @@ not migrate the data.
For the migration steps, it will be outputting log information (at INFO
level) with how many records were migrated and which steps completed.

- Ranked Lowest Player Leaderbaord
- Ranked Lowest Player Leaderboard

Added an inverse of the Top Player leaderboard.

Expand Down Expand Up @@ -230,7 +242,7 @@ Breaking Changes:

Features:

- Additional leaderboard options. The existing leaerboard option will now default to sending top 3 players for what is enabled.
- Additional leaderboard options. The existing leaderboard option will now default to sending top 3 players for what is enabled.
You can enable a highest and lowest leaderboard for each tracked stat now. All leaderboards get sent on the same interval.

### Version 1.2.2
Expand Down Expand Up @@ -328,7 +340,7 @@ This is fixed and you can have join messages disabled and death messages enabled
Features:

- %PLAYER_NAME% is replaced in messages with the player name, allowing you to change
where in the message the playe is mentioned (Thanks @Digitalroot)
where in the message the player is mentioned (Thanks @Digitalroot)
- Configurable Ping and Shout messages

Fixes:
Expand Down Expand Up @@ -418,7 +430,7 @@ when you log in, it adds a little context: "John joined the game for the 1st tim
"Stuart arrives. Previous logins: 15". The context additions are not yet created but
record-keeping is ready and makes sense to get it started as soon as possible.

If you want to disable the record keeping in its entirity, set the Collect Player Stats
If you want to disable the record keeping in its entirety, set the Collect Player Stats
config value to false. This will prevent any records from being saved or written to disk.

### Version 0.5.0
Expand Down Expand Up @@ -472,7 +484,7 @@ are not broadcast and instead it is only network messages.
### Version 0.2.0

- Use config values to set what messages get sent for what actions
- More granualarity with Enable/Disable for existing messages
- More granularity with Enable/Disable for existing messages

### Version 0.1.2

Expand Down
34 changes: 16 additions & 18 deletions Metadata/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Connect your Valheim server (dedicated or served from the game itself) to a Disc
- Record number of logins/deaths/pings and flavor the Discord messages
- Works with non-dedicated server (games opened to lan from the client)

### Supported Message Notificaitons
### Supported Message Notifications

- Server startup (server starting, loading the world)
- Server started (world loaded, ready to join)
Expand All @@ -35,6 +35,18 @@ See the [current roadmap](https://github.com/nwesterhausen/valheim-discordconnec

## Changelog

### Version 2.0.5

Features:

- Adds a config option to format how position data is formatted
- Adds a config option to format how the automatically-appended position data is formatted
- Adds a new variable which can be used in any messages: `%WORLD_NAME%` turns into the name of the world.

Changes:

- `%POS%` now renders without the enclosing parentheses.

### Version 2.0.4

Features:
Expand All @@ -45,7 +57,7 @@ Features:

Other Changes:

- Set BepInEx depencency to eactly 5.4.19 instead of 5.* (this stops a warning from showing up)
- Set BepInEx dependency to exactly 5.4.19 instead of 5.* (this stops a warning from showing up)

### Version 2.0.2

Expand All @@ -61,7 +73,7 @@ With this update, we bring back Steam_ID variable inclusion and leaderboard mess

Fixes:

- Periodic leaderboard messages sending will now respect your config value intead of never sending
- Periodic leaderboard messages sending will now respect your config value instead of never sending
- The STEAMID variable works again. An alias is the PLAYERID variable, which does the same thing -- they both provide the full player id, so `Steam_<SteamID>` or `XBox_<XBoxID>`

Breaking changes:
Expand All @@ -76,18 +88,4 @@ Breaking changes:

- Removed steamid variable (internally) and tracking stats by steamid. This broke with the PlayFab changes to Valheim. It will be a bit involved to figure out how to deliver the same thing again, so if you have an idea or seen it done in another mod, please reach out with a Github Issue or ping on Discord.
- Leaderboard records will reset and a new database with suffix '-records2.db' will be saved anew. This is because what is being tracked is changed (used to be steamid, now it is using the character id).
- Perodic leaderboard messages will not send, ignoring the setting in the config (for now). This is until a more reliable method of determining players apart.

### Version 1.8.0

Features:

- Web requests to Discord API are async instead of blocking the main thread

Fixes:

- Handles the edge case when a toggle was enabled but the text in 'messages' for that toggle was blank, the plugin would crash. (e.g. if 'send shout' toggle was `true` but the 'shout message' was blank, in prior versions this would crash the plugin)

Full changelog history available on the
[Github repository](https://github.com/nwesterhausen/valheim-discordconnector/blob/main/Metadata/CHANGELOG.md)
or [discordconnector.valheim.nwest.games](https://discordconnector.valheim.nwest.games/changelog).
- Periodic leaderboard messages will not send, ignoring the setting in the config (for now). This is until a more reliable method of determining players apart.
Binary file added Metadata/icon-hdpi.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed Metadata/icon.pdn
Binary file not shown.
Binary file modified Metadata/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
101 changes: 101 additions & 0 deletions Metadata/icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion Metadata/manifest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "DiscordConnector",
"version_number": "2.0.4",
"version_number": "2.0.5",
"website_url": "https://discordconnector.valheim.nwest.games/",
"description": "Connects your Valheim server to a Discord webhook. Works for both dedicated and client-hosted servers.",
"dependencies": ["denikson-BepInExPack_Valheim-5.4.1901"]
Expand Down
2 changes: 1 addition & 1 deletion Metadata/thunderstore.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ schemaVersion = "0.0.1"
[package]
namespace = "nwesterhausen"
name = "DiscordConnector"
versionNumber = "2.0.4"
versionNumber = "2.0.5"
description = "Connects your Valheim server to a Discord webhook. Works for both dedicated and client-hosted servers."
websiteUrl = "https://discordconnector.valheim.nwest.games/"
containsNsfwContent = false
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
[![Build](https://github.com/nwesterhausen/valheim-discordconnector/actions/workflows/dotnet.yml/badge.svg)](https://github.com/nwesterhausen/valheim-discordconnector/actions/workflows/dotnet.yml)
[![Publish](https://github.com/nwesterhausen/valheim-discordconnector/actions/workflows/publish.yml/badge.svg)](https://github.com/nwesterhausen/valheim-discordconnector/actions/workflows/publish.yml)
[![GitHub release (latest by date)](https://img.shields.io/github/v/release/nwesterhausen/valheim-discordconnector?label=Github%20Release&style=flat&labelColor=%2332393F)](https://github.com/nwesterhausen/valheim-discordconnector/releases/latest)
[![Thunderstore.io](https://img.shields.io/badge/Thunderstore.io-2.0.4-%23375a7f?style=flat&labelColor=%2332393F)](https://valheim.thunderstore.io/package/nwesterhausen/DiscordConnector/)
[![NexusMods](https://img.shields.io/badge/NexusMods-2.0.4-%23D98F40?style=flat&labelColor=%2332393F)](https://www.nexusmods.com/valheim/mods/1551/)
[![Thunderstore.io](https://img.shields.io/badge/Thunderstore.io-2.0.5-%23375a7f?style=flat&labelColor=%2332393F)](https://valheim.thunderstore.io/package/nwesterhausen/DiscordConnector/)
[![NexusMods](https://img.shields.io/badge/NexusMods-2.0.5-%23D98F40?style=flat&labelColor=%2332393F)](https://www.nexusmods.com/valheim/mods/1551/)

Connect your Valheim server to Discord. ([See website for installation or configuration instructions](https://discordconnector.valheim.nwest.games/)). This plugin is largely based on [valheim-discord-notifier](https://github.com/aequasi/valheim-discord-notifier), but this plugin supports randomized messages, muting players, and Discord message embeds.

Expand Down
28 changes: 20 additions & 8 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,18 @@ A full changelog

## History

### Version 2.0.5

Features:

- Adds a config option to format how position data is formatted
- Adds a config option to format how the automatically-appended position data is formatted
- Adds a new variable which can be used in any messages: `%WORLD_NAME%` turns into the name of the world.

Changes:

- `%POS%` now renders without the enclosing parentheses.

### Version 2.0.4

Features:
Expand All @@ -14,7 +26,7 @@ Features:

Other Changes:

- Set BepInEx depencency to eactly 5.4.19 instead of 5.* (this stops a warning from showing up)
- Set BepInEx dependency to exactly 5.4.19 instead of 5.* (this stops a warning from showing up)

### Version 2.0.2

Expand All @@ -30,7 +42,7 @@ With this update, we bring back Steam_ID variable inclusion and leaderboard mess

Fixes:

- Periodic leaderboard messages sending will now respect your config value intead of never sending
- Periodic leaderboard messages sending will now respect your config value instead of never sending
- The STEAMID variable works again. An alias is the PLAYERID variable, which does the same thing -- they both provide the full player id, so `Steam_<SteamID>` or `XBox_<XBoxID>`

Breaking changes:
Expand All @@ -45,7 +57,7 @@ Breaking changes:

- Removed steamid variable (internally) and tracking stats by steamid. This broke with the PlayFab changes to Valheim. It will be a bit involved to figure out how to deliver the same thing again, so if you have an idea or seen it done in another mod, please reach out with a Github Issue or ping on Discord.
- Leaderboard records will reset and a new database with suffix '-records2.db' will be saved anew. This is because what is being tracked is changed (used to be steamid, now it is using the character id).
- Perodic leaderboard messages will not send, ignoring the setting in the config (for now). This is until a more reliable method of determining players apart.
- Periodic leaderboard messages will not send, ignoring the setting in the config (for now). This is until a more reliable method of determining players apart.

### Version 1.8.0

Expand Down Expand Up @@ -160,7 +172,7 @@ not migrate the data.
For the migration steps, it will be outputting log information (at INFO
level) with how many records were migrated and which steps completed.

- Ranked Lowest Player Leaderbaord
- Ranked Lowest Player Leaderboard

Added an inverse of the Top Player leaderboard.

Expand Down Expand Up @@ -230,7 +242,7 @@ Breaking Changes:

Features:

- Additional leaderboard options. The existing leaerboard option will now default to sending top 3 players for what is enabled.
- Additional leaderboard options. The existing leaderboard option will now default to sending top 3 players for what is enabled.
You can enable a highest and lowest leaderboard for each tracked stat now. All leaderboards get sent on the same interval.

### Version 1.2.2
Expand Down Expand Up @@ -328,7 +340,7 @@ This is fixed and you can have join messages disabled and death messages enabled
Features:

- %PLAYER_NAME% is replaced in messages with the player name, allowing you to change
where in the message the playe is mentioned (Thanks @Digitalroot)
where in the message the player is mentioned (Thanks @Digitalroot)
- Configurable Ping and Shout messages

Fixes:
Expand Down Expand Up @@ -418,7 +430,7 @@ when you log in, it adds a little context: "John joined the game for the 1st tim
"Stuart arrives. Previous logins: 15". The context additions are not yet created but
record-keeping is ready and makes sense to get it started as soon as possible.

If you want to disable the record keeping in its entirity, set the Collect Player Stats
If you want to disable the record keeping in its entirety, set the Collect Player Stats
config value to false. This will prevent any records from being saved or written to disk.

### Version 0.5.0
Expand Down Expand Up @@ -472,7 +484,7 @@ are not broadcast and instead it is only network messages.
### Version 0.2.0

- Use config values to set what messages get sent for what actions
- More granualarity with Enable/Disable for existing messages
- More granularity with Enable/Disable for existing messages

### Version 0.1.2

Expand Down
Loading

0 comments on commit 721693e

Please sign in to comment.