Go to file
Christian Koop 638b793040
Introduce a new hook system (right now only with Hologram support)
My plans with this hook system are to make it easier to understand and maintain – Hopefully it is also more flexible

Hooks now have a dedicated activation-life-cycle – I think this allows it to contain all the logic to do what
it needs to do but also provide some helper methods like `#canBeActivated`.
The activation should be used by the hooks to reduce the memory and performancec impact when not used.
The de-activation also allows hooks to clean up themselves and not rely on the plugins used by the hook or
the plugin using the hook to clean up.

For example:
You can see that the `DecentHologramsHook` has few class variables and they are kept as
small as possible and reasonable when not activated.
In `#deactivate` I call `#removeAll` to remove all holograms that still exist and I call `ArrayList#trimToSize` to reduce it's size again.
This has a similar effect to setting the class varaible null or to a new List but with this I can make that field *final*.

The exact implementation details and capabilities vary on the third-party plugins being supported by hooks,
so it needs to be flexible and easy to understand, so we can easily add support for more plugins and especially
new plugin categories like Maps (dynmap, BlueMap, PlexMap, ...).
2024-01-30 19:43:30 +01:00
.github Bump actions/upload-artifact from 3 to 4 (#90) 2024-01-01 14:04:04 +01:00
Compatibility chore: Updates XSeries to v9.8.0 for Spigot 1.20.4 compatibility 2023-12-12 14:27:33 +01:00
Core Introduce a new hook system (right now only with Hologram support) 2024-01-30 19:43:30 +01:00
NMS Compile v1_20_R3 nms module with Spigot 1.20.4 2023-12-10 17:45:57 +01:00
.editorconfig Update EditorConfig [DEV-2] 2021-10-30 14:10:22 +02:00
.gitignore Add dependencies for unit tests 2021-10-30 14:53:23 +02:00
LICENSE Switch LICENSE from GPLv3 to CC BY-NC-ND 4.0 2023-03-29 18:06:35 +02:00
pom.xml Use jitpack for libraryloader 2024-01-07 14:59:13 +01:00
README.md Rename Maven modules from SongodaCore to CraftaroCore 2023-06-11 00:37:11 +02:00

CraftaroCore

An elaborate multi functional general Spigot plugin compatibility core and general use API.

Discord Patreon
Build Latest version

Maven

Repository

<repository>
    <id>songoda-public</id>
    <url>https://repo.songoda.com/repository/public/</url>
</repository>

Artifact

<dependency>
  <groupId>com.songoda</groupId>
  <artifactId>SongodaCore</artifactId>
  <version>VERSION</version>
</dependency>

Gradle

Repository

repositories {
    maven {
        url 'https://repo.songoda.com/repository/public/'
    }
}

Artifact

dependencies {
    compileOnly 'com.songoda:SongodaCore:VERSION'
}