001/* 002 * PlotSquared, a land and world management plugin for Minecraft. 003 * Copyright (C) IntellectualSites <https://intellectualsites.com> 004 * Copyright (C) IntellectualSites team and contributors 005 * 006 * This program is free software: you can redistribute it and/or modify 007 * it under the terms of the GNU General Public License as published by 008 * the Free Software Foundation, either version 3 of the License, or 009 * (at your option) any later version. 010 * 011 * This program is distributed in the hope that it will be useful, 012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 014 * GNU General Public License for more details. 015 * 016 * You should have received a copy of the GNU General Public License 017 * along with this program. If not, see <https://www.gnu.org/licenses/>. 018 */ 019package com.plotsquared.core.util.entity; 020 021import com.plotsquared.core.PlotSquared; 022 023/** 024 * A collection of {@link EntityCategory entity categories} 025 */ 026public class EntityCategories { 027 028 public static final int CAP_ENTITY = 0; 029 public static final int CAP_ANIMAL = 1; 030 public static final int CAP_MONSTER = 2; 031 public static final int CAP_MOB = 3; 032 public static final int CAP_VEHICLE = 4; 033 public static final int CAP_MISC = 5; 034 035 public static final EntityCategory ANIMAL = register("animal"); 036 public static final EntityCategory TAMEABLE = register("tameable"); 037 public static final EntityCategory VEHICLE = register("vehicle"); 038 public static final EntityCategory HOSTILE = register("hostile"); 039 public static final EntityCategory HANGING = register("hanging"); 040 public static final EntityCategory VILLAGER = register("villager"); 041 public static final EntityCategory PROJECTILE = register("projectile"); 042 public static final EntityCategory OTHER = register("other"); 043 public static final EntityCategory PLAYER = register("player"); 044 045 public static EntityCategory register(final String id) { 046 final EntityCategory entityCategory = new EntityCategory(PlotSquared.platform().worldUtil(), id); 047 EntityCategory.REGISTRY.register(entityCategory.getId(), entityCategory); 048 return entityCategory; 049 } 050 051 public static void init() { 052 } 053 054}