// 
// Decompiled by Procyon v0.6.0
// 

package com.hypixel.hytale.builtin.adventure.objectives.config.markerarea;

import com.hypixel.hytale.codec.Codec;
import com.hypixel.hytale.component.CommandBuffer;
import com.hypixel.hytale.server.core.universe.PlayerRef;
import com.hypixel.hytale.component.ComponentType;
import com.hypixel.hytale.math.vector.Vector3d;
import java.util.List;
import com.hypixel.hytale.server.core.universe.world.storage.EntityStore;
import com.hypixel.hytale.component.Ref;
import com.hypixel.hytale.component.spatial.SpatialResource;
import com.hypixel.hytale.math.shape.Box;
import javax.annotation.Nonnull;
import com.hypixel.hytale.codec.lookup.CodecMapCodec;

public abstract class ObjectiveLocationMarkerArea
{
    @Nonnull
    public static final CodecMapCodec<ObjectiveLocationMarkerArea> CODEC;
    protected Box entryAreaBox;
    protected Box exitAreaBox;
    
    public abstract void getPlayersInEntryArea(@Nonnull final SpatialResource<Ref<EntityStore>, EntityStore> p0, @Nonnull final List<Ref<EntityStore>> p1, @Nonnull final Vector3d p2);
    
    public abstract void getPlayersInExitArea(@Nonnull final SpatialResource<Ref<EntityStore>, EntityStore> p0, @Nonnull final List<Ref<EntityStore>> p1, @Nonnull final Vector3d p2);
    
    public abstract boolean hasPlayerInExitArea(@Nonnull final SpatialResource<Ref<EntityStore>, EntityStore> p0, @Nonnull final ComponentType<EntityStore, PlayerRef> p1, @Nonnull final Vector3d p2, @Nonnull final CommandBuffer<EntityStore> p3);
    
    public abstract boolean isPlayerInEntryArea(@Nonnull final Vector3d p0, @Nonnull final Vector3d p1);
    
    public Box getBoxForEntryArea() {
        return this.entryAreaBox;
    }
    
    public Box getBoxForExitArea() {
        return this.exitAreaBox;
    }
    
    @Nonnull
    public ObjectiveLocationMarkerArea getRotatedArea(final float yaw, final float pitch) {
        return this;
    }
    
    protected abstract void computeAreaBoxes();
    
    @Nonnull
    @Override
    public String toString() {
        return "ObjectiveLocationMarkerArea{, entryAreaBox=" + String.valueOf(this.entryAreaBox) + ", exitAreaBox=" + String.valueOf(this.exitAreaBox);
    }
    
    static {
        (CODEC = new CodecMapCodec<ObjectiveLocationMarkerArea>("Type")).register("Box", ObjectiveLocationAreaBox.class, ObjectiveLocationAreaBox.CODEC);
        ObjectiveLocationMarkerArea.CODEC.register("Radius", ObjectiveLocationAreaRadius.class, ObjectiveLocationAreaRadius.CODEC);
    }
}
