Skip to content

Commit 03ca485

Browse files
try the new readme format
1 parent bd2a82c commit 03ca485

File tree

1 file changed

+93
-105
lines changed

1 file changed

+93
-105
lines changed

README.md

Lines changed: 93 additions & 105 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,78 @@
11
# Player Stats
2-
Player PVP and PVE stats with ranking, rewards and UI.
2+
> Track and display player PVP and PVE statistics with ranking, rewards and UI
33
4-
## Features
5-
* Stores player stats in a JSON file or MySQL database
6-
* Displays player stats, playtime, ranking, and session stats using commands
7-
* Supports PVP (Kills) and PVE (Zombie Kills) ranking
8-
* Permission group rewards for reaching a certain number of kills
9-
* Automatic migration from Arechi PlayerStats plugin
10-
* UI for PVP/PVE stats
4+
---
115

12-
**PVP Stats:** Kills, Deaths, KDR, HS%
13-
**PVE Stats:** Zombies, Mega Zombies, Animals, Resources, Harvests, Fish
6+
## 📊 Overview
7+
Player Stats is a plugin that tracks various player statistics and provides ranking for both PVP and PVE gameplay. The plugin supports permission-based rewards and includes an optional visual UI.
148

15-
**`<StatsMode>Both</StatsMode>` configuration options:**
16-
* `Both` - The `/stats` command will display both PVP and PVE stats, but the ranking, rewards and UI will be based on PVP stats
17-
* `PVP` - The `/stats` command will display only PVP stats, and the ranking, rewards and UI will be based on PVP stats
18-
* `PVE` - The `/stats` command will display only PVE stats, and the ranking, rewards and UI will be based on PVE stats
9+
## ✨ Features
10+
| Feature | Description |
11+
|---------|-------------|
12+
| 💾 Data Storage | Store player stats in a JSON file or MySQL database |
13+
| 📈 Stats Display | Show player stats, playtime, ranking, and session stats via commands |
14+
| 🏆 Rankings | Support for both PVP (Kills) and PVE (Zombie Kills) leaderboards |
15+
| 🎁 Rewards | Permission group rewards for reaching specific kill thresholds |
16+
| 🔄 Migration | Automatic migration from Arechi PlayerStats plugin |
17+
| 🖥️ User Interface | Optional UI for viewing PVP/PVE stats |
1918

20-
## Credits
21-
UI made by **💪 Soer (Unbeaten)**. He also sponsored the creation of this plugin 💸.
19+
## 📊 Tracked Statistics
20+
21+
### PVP Stats
22+
- Kills
23+
- Deaths
24+
- KDR (Kill/Death Ratio)
25+
- HS% (Headshot Percentage)
26+
27+
### PVE Stats
28+
- Zombies
29+
- Mega Zombies
30+
- Animals
31+
- Resources
32+
- Harvests
33+
- Fish
34+
35+
---
36+
37+
## 🔧 Configuration Options
38+
39+
### Stats Mode (`<StatsMode>Both</StatsMode>`)
40+
41+
| Mode | Description |
42+
|------|-------------|
43+
| `Both` | The `/stats` command displays both PVP and PVE stats, but ranking, rewards and UI are based on PVP stats |
44+
| `PVP` | The `/stats` command displays only PVP stats, and ranking, rewards and UI are based on PVP stats |
45+
| `PVE` | The `/stats` command displays only PVE stats, and ranking, rewards and UI are based on PVE stats |
46+
47+
---
48+
49+
## 🖥️ Workshop Integration (Optional)
50+
The UI is optional and provides a visual display for PVP stats.
51+
52+
- **Workshop Item**: [Player Stats UI](https://steamcommunity.com/sharedfiles/filedetails/?id=3352126593)
53+
- **ID**: `3352126593`
54+
55+
> 💡 **PRO TIP**
56+
> Remember to set `<EnableUIEffect>true</EnableUIEffect>` in the configuration file to activate the UI.
57+
58+
---
59+
60+
## 🔑 Commands
61+
62+
| Command | Description |
63+
|---------|-------------|
64+
| `/playtime [player]` | Shows your or another player's total playtime |
65+
| `/stats [player]` | Displays your or another player's stats |
66+
| `/rank [player]` | Shows your or another player's ranking |
67+
| `/sstats [player]` | Displays your or another player's session stats (since they joined) |
68+
| `/splaytime [player]` | Shows your or another player's session playtime (since they joined) |
69+
| `/ranking` | Displays the top players ranking |
70+
| `/statsui` | Toggles the stats UI on/off |
71+
72+
---
73+
74+
## 🔐 Permissions
2275

23-
## Workshop (optional)
24-
The UI is optional and only for PVP stats. You can use the following workshop item to display the stats in-game.
25-
[Player Stats UI](https://steamcommunity.com/sharedfiles/filedetails/?id=3352126593) - `3352126593`
26-
> **💡 PRO TIP**
27-
> Remember to set `<EnableUIEffect>true</EnableUIEffect>` to **true** in the configuration file to enable the UI.
28-
29-
## Commands
30-
* `/playtime [player]` - Displays your or other player's playtime
31-
* `/stats [player]` - Displays your or other player's stats
32-
* `/rank [player]` - Displays your or other player's ranking
33-
* `/sstats [player]` - Displays your or other player's session stats (since they joined)
34-
* `/splaytime [player]` - Displays your or other player's session playtime (since they joined)
35-
* `/ranking` - Displays the top players ranking
36-
* `/statsui` - Toggles the stats UI
37-
38-
## Permissions
3976
```xml
4077
<Permission Cooldown="0">playtime</Permission>
4178
<Permission Cooldown="0">stats</Permission>
@@ -46,7 +83,9 @@ The UI is optional and only for PVP stats. You can use the following workshop it
4683
<Permission Cooldown="0">statsui</Permission>
4784
```
4885

49-
## Configuration
86+
---
87+
88+
## ⚙️ Configuration
5089
```xml
5190
<?xml version="1.0" encoding="utf-8"?>
5291
<PlayerStatsConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
@@ -72,75 +111,24 @@ The UI is optional and only for PVP stats. You can use the following workshop it
72111
</PlayerStatsConfiguration>
73112
```
74113

75-
## Translations
76-
```xml
77-
<?xml version="1.0" encoding="utf-8"?>
78-
<Translations xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
79-
<Translation Id="StatsCommandSyntax" Value="You must specify player name or steamID." />
80-
<Translation Id="PlayerStatsNotLoaded" Value="Player stats are not loaded for [[b]]{0}.[[/b]] Please try again later." />
81-
<Translation Id="PlayerNotFound" Value="Player [[b]]{0}[[/b]] not found." />
82-
<Translation Id="YourPVPStats" Value="[[b]]Your[[/b]] PVP stats | Kills: [[b]]{0}[[/b]], Deaths: [[b]]{1}[[/b]], KDR: [[b]]{2}[[/b]], HS%: [[b]]{3}[[/b]]" />
83-
<Translation Id="YourPVEStats" Value="[[b]]Your[[/b]] PVE stats | Zombies: [[b]]{0}[[/b]], Mega Zombies: [[b]]{1}[[/b]], Animals: [[b]]{2}[[/b]], Resources: [[b]]{3}[[/b]], Harvests: [[b]]{4}[[/b]], Fish: [[b]]{5}[[/b]]" />
84-
<Translation Id="OtherPVPStats" Value="[[b]]{0}[[/b]] PVP stats | Kills: [[b]]{1}[[/b]], Deaths: [[b]]{2}[[/b]], KDR: [[b]]{3}[[/b]], HS%: [[b]]{4}[[/b]]" />
85-
<Translation Id="OtherPVEStats" Value="[[b]]{0}[[/b]] PVE stats | Zombies: [[b]]{1}[[/b]], Mega Zombies: [[b]]{2}[[/b]], Animals: [[b]]{3}[[/b]], Resources: [[b]]{4}[[/b]], Harvests: [[b]]{5}[[/b]], Fish: [[b]]{6}[[/b]]" />
86-
<Translation Id="PlaytimeCommandSyntax" Value="You must specify player name or steamID." />
87-
<Translation Id="YourPlaytime" Value="You have played for [[b]]{0}[[/b]]" />
88-
<Translation Id="OtherPlaytime" Value="[[b]]{0}[[/b]] has played for [[b]]{1}[[/b]]" />
89-
<Translation Id="RankCommandSyntax" Value="You must specify player name or steamID." />
90-
<Translation Id="YourPlayerPVPRanking" Value="Your rank is [[b]]#{0}[[/b]] with {1} kills" />
91-
<Translation Id="OtherPlayerPVPRanking" Value="[[b]]{0}[[/b]] rank is [[b]]#{1}[[/b]] with {2} kills." />
92-
<Translation Id="YourPlayerPVERanking" Value="Your rank is [[b]]#{0}[[/b]] with {1} zombie kills." />
93-
<Translation Id="OtherPlayerPVERanking" Value="[[b]]{0}[[/b]] rank is [[b]]#{1}[[/b]] with {2} zombie kills." />
94-
<Translation Id="RankingListHeaderPVP" Value="[[b]]Top {0} Players by Kills[[/b]]" />
95-
<Translation Id="RankingListItemPVP" Value="[[b]]#{0}[[/b]] [[b]]{1}[[/b]] - {2} kills" />
96-
<Translation Id="RankingListHeaderPVE" Value="[[b]]Top {0} Players by Zombie Kills[[/b]]" />
97-
<Translation Id="RankingListItemPVE" Value="[[b]]#{0}[[/b]] [[b]]{1}[[/b]] - {2} zombie kills" />
98-
<Translation Id="YouAreUnrankedPVP" Value="You are unranked because you have [[b]]{0}/{1}[[/b]] kills. " />
99-
<Translation Id="OtherPlayerIsUnrankedPVP" Value="[[b]]{0}[[/b]] is unranked because they have [[b]]{1}/{2}[[/b]] kills." />
100-
<Translation Id="YouAreUnrankedPVE" Value="You are unranked because you have [[b]]{0}/{1}[[/b]] zombie kills. " />
101-
<Translation Id="OtherPlayerIsUnrankedPVE" Value="[[b]]{0}[[/b]] is unranked because they have [[b]]{1}/{2}[[/b]] zombie kills." />
102-
<Translation Id="NoRankingPlayersFound" Value="There isn't any players qualified for ranking yet." />
103-
<Translation Id="StatsUIEffectDisabled" Value="Stats UI is not enabled on this server." />
104-
<Translation Id="StatsUIDisabled" Value="Stats UI has been disabled" />
105-
<Translation Id="StatsUIEnabled" Value="Stats UI has been enabled" />
106-
<Translation Id="RewardReceivedPVP" Value="You received [[b]]{0}[[/b]] reward for {1} kills." />
107-
<Translation Id="RewardReceivedPVE" Value="You received [[b]]{0}[[/b]] reward for {1} zombie kills." />
108-
<Translation Id="YourPVPSessionStats" Value="[[b]]Your[[/b]] PVP session stats | Kills: [[b]]{0}[[/b]], Deaths: [[b]]{1}[[/b]], KDR: [[b]]{2}[[/b]], HS%: [[b]]{3}[[/b]]" />
109-
<Translation Id="OtherPVPSessionStats" Value="[[b]]{0}[[/b]] PVP session stats | Kills: [[b]]{1}[[/b]], Deaths: [[b]]{2}[[/b]], KDR: [[b]]{3}[[/b]], HS%: [[b]]{4}[[/b]]" />
110-
<Translation Id="YourPVESessionStats" Value="[[b]]Your[[/b]] PVE session stats | Zombies: [[b]]{0}[[/b]], Mega Zombies: [[b]]{1}[[/b]], Animals: [[b]]{2}[[/b]], Resources: [[b]]{3}[[/b]], Harvests: [[b]]{4}[[/b]], Fish: [[b]]{5}[[/b]]" />
111-
<Translation Id="OtherPVESessionStats" Value="[[b]]{0}[[/b]] PVE session stats | Zombies: [[b]]{1}[[/b]], Mega Zombies: [[b]]{2}[[/b]], Animals: [[b]]{3}[[/b]], Resources: [[b]]{4}[[/b]], Harvests: [[b]]{5}[[/b]], Fish: [[b]]{6}[[/b]]" />
112-
<Translation Id="SessionStatsCommandSyntax" Value="You must specify player name or steamID." />
113-
<Translation Id="SessionPlaytimeCommandSyntax" Value="You must specify player name or steamID." />
114-
<Translation Id="YourSessionPlaytime" Value="You have played for [[b]]{0}[[/b]] since you joined." />
115-
<Translation Id="OtherSessionPlaytime" Value="[[b]]{0}[[/b]] has played for [[b]]{1}[[/b]] since they joined." />
116-
<Translation Id="JoinMessage" Value="[[b]][#{0}] {1}[[/b]] joined the server." />
117-
<Translation Id="LeaveMessage" Value="[[b]][#{0}] {1}[[/b]] left the server." />
118-
<Translation Id="JoinMessageNoRank" Value="[[b]]{0}[[/b]] joined the server." />
119-
<Translation Id="LeaveMessageNoRank" Value="[[b]]{0}[[/b]] left the server." />
120-
<Translation Id="Day" Value="1 day" />
121-
<Translation Id="Days" Value="{0} days" />
122-
<Translation Id="Hour" Value="1 hour" />
123-
<Translation Id="Hours" Value="{0} hours" />
124-
<Translation Id="Minute" Value="1 minute" />
125-
<Translation Id="Minutes" Value="{0} minutes" />
126-
<Translation Id="Second" Value="1 second" />
127-
<Translation Id="Seconds" Value="{0} seconds" />
128-
<Translation Id="Zero" Value="a moment" />
129-
<Translation Id="UI_NextReward" Value="Next Reward: {0}" />
130-
<Translation Id="UI_RewardProgress" Value="{0}/{1} Kills" />
131-
<Translation Id="UI_Kills" Value="KILLS" />
132-
<Translation Id="UI_Deaths" Value="DEATHS" />
133-
<Translation Id="UI_Headshots" Value="HS" />
134-
<Translation Id="UI_Accuracy" Value="HS%" />
135-
<Translation Id="UI_Rank" Value="RANK" />
136-
<Translation Id="UI_KDR" Value="K/D" />
137-
<Translation Id="UI_Footer" Value="Use /statsui to hide" />
138-
<Translation Id="UI_RewardProgressPVE" Value="{0}/{1} Zombies" />
139-
<Translation Id="UI_ZombieKills" Value="ZOMBIES" />
140-
<Translation Id="UI_MegaZombieKills" Value="MEGAS" />
141-
<Translation Id="UI_AnimalKills" Value="ANIMALS" />
142-
<Translation Id="UI_ResourcesGathered" Value="GATHERS" />
143-
<Translation Id="UI_PVEDeaths" Value="DEATHS" />
144-
</Translations>
145-
</Translations>
146-
```
114+
---
115+
116+
## 👨‍💻 Credits
117+
UI made by **💪 Soer (Unbeaten)**. He also sponsored the creation of this plugin 💸.
118+
119+
---
120+
121+
## ❓ Frequently Asked Questions
122+
123+
1. **How do I enable the UI?**
124+
Set `<EnableUIEffect>true</EnableUIEffect>` in the configuration and subscribe to the workshop item.
125+
126+
2. **Can I use MySQL instead of JSON?**
127+
Yes, change `<DatabaseProvider>json</DatabaseProvider>` to `<DatabaseProvider>mysql</DatabaseProvider>` and configure your connection string.
128+
129+
3. **How do I customize rewards?**
130+
Edit the `<Rewards>` section in the configuration file with your desired thresholds and permission groups.
131+
132+
---
133+
134+
*For support, bug reports, or feature requests, please write on our forum or join our Discord.*

0 commit comments

Comments
 (0)