Minebench / Tresor

An experimental VaultAPI compatible abstraction layer for Bukkit/Spigot/Paper plugins
https://ci.minebench.de/job/Tresor/
GNU General Public License v3.0
8 stars 3 forks source link

Added hologram service and DecentHolograms provider #25

Closed IllusionTheDev closed 7 months ago

IllusionTheDev commented 7 months ago

I created a basic hologram API. Might need some work (namedly documentation), and integrating a native hologram provider

Closes https://github.com/Minebench/Tresor/issues/22


IssueHunt Summary ### Referenced issues This pull request has been submitted to: - [#22: Holograms](https://oss.issuehunt.io/repos/121785670/issues/22) ---
IllusionTheDev commented 7 months ago

@Phoenix616 I've gone ahead and pushed the changes you requested. I'm a bit conflicted between putting the features enum in the Hologram itself or in the Holograms class.

Phoenix616 commented 7 months ago

Thank you, I will take a look at them.

And yeah, that is indeed a good question... I kinda feel like it needs to be in both as someone might be referencing holograms from different plugins in the same context without keeping track which hologram stems from which provider and someone might want to select only a provider based on certain features.

Granted these use cases would probably not be common but using them in parallel is technically supported by service providers.

Alternatively I guess you could add a getProvider method to the Hologram class? Then the Feature check wouldn't need to be duplicated.

IllusionTheDev commented 7 months ago

I believe the commit above should address the ideal scenario.

Phoenix616 commented 7 months ago

Thanks again :) Added some quick documentation too and some minor things I noticed.