Search in sources :

Example 6 with WorldXYZ

use of com.github.sirblobman.api.object.WorldXYZ in project CombatLogX by SirBlobman.

the class ListenerForceField method safeRemoveForceField.

private void safeRemoveForceField(Player player) {
    UUID uuid = player.getUniqueId();
    if (!this.fakeBlockMap.containsKey(uuid)) {
        return;
    }
    Set<WorldXYZ> oldArea = new HashSet<>(this.fakeBlockMap.remove(uuid));
    for (WorldXYZ worldXYZ : oldArea) {
        Location location = worldXYZ.asLocation();
        if (location != null)
            resetBlock(player, location);
    }
}
Also used : WorldXYZ(com.github.sirblobman.api.object.WorldXYZ) UUID(java.util.UUID) HashSet(java.util.HashSet) Location(org.bukkit.Location)

Aggregations

WorldXYZ (com.github.sirblobman.api.object.WorldXYZ)6 UUID (java.util.UUID)5 Location (org.bukkit.Location)4 HashSet (java.util.HashSet)3 ProtectedItem (combatlogx.expansion.loot.protection.object.ProtectedItem)2 World (org.bukkit.World)2 Item (org.bukkit.entity.Item)2 EventHandler (org.bukkit.event.EventHandler)2 ItemStack (org.bukkit.inventory.ItemStack)2 ConfigurationManager (com.github.sirblobman.api.configuration.ConfigurationManager)1 PlayerDataManager (com.github.sirblobman.api.configuration.PlayerDataManager)1 Replacer (com.github.sirblobman.api.language.Replacer)1 ICombatLogX (com.github.sirblobman.combatlogx.api.ICombatLogX)1 PlayerPunishEvent (com.github.sirblobman.combatlogx.api.event.PlayerPunishEvent)1 PlayerUntagEvent (com.github.sirblobman.combatlogx.api.event.PlayerUntagEvent)1 Expansion (com.github.sirblobman.combatlogx.api.expansion.Expansion)1 ExpansionListener (com.github.sirblobman.combatlogx.api.expansion.ExpansionListener)1 IDeathListener (com.github.sirblobman.combatlogx.api.listener.IDeathListener)1 TagType (com.github.sirblobman.combatlogx.api.object.TagType)1 UntagReason (com.github.sirblobman.combatlogx.api.object.UntagReason)1