Commit Graph

69 Commits

Author SHA1 Message Date
Paul Reilly
98fb321685 Merge branch 'update/toml-json-config' into impl/tyr-backbone 2023-09-09 19:12:02 -05:00
Paul Reilly
df442ef4b0 Merge branch 'Implementations' into update/toml-json-config
# Conflicts:
#	Patchwork/src/main/java/fns/patchwork/config/Configuration.java
#	Veritas/src/main/java/fns/veritas/Aggregate.java
#	Veritas/src/main/java/fns/veritas/bukkit/ServerListener.java
#	Veritas/src/main/java/fns/veritas/client/BotClient.java
#	Veritas/src/main/java/fns/veritas/client/BotConfig.java
2023-09-09 19:11:19 -05:00
Paul Reilly
33731b611f Tyr Backbone Creation
# Changes:

## Patchwork
- Renamed FreedomExecutor to ExecutorProvider and moved the class to the provider package.
- Created an SQL Registry to prevent dependencies on Datura for SQL data. SQL is returned through an Optional, in the event that there is no SQL service registered.
- Created SQLResult, a generic ORM for ResultSets to avoid working directly with SQL data.

## Tyr
- Created Identity, which houses a username and related secret key.
- Created SQLEntry which stores the information from the Identity class into an SQL table called sessionData.
- Created TOTP, a simple static class that allows easy access to TimeBasedOneTimePasswordUtils class.
- Created OAuth2 which houses identities and performs the appropriate credential validations (incomplete)
2023-09-09 18:57:15 -05:00
Paul Reilly
85cc1f7ae0 Bot Command Implementation
# Changes:
- Added /ban <player> <reason> [duration] command. Bans a user on the server for the specified reason and duration (in minutes). If no duration is specified, the default is 5 minutes.

- Added /kick <player> <reason> command. Kicks a player on the server for the specified reason.

- Added /whisper <player> <message> command. Send a private message to a player on the server.
2023-09-04 22:57:36 -05:00
Paul Reilly
4681fc9596 Minor tweaks to GenericConfig & ContextProvider
# Changes:
- Changed Configuration#getList(String, Class) to Configuration#getCollection(String, Class)

- Renamed GenericConfiguration -> GenericConfig

- Implemented semantics for GenericConfig#getCollection and GenericConfig#getStringList

- Adjusted return value of ContextProvider#fromString to return Optional<T> instead of @Nullable T

- Adjusted classes which used previous API methods to use the newly updated ones.
2023-08-30 20:49:22 -05:00
Paldiu
7d5cb35e50
Fully implement Discord bot (#33)
* Fully implement Discord bot

* Fix plugin-yml plugin errors & switch to night-config

# Changes:
- Migrate from com.google.gson:gson and com.tomlj:tomlj over to com.electronwill.night-config:core, toml, and json
- Add the appropriate bukkit tags required by the minecrell/plugin-yml gradle plugin to Veritas and Tyr.

* Replace TOML wrapper with generic support

# Changes:
- Removed specific TOML wrapper in favor of GenericConfiguration.
- Added ConfigType enum to define configuration formats, parsers, and writers for TOML and JSON.
- Created FileUtils class containing useful file and directory creation methods
- Added @ApiStatus.Internal to both the BukkitDelegate class and Completions annotation to specify that they should not be used externally.
2023-08-29 17:32:13 -05:00
Paul Reilly
26f4e0746b Replace TOML wrapper with generic support
# Changes:
- Removed specific TOML wrapper in favor of GenericConfiguration.
- Added ConfigType enum to define configuration formats, parsers, and writers for TOML and JSON.
- Created FileUtils class containing useful file and directory creation methods
- Added @ApiStatus.Internal to both the BukkitDelegate class and Completions annotation to specify that they should not be used externally.
2023-08-28 21:52:40 -05:00
Paul Reilly
e71c167d5e Fix plugin-yml plugin errors & switch to night-config
# Changes:
- Migrate from com.google.gson:gson and com.tomlj:tomlj over to com.electronwill.night-config:core, toml, and json
- Add the appropriate bukkit tags required by the minecrell/plugin-yml gradle plugin to Veritas and Tyr.
2023-08-28 18:17:12 -05:00
Paul Reilly
51c96269d2 Merge remote-tracking branch 'origin/Implementations' into impl/discord-bot 2023-08-28 17:04:20 -05:00
Paul Reilly
c71ab845b9 Fully implement Discord bot 2023-08-28 01:53:48 -05:00
EnZaXD
b4c8e05310
Update license header (#32)
* Migrate license header to new organisation

* Thank you Intellij
2023-08-27 17:58:16 -05:00
Paul Reilly
a676207afa Add Veritas, Tyr, also other changes 2023-08-26 19:05:45 -05:00
Paldiu
8c36ecc4aa
Update plugin description and group id 2023-08-22 20:55:12 -05:00
allinkdev
18951fa120
Port to ClassGraph (#30)
* Port to ClassGraph

* Migrate to Minecrell plugin-yml

This allows us to load libraries at runtime instead of using shading & creating massive JAR files.

* Fix constructor modifiers of cake command

* Fix improper usage of CommandMap
2023-08-21 17:39:50 -05:00
Paul Reilly
305ebae9bf Attempt at fixing command registration
Signed-off-by: Paul Reilly <pawereus@gmail.com>
2023-08-11 15:58:40 -05:00
Paul Reilly
6ef6eacea0 Addressed requested changes
Signed-off-by: Paul Reilly <pawereus@gmail.com>
2023-08-11 15:26:26 -05:00
Paul Reilly
bbaa325ad6 Create Cladis (NetworkManager Hook)
Signed-off-by: Paul Reilly <pawereus@gmail.com>
2023-08-11 14:08:49 -05:00
allinkdev
8e5c52d0e8
Implement configuration system (#12)
* Return primitives in configuration interface where possible

This should save some unnecessary performance and memory overhead caused by the storage of object wrappers of the primitive types and the unboxing of those object wrappers into the wrapped primitive types when we try to do some primitive-exclusive operation.

I doubt that we'll be using the additional sugar methods that these wrappers provide most of the time, and if we need to we can just box the returned primitives.

* Mark returned lists in Configuration interface as Unmodifiable

I can't think of a use-case where we would want to modify the returned list from the Configuration interface we're accessing; however in case those situations do in-fact exist, I've made the decision to mark the return values of those methods as Unmodifiable so that there are no confusions in the future when the returned list throws an UnsupportedOperationException

* Provide class parameter in Configuration#getList

Otherwise, it's impossible to actually check if the on-disk configuration values are actually of the same type as/a subclass of what the plugin is expecting in the implementation.

* State that Configuration#getList will return an empty list if it fails

I don't think it would go particularly well if we were to return a list of Objects when we have a parameterized method. Additionally, how would components of the plugin respond to being given a list of Objects instead of whatever type they were expecting? This should be a better fail-safe solution compared to what we were previously going to do.

* Return an optional in Configuration#get if something went wrong

* Add class parameter to Configuration#get

* Update JavaDoc of Configuration#getList to reflect new parameter

* Remove final modifier from parameter

* Add class parameter to Configuration#getOrDefault

* Fix misspelled JavaDoc tag

* Partially implement a wrapper over FileConfiguration that implements our Configuration

* Fix codestyle violation

* Add copyright header & change package

* Add code for WrappedBukkitConfiguration#getList and WrappedBukkitConfiguration#get
2023-08-11 14:01:19 -05:00
EnZaXD
086e5ca72f
Added copyright notice to all class files (#23)
* Pushed copyright configuration to all classes

* Removed duplicated copyright headers
2023-08-11 19:41:38 +01:00
Eva
3e8c63221d
Overhaul of Patchwork and Registration system, fix-up for all plugin.yml files and removal of .negates(0 and .value() from DefaultNodes in turn for the .expiry() system removing the redundancies. (#21)
Co-authored-by: eva <66324759+evax64@users.noreply.github.com>
2023-08-11 13:15:36 -05:00
Paldiu
9bb7ebb770
Changed phrasing to match latest changes. 2023-08-06 17:07:49 -05:00
Paldiu
21463c50fe
Migrates the entire package nomenclature to be more direct and straightforward. (#17)
Signed-off-by: Paul Reilly <pawereus@gmail.com>
2023-08-01 22:34:18 -05:00
Paul Reilly
6842cb2792 Adjusted Command Processing
Completion annotations have been moved to top level, from per method, for a much clearer understanding of how the annotation should be used.
2023-07-23 02:15:12 -05:00
Paul Reilly
2b12f4eebb hotfixes 2023-06-25 21:46:01 -05:00
Paul Reilly
d0e8d6e361 pbs kids 2023-06-25 01:10:30 -05:00
Paul Reilly
fb97a8e65b updates 2023-06-21 15:45:55 -05:00
Paul Reilly
09699ccabb AdminChat 2023-06-20 09:24:28 -05:00
Paul Reilly
e18a0c0808 Minor fixes 2023-06-10 21:41:14 -05:00
Paul Reilly
a22f7fb215 Super edited with Notepad++ 2023-06-09 21:18:29 -05:00
Paul Reilly
de1da2bd61 Edited with Notepad++ 2023-06-09 21:17:42 -05:00
Paul Reilly
bacf6e8818 Beans 2023-06-09 21:11:36 -05:00
Paul Reilly
f459842eaf Some more updates 2023-06-09 14:15:53 -05:00
Paul Reilly
6631aebaa0 Merge branch 'kitchen-sink' into Displayable-GUI-API 2023-06-09 13:25:18 -05:00
Paul Reilly
09c511ef34 Additional documentation 2023-06-09 13:23:06 -05:00
Allink
6ccaf5eb25
Add documentation to economy-related interfaces 2023-06-09 17:24:12 +01:00
Paul Reilly
1ea106d999 Documentation, Add BouncyPads 2023-06-08 10:02:20 -05:00
Paul Reilly
27dafd69e6 Fixings! 2023-06-04 21:30:17 -05:00
Paldiu
6edf320bf7
Merge branch 'Displayable-GUI-API' into videos-stupid-contributions 2023-06-02 18:08:55 -05:00
Paul Reilly
e160868967 Reformatting 2023-06-02 17:58:08 -05:00
Video
ccb456ea0c Removes old unused UserData methods 2023-06-02 16:57:26 -06:00
Paul Reilly
bf2b48d670 Merge branch 'kitchen-sink' into Displayable-GUI-API 2023-06-02 17:11:20 -05:00
Paul Reilly
9481f88afd Update 2023-06-02 17:07:14 -05:00
Video
4ebeca9c73 Ports /cake over to Fossil and now every submodule has a plugin yml 2023-06-02 15:46:59 -06:00
Paul Reilly
a632eb778c Start implementations 2023-06-01 23:02:01 -05:00
Paul Reilly
def84bd747 updates 🎱 2023-05-30 17:39:54 -05:00
Paul Reilly
b95a06fa7c Start implementing GUI API 2023-05-25 13:13:32 -05:00
Paul Reilly
73d9f1e91d Create KyoriConstants.java
See docs for info
2023-05-24 21:10:59 -05:00
Paul Reilly
b9a5440733 Minor update 2023-05-23 17:11:08 -05:00
Paul Reilly
5f6e7a153e Slight bugfix, also more code spec alignment 2023-05-21 22:11:31 -05:00
Paul Reilly
faca73f99c Merge branch 'banning-update' of https://github.com/SimplexDevelopment/FreedomNetworkSuite into banning-update 2023-05-21 21:47:54 -05:00