001 package net.minecraft.src; 002 003 public enum EnumCreatureType 004 { 005 monster(IMob.class, 70, Material.air, false, false), 006 creature(EntityAnimal.class, 10, Material.air, true, true), 007 ambient(EntityAmbientCreature.class, 15, Material.air, true, false), 008 waterCreature(EntityWaterMob.class, 5, Material.water, true, false); 009 010 /** 011 * The root class of creatures associated with this EnumCreatureType (IMobs for aggressive creatures, EntityAnimals 012 * for friendly ones) 013 */ 014 private final Class creatureClass; 015 private final int maxNumberOfCreature; 016 private final Material creatureMaterial; 017 018 /** A flag indicating whether this creature type is peaceful. */ 019 private final boolean isPeacefulCreature; 020 021 /** Whether this creature type is an animal. */ 022 private final boolean isAnimal; 023 024 private EnumCreatureType(Class par3Class, int par4, Material par5Material, boolean par6, boolean par7) 025 { 026 this.creatureClass = par3Class; 027 this.maxNumberOfCreature = par4; 028 this.creatureMaterial = par5Material; 029 this.isPeacefulCreature = par6; 030 this.isAnimal = par7; 031 } 032 033 public Class getCreatureClass() 034 { 035 return this.creatureClass; 036 } 037 038 public int getMaxNumberOfCreature() 039 { 040 return this.maxNumberOfCreature; 041 } 042 043 public Material getCreatureMaterial() 044 { 045 return this.creatureMaterial; 046 } 047 048 /** 049 * Gets whether or not this creature type is peaceful. 050 */ 051 public boolean getPeacefulCreature() 052 { 053 return this.isPeacefulCreature; 054 } 055 056 /** 057 * Return whether this creature type is an animal. 058 */ 059 public boolean getAnimal() 060 { 061 return this.isAnimal; 062 } 063 }