diff --git a/docs/API-Examples.md b/docs/API-Examples.md
index 530f397c..e63bd4c2 100644
--- a/docs/API-Examples.md
+++ b/docs/API-Examples.md
@@ -74,6 +74,30 @@ A number of methods from the HuskHomesAPI return asynchronously-executing [Compl
> **Warning:** You should never call `#join()` on futures returned from the HuskHomesAPI as futures are processed on server asynchronous tasks, which could lead to thread deadlock and crash your server if you attempt to lock the main thread to process them.
+## Getting a player
+You can get an OnlineUser object, which represents a player currently connected to a server, by calling `HuskHomesAPI#adaptUser`.
+
+Alternatively (if you're compiling against the common module) you could use `HuskHomesAPI#getOnlineUser(UUID)` to get an `Optional` online user by UUID; the optional will contain the user if they are present and online.
+
+
+Getting an OnlineUser
+
+```java
+public class HuskHomesAPIHook {
+
+ private final HuskHomesAPI huskHomesAPI;
+
+ // This method prints out a player's homes into console using stdout
+ public void getAnOnlineUser(UUID uuid) {
+ OnlineUser user = huskHomesAPI.adaptUser(Bukkit.getPlayer(uuid));
+ System.out.println("Found " + user.getUsername() + "!");
+ Optional otherMethod = huskHomesAPI.getOnlineUser(uuid);
+ }
+
+}
+```
+
+
## Getting a player's homes
To get a list of a player's homes, you can call `#getUserHomes(user)` on the API instance. This method requires a `User` object, which can be constructed from a UUID and username, or adapted from an online player using `#adaptUser(player)`. The method returns a `CompletableFuture>`, which can be accepted with `#thenAccept()`.
@@ -105,7 +129,7 @@ public class HuskHomesAPIHook {
huskHomesAPI.getUserHome(user, "example").thenAccept(optionalHome -> {
// #getUserHome returns an Optional wrapper, so we need to run #ifPresent() first and call #get() to retrieve it if it exists
if (optionalHome.isPresent()) {
- System.out.println("Found " + user.getUsername() + "'s home: " optionalHome.get().getName());
+ System.out.println("Found " + user.getUsername() + "'s home: " + optionalHome.get().getName());
} else {
System.out.println("Home not found");
}
diff --git a/docs/Commands.md b/docs/Commands.md
index a462e574..7bea7a66 100644
--- a/docs/Commands.md
+++ b/docs/Commands.md
@@ -3,7 +3,7 @@ HuskHomes provides a range of commands for you to use. This page will detail the
## Commands & Permissions Table
> **Command Conflicts:** If you have multiple plugins providing similar commands, you may need to [create aliases](command-conflicts) to ensure HuskHomes' commands take priority.
-
+
| Key |
diff --git a/docs/Unsupported-Versions.md b/docs/Compatibility.md
similarity index 100%
rename from docs/Unsupported-Versions.md
rename to docs/Compatibility.md
diff --git a/docs/FAQs.md b/docs/FAQs.md
index a9e61ea6..38285ed3 100644
--- a/docs/FAQs.md
+++ b/docs/FAQs.md
@@ -1,6 +1,10 @@
-This page addresses a number of frequently asked questions.
+This page addresses a number of frequently asked questions about HuskHomes.
+
+## Frequently Asked Questions
+
+
+ How do I make it so players always rejoin the last server they left from?
-## How do I make it so players always rejoin the last server they left from?
In other words, you'd like it so that when players disconnect from your proxy network, that when they reconnect they are put on the same server as the one they were on when they disconnected, rather than your lobby/fallback server. This feature isn't controlled by HuskHomes, but rather on your proxy.
* On Velocity proxies: Install and configure [Yunfaremember](https://modrinth.com/plugin/yunfaremember).
@@ -8,8 +12,12 @@ In other words, you'd like it so that when players disconnect from your proxy ne
If this isn't working, make sure you've not configured priority servers which can override this.
-## What's the difference between a warp and a public home?
-**Warps:**
+
+
+
+ What's the difference between a warp and a public home?
+
+### Warps:
- Nobody owns a warp.
- It is just an object on the server.
- Intended to be created by admins; only able to be created by admins by default.
@@ -17,10 +25,26 @@ If this isn't working, make sure you've not configured priority servers which ca
- Accessible with /warp.
- All warp names must be unique globally.
-**Public homes:**
+### Public homes:
- Owned by a single player.
- Effectively, just a regular player home that has been made public.
- Can only be edited/deleted/etc by that player (unless you have admin perms).
-- Counts toward's the players home slot totals. You can also limit the number of homes a player can make public with perms & via config.
+- Counts towards the players home slot totals. You can also limit the number of homes a player can make public with perms & via config.
- Accessible with /phome, or /home (by the home owner)
- Names must be unique **per-player**; otherwise non-unique p-homes can be accessed with /phome OWNER_USERNAME.HOME_NAME.
+
+
+
+
+ Is a Database required? What Databases are supported?
+
+A database is not required for using HuskHomes on a single-server. If you want to use the plugin cross-server, however, a MySQL, MariaDB or PostgreSQL [[database]] are required.
+
+HuskHomes supports the following database types. Databases marked (local) are only supported on a single-server setup:
+* SQLite (local)
+* H2 (local)
+* MySQL v8.0+
+* MariaDB v5.0+
+* PostgreSQL
+
+
\ No newline at end of file
diff --git a/docs/Home.md b/docs/Home.md
index 6b6c3b2f..216ae8c3 100644
--- a/docs/Home.md
+++ b/docs/Home.md
@@ -1,40 +1,45 @@
# [](https://github.com/WiIIiam278/HuskHomes)
Welcome to the plugin documentation for HuskHomes v4.x+, the powerful & intuitive homes, warps, and teleportation suite developed by William278. Please click through to the topic you'd like to read about.
-## Guides
+## Setup
* π [[Setup]]
-* π [[Importing Data]]
+* πΎ [[Database]]
+* β¨ [[Redis]]
+* β οΈ [[Compatibility]]
* π [[Config Files]]
-* β [[Managing Access]]
-* π₯οΈ [[Commands]]
-* π [[Command Conflicts]]
-* βοΈ [[Troubleshooting]]
-* β [[FAQs]]
+* π [[Troubleshooting]]
-## Documentation
-* π [[Database]]
-* β
[[Redis Support]]
-* π [[Translations]]
+## Features
+* π₯οΈ [[Commands]]
* π© [[Plan Hook]]
* πΊοΈ [[Map Hooks]]
-* β° [[Cooldowns]]
* π΅ [[Economy Hook]]
* β οΈ [[Strict Tpahere]]
* π« [[Restricted Warps]]
-* ποΈ [[Global Respawning]]
+* β° [[Cooldowns]]
* π [[Global Spawn]]
+* ποΈ [[Global Respawning]]
+* β [[FAQs]]
+
+## Guides
+* π [[Importing Data]]
+* β [[Managing Access]]
+* π [[Command Conflicts]]
+* π [[Translations]]
* βοΈ [[Placeholders]]
-* πΈοΈ [[Legacy Migration]] (*v2 β v3*)
+* π [[Translations]]
+
+## Developers
* π¦ [[API]]
* π‘ [[API Examples]]
* β [[API Events]]
## Links
* π» [GitHub](https://github.com/WiIIiam278/HuskHomes)
-* π [Downloads](https://william278.net/project/huskhomes/)
+* π [Get HuskHomes](https://william278.net/project/huskhomes/)
* π§ [Modrinth](https://modrinth.com/plugin/huskhomes)
* π° [Spigot](https://www.spigotmc.org/resources/huskhomes.83767/)
* π [Polymart](https://polymart.org/resource/huskhomes.284/)
* π« [Hangar](https://hangar.papermc.io/William278/HuskHomes)
* π₯ [CurseForge](https://www.curseforge.com/minecraft/mc-mods/huskhomes/)
-* π¬ [Discord Support](https://discord.gg/tVYhJfyDWG)
+* π¬ [Discord Support](https://discord.gg/tVYhJfyDWG)
\ No newline at end of file
diff --git a/docs/Legacy-Migration.md b/docs/Legacy-Migration.md
deleted file mode 100644
index ddcd7191..00000000
--- a/docs/Legacy-Migration.md
+++ /dev/null
@@ -1,15 +0,0 @@
-> **Warning:** Migration from v2.11.x to v4.x is not supported; you must first download HuskHomes v3.2.1 and carry out the migration in that version, before upgrading to v4.x. No migration is needed between v3.x and v4.x as the two versions have the same database schema.
-
-To upgrade from HuskHomes v2.11.2 to v3.x, please carry out the following steps:
-
-* Delete the old `HuskHomes-2.x.jar` from your server(s) `plugins` folder(s).
-* Drag in the new HuskHomes v3.x jar file to the folder.
-* In your `plugins/HuskHomes/` folder, delete the `messages.yml` file to let it regenerate.
-* Start your server. If you are running multiple servers, start just one server. HuskHomes will automatically upgrade your data.
-* If you are running on multiple servers:
- - Delete `plugins/HuskHomes/config.yml` from each of your other servers.
- - Start each server you deleted config.yml from.
- - Once they have started, stop them again and navigate to the newly generated config.yml file on each server and update it with your database credentials and set the database type to MYSQL from SQLITE. Be sure to enable cross_server mode, too.
-* Update your Permissions plugin groups to make use of the [new permission nodes](https://william278.net/docs/huskhomes/Commands)
-
-That's it! Enjoy HuskHomes v3.x.
\ No newline at end of file
diff --git a/docs/Redis-Support.md b/docs/Redis-Support.md
deleted file mode 100644
index 9c80a856..00000000
--- a/docs/Redis-Support.md
+++ /dev/null
@@ -1,10 +0,0 @@
-For networks of connected servers, HuskHomes supports Redis (v5.0+) as an alternative to the default Plugin messaging protocol, for servers that would like to use it.
-
-## Setup
-To make use of Redis, your network must first be correctly configured in `cross_server` mode. Then, follow these steps:
-1. Turn off all your servers.
-2. Ensure your Redis server is online.
-3. Modify the `config.yml` files of each server, filling in the redis `credentials` in the `cross_server` section.
- - Most Redis installations don't have a password by default. You can probably leave `password` blank (`''`).
-4. Set the `messenger_type` to `REDIS`
-5. Save your config files and turn on each server. Check to make sure the plugin enabled the network messenger successfully on startup. If it didn't, check your credentials (try without setting the password and SSL mode off if neccessary).
\ No newline at end of file
diff --git a/docs/Redis.md b/docs/Redis.md
new file mode 100644
index 00000000..e2a4a659
--- /dev/null
+++ b/docs/Redis.md
@@ -0,0 +1,78 @@
+For networks of connected servers, HuskHomes supports Redis (v5.0+) as an alternative to the default Plugin messaging protocol, for servers that would like to use it. Redis is required if you would like to use cross-server RTP, otherwise is completely optional.
+
+## What is Redis?
+[Redis](http://redis.io/) (**RE**mote **DI**ctionary **S**erver) is an open-source, in-memory data store server that can be used as a cache, message broker, streaming engine, or database.
+
+HuskHomes supports Redis and uses it for pub/sub messaging to facilitate cross-server teleports and teleport requests, as well as other [[commands]].
+
+## Configuring
+To configure Redis, navigate to your [`config.yml`](Config-Files) file and modify the properties under `redis`. Change the `broker_type` to `REDIS`.
+
+
+Database options (config.yml)
+
+```yaml
+# Type of network message broker to ues for data synchronization (PLUGIN_MESSAGE or REDIS)
+broker_type: REDIS
+# Settings for if you're using REDIS as your message broker
+redis:
+ host: localhost
+ port: 6379
+ # Password for your Redis server. Leave blank if you're not using a password.
+ password: ''
+ use_ssl: false
+ # Settings for if you're using Redis Sentinels.
+ # If you're not sure what this is, please ignore this section.
+ sentinel:
+ master_name: ''
+ # List of host:port pairs
+ nodes: []
+ password: ''
+```
+
+
+
+### Credentials
+Enter the hostname, port, and default user password of your Redis server.
+
+If your Redis default user doesn't have a password, leave the password field blank (`password: ''`') and the plugin will attempt to connect without a password.
+
+### Default user password
+Depending on the version of Redis you've installed, Redis may or may not set a random default user password. Please check this in your Redis server config. You can clear the password of the default user with the below command in `redis-cli`.
+
+```bash
+requirepass thepassword
+user default on nopass ~* &* +@all
+```
+
+### Using Redis Sentinel
+If you're using [Redis Sentinel](https://redis.io/docs/latest/operate/oss_and_stack/management/sentinel/), set this up by filling out the properties under the `sentinel` subsection.
+
+You'll need to supply your master set name, your sentinel password, and a list of hosts/ports in the format `host:port`.
+
+## Getting a Redis Server
+A Redis server is not required to use HuskHomes, but we recommend it for better cross-server networking performance. A Redis server also lets you utilise cross-server RTP, which is not supported with the default plugin messaging protocol. Instructions for getting Redis on different servers are detailed below. HuskHomes is tested for the official Redis package, but should also work with Redis forks or other compatible software.
+
+For the best results, we recommend a Redis server with 1GB of RAM, hosted locally (on the same machine as all your other servers). If your setup has multiple machines, install Redis on the machine with your Velocity/BungeeCord/Waterfall proxy server.
+
+### If you're using a Minecraft server hosting provider
+Please contact your host's customer support and request Redis. You can direct them to this page if you wish. Looking for a Minecraft Server host that supports Redis? We maintain a list of [server hosts which offer Redis](https://william278.net/docs/website/redis-hosts).
+
+### Redis on Linux or macOS
+You can [install Redis](https://redis.io/docs/latest/operate/oss_and_stack/install/install-redis/install-redis-on-linux/) on your distribution of Linux. Redis is widely available on most package manager repositories.
+
+You can also [install Redis](https://redis.io/docs/latest/operate/oss_and_stack/install/install-redis/install-redis-on-mac-os/) on your macOS server.
+
+### Redis on Windows
+Redis isn't officially supported on Windows, but there's a number of [unofficial ports](https://github.com/tporadowski/redis/releases) you can install which work great and run Redis as a Windows service.
+
+You can also [install Redis via WSL](https://redis.io/docs/latest/operate/oss_and_stack/install/install-redis/install-redis-on-windows/) if you prefer.
+
+### Pterodactyl / Pelican panel hosts
+If you're self-hosting your server on a Pterodactyl or Pelican panel, you will already have Redis installed and can use this server for HuskHomes, too.
+
+If you are hosting your Redis server on the same node as your servers, you need to use `172.18.0.1` as your host (or equivalent if you changed your network settings), and bind it in the Redis config `nano /etc/redis/redis.conf`.
+
+You will also need to uncomment the `requirepass` directive and set a password to allow outside connections, or disable `protected-mode`. Once a password is set and Redis is restarted `systemctl restart redis`, you will also need to update the password in your pterodactyl `.env` (`nano /var/www/pterodactyl/.env`) and refresh the cache `cd /var/www/pterodactyl && php artisan config:clear`.
+
+You may also need to allow connections from your firewall depending on your Linux distribution.
\ No newline at end of file
diff --git a/docs/Setup.md b/docs/Setup.md
index 72686035..ad2ee4df 100644
--- a/docs/Setup.md
+++ b/docs/Setup.md
@@ -1,7 +1,7 @@
This will walk you through installing HuskHomes on your Spigot or Fabric server, or proxy network of servers.
## Requirements
-> **Note:** If the plugin fails to load, please check that you are not running an [incompatible version combination](Unsupported-Versions)
+> **Note:** If the plugin fails to load, please check that you are not running an [incompatible version combination](Compatibility)
* A Spigot (1.17.1+) or Fabric (latest Minecraft version) _Minecraft: Java Edition_ server running on Java 17+
* (For proxy network support) A proxy server (Velocity, BungeeCord) and MySQL (v8.0+)/MariaDB/PostgreSQL database
diff --git a/docs/_Sidebar.md b/docs/_Sidebar.md
index 38e62de4..16b21556 100644
--- a/docs/_Sidebar.md
+++ b/docs/_Sidebar.md
@@ -1,34 +1,39 @@
-## Guides
+## Setup
* π [[Setup]]
-* π [[Importing Data]]
+* πΎ [[Database]]
+* β¨ [[Redis]]
+* β οΈ [[Compatibility]]
* π [[Config Files]]
-* β [[Managing Access]]
-* π₯οΈ [[Commands]]
-* π [[Command Conflicts]]
-* βοΈ [[Troubleshooting]]
-* β [[FAQs]]
+* π [[Troubleshooting]]
-## Documentation
-* π [[Database]]
-* β
[[Redis Support]]
-* π [[Translations]]
+## Features
+* π₯οΈ [[Commands]]
* π© [[Plan Hook]]
* πΊοΈ [[Map Hooks]]
-* β° [[Cooldowns]]
* π΅ [[Economy Hook]]
* β οΈ [[Strict Tpahere]]
* π« [[Restricted Warps]]
-* ποΈ [[Global Respawning]]
+* β° [[Cooldowns]]
* π [[Global Spawn]]
+* ποΈ [[Global Respawning]]
+* β [[FAQs]]
+
+## Guides
+* π [[Importing Data]]
+* β [[Managing Access]]
+* π [[Command Conflicts]]
+* π [[Translations]]
* βοΈ [[Placeholders]]
-* πΈοΈ [[Legacy Migration]] (*v2 β v3*)
+* π [[Translations]]
+
+## Developers
* π¦ [[API]]
* π‘ [[API Examples]]
* β [[API Events]]
## Links
* π» [GitHub](https://github.com/WiIIiam278/HuskHomes)
-* π [Downloads](https://william278.net/project/huskhomes/)
+* π [Get HuskHomes](https://william278.net/project/huskhomes/)
* π§ [Modrinth](https://modrinth.com/plugin/huskhomes)
* π° [Spigot](https://www.spigotmc.org/resources/huskhomes.83767/)
* π [Polymart](https://polymart.org/resource/huskhomes.284/)