本文整理匯總了Java中net.minecraft.entity.monster.EntitySpider類的典型用法代碼示例。如果您正苦於以下問題:Java EntitySpider類的具體用法?Java EntitySpider怎麽用?Java EntitySpider使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
EntitySpider類屬於net.minecraft.entity.monster包,在下文中一共展示了EntitySpider類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: loadEntityShader
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
/**
* What shader to use when spectating this entity
*/
public void loadEntityShader(Entity entityIn)
{
if (OpenGlHelper.shadersSupported)
{
if (this.theShaderGroup != null)
{
this.theShaderGroup.deleteShaderGroup();
}
this.theShaderGroup = null;
if (entityIn instanceof EntityCreeper)
{
this.loadShader(new ResourceLocation("shaders/post/creeper.json"));
}
else if (entityIn instanceof EntitySpider)
{
this.loadShader(new ResourceLocation("shaders/post/spider.json"));
}
else if (entityIn instanceof EntityEnderman)
{
this.loadShader(new ResourceLocation("shaders/post/invert.json"));
}
}
}
示例2: loadEntityShader
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
/**
* What shader to use when spectating this entity
*/
public void loadEntityShader(Entity entityIn) {
if (OpenGlHelper.shadersSupported) {
if (this.theShaderGroup != null) {
this.theShaderGroup.deleteShaderGroup();
}
this.theShaderGroup = null;
if (entityIn instanceof EntityCreeper) {
this.loadShader(new ResourceLocation("shaders/post/creeper.json"));
} else if (entityIn instanceof EntitySpider) {
this.loadShader(new ResourceLocation("shaders/post/spider.json"));
} else if (entityIn instanceof EntityEnderman) {
this.loadShader(new ResourceLocation("shaders/post/invert.json"));
}
}
}
示例3: onEntityKilled
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
@SubscribeEvent
public void onEntityKilled(LivingDropsEvent event)
{
// TODO remove when actual ark creatures are in place and dropping items
if (event.getEntityLiving().world.isRemote) return;
Random r = new Random();
int x = r.nextInt(3) + 1;
ItemStack meat = new ItemStack(ARKCraftItems.meat_raw, x);
event.getDrops().add(new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX, event.getEntityLiving().posY,
event.getEntityLiving().posZ, IDecayable.setDecayStart(meat, ARKCraft.proxy.getWorldTime())));
if (r.nextDouble() < 0.05) event.getDrops().add(new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX,
event.getEntityLiving().posY, event.getEntityLiving().posZ, IDecayable.setDecayStart(new ItemStack(
ARKCraftItems.primemeat_raw), ARKCraft.proxy.getWorldTime())));
if (event.getEntityLiving() instanceof EntitySpider || event.getEntityLiving() instanceof EntitySilverfish
|| event.getEntityLiving() instanceof EntityEndermite) event.getDrops().add(new EntityItem(
event.getEntityLiving().world, event.getEntityLiving().posX, event.getEntityLiving().posY,
event.getEntityLiving().posZ, new ItemStack(ARKCraftItems.chitin, r.nextInt(3) + 1)));
else event.getDrops().add(new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX,
event.getEntityLiving().posY, event.getEntityLiving().posZ, new ItemStack(ARKCraftItems.hide, r.nextInt(3) + 1)));
}
示例4: EntityRana
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public EntityRana(World par1World, int par2)
{
super(par1World);
randomTickDivider = 0;
isPlayingFlag = false;
villageObj = null;
setProfession(par2);
dead = false;
((PathNavigateGround)this.getNavigator()).setAvoidsWater(true);
tasks.addTask(0, new EntityAISwimming(this));
this.tasks.addTask(1, new EntityAIAvoidEntity(this, EntityZombie.class, 8.0F, 0.6D, 0.6D));
this.tasks.addTask(1, new EntityAIAvoidEntity(this, EntitySkeleton.class, 8.0F, 0.6D, 0.6D));
this.tasks.addTask(1, new EntityAIAvoidEntity(this, EntitySpider.class, 8.0F, 0.6D, 0.6D));
this.tasks.addTask(1, new EntityAIAvoidEntity(this, EntityTNTPrimed.class, 8.0F, 0.6D, 0.6D));
this.tasks.addTask(1, new EntityAIAvoidEntity(this, EntityCreeper.class, 8.0F, 0.6D, 0.6D));
tasks.addTask(5, new EntityAIMoveIndoors(this));
tasks.addTask(6, new EntityAIRestrictOpenDoor(this));
tasks.addTask(7, new EntityAIOpenDoor(this, true));
tasks.addTask(8, new EntityAIMoveTowardsRestriction(this, 0.3F));
tasks.addTask(9, new EntityAIWatchClosest2(this, net.minecraft.entity.player.EntityPlayer.class, 3F, 1.0F));
tasks.addTask(10, new EntityAIWatchClosest2(this, net.minecraft.entity.passive.EntityVillager.class, 5F, 0.02F));
tasks.addTask(11, new EntityAIWatchClosest2(this, com.stormister.rediscovered.EntityRana.class, 5F, 0.02F));
tasks.addTask(12, new EntityAIWatchClosest2(this, com.stormister.rediscovered.EntitySteve.class, 5F, 0.02F));
tasks.addTask(13, new EntityAIWander(this, 0.3F));
tasks.addTask(14, new EntityAIWatchClosest(this, net.minecraft.entity.EntityLiving.class, 8F));
}
示例5: BiomeGenCandy
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenCandy(int id){
super(id);
this.theBiomeDecorator.treesPerChunk = 6;
this.theBiomeDecorator.grassPerChunk = 2;
this.theBiomeDecorator.mushroomsPerChunk = 1;
setDisableRain();
setHeight(new BiomeGenBase.Height(1.5F, 0.5F));
this.spawnableCreatureList.clear();
this.spawnableCreatureList.add(new SpawnListEntry(EntityPeep.class, 10, 4, 4));
this.spawnableCreatureList.add(new SpawnListEntry(EntityUnicorn.class, 10, 4, 4));
this.spawnableCreatureList.add(new SpawnListEntry(EntityCandySheep.class, 10, 4, 4));
this.spawnableMonsterList.clear();
this.spawnableMonsterList.add(new SpawnListEntry(EntityCalavera.class, 100, 4, 4));
this.spawnableMonsterList.add(new SpawnListEntry(EntityZombie.class, 100, 4, 4));
this.spawnableMonsterList.add(new SpawnListEntry(EntityGingerbread.class, 100, 4, 6));
this.spawnableMonsterList.add(new SpawnListEntry(EntityCreeper.class, 100, 4, 4));
this.spawnableMonsterList.add(new SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new SpawnListEntry(EntityWitch.class, 10, 4, 4));
BiomeManager.addBiome(BiomeManager.BiomeType.WARM, new BiomeManager.BiomeEntry(this, Config.candyWeight));
BiomeDictionary.registerBiomeType(this, BiomeDictionary.Type.MAGICAL, BiomeDictionary.Type.MOUNTAIN, BiomeDictionary.Type.LUSH);
setBiomeName("Rock Candy Mountain");
setColor(0x8AFFF0);
this.waterColorMultiplier = 0x899CFF;
}
示例6: shouldRenderPass
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
/**
* Queries whether should render the specified pass or not.
*/
protected int shouldRenderPass(EntitySpider p_77032_1_, int p_77032_2_, float p_77032_3_)
{
this.bindTexture(herobrineEyesTexture);
GL11.glEnable(GL11.GL_BLEND);
GL11.glDisable(GL11.GL_ALPHA_TEST);
GL11.glBlendFunc(GL11.GL_ONE, GL11.GL_ONE);
if (p_77032_1_.isInvisible())
{
GL11.glDepthMask(false);
}
else
{
GL11.glDepthMask(true);
}
char c0 = 61680;
int j = c0 % 65536;
int k = c0 / 65536;
OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, (float) j / 1.0F, (float) k / 1.0F);
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
return 1;
}
示例7: getPossibleCreatures
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
@SuppressWarnings({"unchecked","rawtypes"})
@Override public List getPossibleCreatures(EnumCreatureType par1EnumCreatureType,int i,int j,int k){
if (par1EnumCreatureType == EnumCreatureType.monster)
{
List monsters=new ArrayList();
monsters.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 8, 2, 3));
monsters.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 8, 2, 3));
monsters.add(new BiomeGenBase.SpawnListEntry(EntitySkeleton.class, 8, 2, 3));
monsters.add(new BiomeGenBase.SpawnListEntry(EntityCreeper.class, 8, 2, 3));
monsters.add(new BiomeGenBase.SpawnListEntry(EntityEnderman.class, 8, 1, 3));
monsters.add(new BiomeGenBase.SpawnListEntry(EntityPixelOneSwingman.class, 1, 1, 1));
return monsters;
}
if (par1EnumCreatureType == EnumCreatureType.creature)
{
List creatures=new ArrayList();
creatures.add(new BiomeGenBase.SpawnListEntry(EntityhumanPixel.class, 8, 2, 3));
creatures.add(new BiomeGenBase.SpawnListEntry(EntitypixelPig.class, 8, 1, 3));
creatures.add(new BiomeGenBase.SpawnListEntry(EntitypixelCow.class, 8, 1, 3));
return creatures;
}
return null;
}
示例8: BiomeGenBlueTaiga
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenBlueTaiga(int p_i45385_1_, int p_i45385_2_)
{
super(p_i45385_1_);
this.field_150644_aH = p_i45385_2_;
this.spawnableMonsterList.clear();
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySkeleton.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySlime.class, 100, 4, 4));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityIceZertum.class, 20, 3, 4));
this.theBiomeDecorator.treesPerChunk = 10;
if (p_i45385_2_ != 1 && p_i45385_2_ != 2)
{
this.theBiomeDecorator.grassPerChunk = 1;
this.theBiomeDecorator.mushroomsPerChunk = 1;
}
else
{
this.theBiomeDecorator.grassPerChunk = 7;
this.theBiomeDecorator.deadBushPerChunk = 1;
this.theBiomeDecorator.mushroomsPerChunk = 3;
}
}
示例9: BiomeGenDestroZone
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenDestroZone(int par1)
{
super(par1);
this.topBlock = Blocks.sand;
this.fillerBlock = Blocks.sand;
this.waterColorMultiplier = 0x333333;
this.theBiomeDecorator.treesPerChunk = -999;
this.theBiomeDecorator.deadBushPerChunk = 2;
this.theBiomeDecorator.reedsPerChunk = 50;
this.theBiomeDecorator.cactiPerChunk = 10;
this.spawnableMonsterList.clear();
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityDestroZertum.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySkeleton.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySlime.class, 100, 4, 4));
}
示例10: BiomeGenRedSeed
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenRedSeed(int id) {
super(id);
this.waterColorMultiplier = 0x003333;
this.theBiomeDecorator.treesPerChunk = -999;
this.theBiomeDecorator.flowersPerChunk = 4;
this.theBiomeDecorator.grassPerChunk = 10;
this.flowers.clear();
this.addFlower(Blocks.red_flower, 4, 3);
this.addFlower(Blocks.red_flower, 5, 3);
this.addFlower(Blocks.red_flower, 6, 3);
this.addFlower(Blocks.red_flower, 7, 3);
this.addFlower(ModBlocks.nileBlackFlower, 0, 20);
this.addFlower(ModBlocks.nileBlackFlower, 3, 20);
this.addFlower(ModBlocks.nileBlackFlower, 8, 20);
this.addFlower(ModBlocks.nileBlackFlower, 0, 30);
this.spawnableMonsterList.clear();
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityHorse.class, 5, 2, 6));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityRedZertum.class, 100, 4, 4));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityChicken.class, 5, 1, 5));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityCow.class, 5, 1, 5));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityPig.class, 5, 1, 5));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySkeleton.class, 100, 4, 4));
}
示例11: BiomeGenBioZone
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenBioZone(int id) {
super(id);
this.theBiomeDecorator.generateLakes = true;
this.theBiomeDecorator.treesPerChunk = 4;
this.spawnableMonsterList.clear();
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySkeleton.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityCreeper.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySlime.class, 100, 4, 4));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityZertum.class, 100, 4, 4));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityBat.class, 5, 1, 5));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityChicken.class, 5, 1, 5));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityCow.class, 5, 1, 5));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityPig.class, 5, 1, 5));
}
示例12: BiomeGenNileMountains
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenNileMountains(int p_i45373_1_, boolean p_i45373_2_)
{
super(p_i45373_1_);
this.theWorldGenerator = new WorldGenMinable(Blocks.monster_egg, 8);
this.field_150634_aD = new WorldGenTaiga2(false);
this.field_150635_aE = 0;
this.field_150636_aF = 1;
this.field_150637_aG = 2;
this.field_150638_aH = this.field_150635_aE;
this.spawnableMonsterList.clear();
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySkeleton.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySlime.class, 100, 4, 4));
if (p_i45373_2_)
{
this.theBiomeDecorator.treesPerChunk = 3;
this.field_150638_aH = this.field_150636_aF;
}
}
示例13: BiomeGenNileSwamp
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenNileSwamp(int p_i1988_1_)
{
super(p_i1988_1_);
this.theBiomeDecorator.treesPerChunk = 2;
this.theBiomeDecorator.flowersPerChunk = 1;
this.theBiomeDecorator.deadBushPerChunk = 1;
this.theBiomeDecorator.mushroomsPerChunk = 8;
this.theBiomeDecorator.reedsPerChunk = 10;
this.theBiomeDecorator.clayPerChunk = 1;
this.theBiomeDecorator.waterlilyPerChunk = 4;
this.theBiomeDecorator.sandPerChunk2 = 0;
this.theBiomeDecorator.sandPerChunk = 0;
this.theBiomeDecorator.grassPerChunk = 5;
this.waterColorMultiplier = 14745518;
this.spawnableMonsterList.clear();
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityZertum.class, 100, 3, 4));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityForisZertum.class, 20, 3, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySkeleton.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySlime.class, 100, 4, 4));
this.flowers.clear();
this.addFlower(Blocks.red_flower, 1, 10);
this.addFlower(ModBlocks.nilePinkFlower, 1, 20);
}
示例14: BiomeGenDarkLand
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenDarkLand(int id) {
super(id);
this.waterColorMultiplier = 0x666600;
this.theBiomeDecorator.treesPerChunk = 1;
this.theBiomeDecorator.grassPerChunk = 1;
this.theBiomeDecorator.flowersPerChunk = -999;
this.theBiomeDecorator.generateLakes = true;
this.spawnableMonsterList.clear();
this.spawnableCreatureList.clear();
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityDarkZertum.class, 100, 4, 4));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityBat.class, 60, 1, 5));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityMagmaCube.class, 1, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityPigZombie.class, 20, 2, 3));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityGhast.class, 20, 1, 2));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityKurr.class, 10, 2, 2));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 100, 4, 4));
}
示例15: BiomeGenNileSavanna
import net.minecraft.entity.monster.EntitySpider; //導入依賴的package包/類
public BiomeGenNileSavanna(int p_i45383_1_)
{
super(p_i45383_1_);
this.theBiomeDecorator.treesPerChunk = 1;
this.theBiomeDecorator.flowersPerChunk = 4;
this.theBiomeDecorator.grassPerChunk = 20;
this.spawnableMonsterList.clear();
this.spawnableCreatureList.clear();
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityZertum.class, 100, 4, 4));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityKortor.class, 100, 2, 3));
this.spawnableCreatureList.add(new BiomeGenBase.SpawnListEntry(EntityPig.class, 5, 1, 5));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySpider.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityZombie.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntityCreeper.class, 100, 4, 4));
this.spawnableMonsterList.add(new BiomeGenBase.SpawnListEntry(EntitySkeleton.class, 100, 4, 4));
this.waterColorMultiplier = 0x0099cc;
}