mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2025-06-25 10:14:42 +02:00
Get placeholders working
This commit is contained in:
@ -270,6 +270,11 @@ public interface IPlotMain<P> extends ILogger {
|
||||
*/
|
||||
void registerWorldEvents();
|
||||
|
||||
/**
|
||||
* Register events related to the server
|
||||
*/
|
||||
void registerServerEvents();
|
||||
|
||||
/**
|
||||
* Usually HybridGen
|
||||
*
|
||||
|
@ -262,6 +262,7 @@ public class PlotSquared {
|
||||
this.IMP.registerPlayerEvents();
|
||||
}
|
||||
// Required
|
||||
this.IMP.registerServerEvents();
|
||||
this.IMP.registerWorldEvents();
|
||||
if (Settings.Enabled_Components.CHUNK_PROCESSOR) {
|
||||
this.IMP.registerChunkProcessor();
|
||||
|
@ -159,7 +159,7 @@ public final class PlaceholderRegistry {
|
||||
final Placeholder previous = this.placeholders
|
||||
.put(placeholder.getKey().toLowerCase(Locale.ENGLISH),
|
||||
Preconditions.checkNotNull(placeholder, "Placeholder may not be null"));
|
||||
if (previous != null) {
|
||||
if (previous == null) {
|
||||
this.eventDispatcher.callGenericEvent(new PlaceholderAddedEvent(placeholder));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user