Core/src/main/java/eu/univento/core/api/gui/hologram/components/StationaryPlayerGUIPage.java

42 lines
1.2 KiB
Java

/*
* Copyright (c) 2017 univento.eu - All rights reserved
* You are not allowed to use, distribute or modify this code
*/
package eu.univento.core.api.gui.hologram.components;
import eu.univento.core.api.player.CustomPlayer;
import lombok.Getter;
import org.bukkit.Location;
import java.util.HashMap;
/**
* @author joethei
* @version 0.1
*/
public class StationaryPlayerGUIPage extends PlayerGUIPage{
@Getter
private String stationaryDisplayID;
public StationaryPlayerGUIPage(CustomPlayer player, HashMap<String, PlayerGUIComponent> components, Location location, GUIPage page, String param) {
super(player, components, location, page);
this.stationaryDisplayID = param;
}
public void renderComponents() {
for(PlayerGUIComponent component : components.values()) {
component.spawnEntities(location, true);
}
}
public boolean equals(Object object) {
if((object instanceof StationaryPlayerGUIPage)) {
StationaryPlayerGUIPage page = (StationaryPlayerGUIPage) object;
return page.getPage().getId().equals(this.getPage().getId());
}
return false;
}
}