当前位置: 首页>>代码示例>>Java>>正文


Java EntitySpectralArrow类代码示例

本文整理汇总了Java中net.minecraft.entity.projectile.EntitySpectralArrow的典型用法代码示例。如果您正苦于以下问题:Java EntitySpectralArrow类的具体用法?Java EntitySpectralArrow怎么用?Java EntitySpectralArrow使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


EntitySpectralArrow类属于net.minecraft.entity.projectile包,在下文中一共展示了EntitySpectralArrow类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: func_190726_a

import net.minecraft.entity.projectile.EntitySpectralArrow; //导入依赖的package包/类
protected EntityArrow func_190726_a(float p_190726_1_)
{
    ItemStack itemstack = this.getItemStackFromSlot(EntityEquipmentSlot.OFFHAND);

    if (itemstack.getItem() == Items.SPECTRAL_ARROW)
    {
        EntitySpectralArrow entityspectralarrow = new EntitySpectralArrow(this.world, this);
        entityspectralarrow.func_190547_a(this, p_190726_1_);
        return entityspectralarrow;
    }
    else
    {
        EntityArrow entityarrow = super.func_190726_a(p_190726_1_);

        if (itemstack.getItem() == Items.TIPPED_ARROW && entityarrow instanceof EntityTippedArrow)
        {
            ((EntityTippedArrow)entityarrow).setPotionEffect(itemstack);
        }

        return entityarrow;
    }
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:23,代码来源:EntitySkeleton.java

示例2: getArrow

import net.minecraft.entity.projectile.EntitySpectralArrow; //导入依赖的package包/类
protected EntityArrow getArrow(float distanceFactor) {
	ItemStack arrowItem = this.getItemStackFromSlot(EntityEquipmentSlot.OFFHAND);

	if (arrowItem.getItem() == Items.SPECTRAL_ARROW) {
		EntitySpectralArrow entityspectralarrow = new EntitySpectralArrow(this.world, this);
		entityspectralarrow.setEnchantmentEffectsFromEntity(this, distanceFactor);
		return entityspectralarrow;
	} else {
		EntityTippedArrow entityarrow = new EntityTippedArrow(this.world, this);
		entityarrow.setEnchantmentEffectsFromEntity(this, distanceFactor);

		if (arrowItem.getItem() == Items.TIPPED_ARROW)
			entityarrow.setPotionEffect(arrowItem);

		return entityarrow;
	}
}
 
开发者ID:The-Fireplace-Minecraft-Mods,项目名称:Overlord,代码行数:18,代码来源:EntityConvertedSkeleton.java

示例3: getArrow

import net.minecraft.entity.projectile.EntitySpectralArrow; //导入依赖的package包/类
protected EntityArrow getArrow(float distanceFactor) {
	ItemStack arrowStack = this.getItemStackFromSlot(EntityEquipmentSlot.OFFHAND);

	if (arrowStack.getItem() == Items.SPECTRAL_ARROW) {
		EntitySpectralArrow entityspectralarrow = new EntitySpectralArrow(this.world, this);
		entityspectralarrow.setEnchantmentEffectsFromEntity(this, distanceFactor);
		return entityspectralarrow;
	} else {
		EntityTippedArrow entityarrow = new EntityTippedArrow(this.world, this);
		entityarrow.setEnchantmentEffectsFromEntity(this, distanceFactor);

		if (arrowStack.getItem() == Items.TIPPED_ARROW)
			entityarrow.setPotionEffect(arrowStack);

		return entityarrow;
	}
}
 
开发者ID:The-Fireplace-Minecraft-Mods,项目名称:Overlord,代码行数:18,代码来源:EntitySkeletonWarrior.java

示例4: preInit

import net.minecraft.entity.projectile.EntitySpectralArrow; //导入依赖的package包/类
@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event) {
    logger = event.getModLog();
    knightArmourMaterial = EnumHelper.addArmorMaterial("knights.armour", "battlegear2:knight", 25, new int[]{3, 5, 7, 3}, 15, SoundEvents.ITEM_ARMOR_EQUIP_IRON, 1.5F);
    ResourceLocation sound = new ResourceLocation(MODID, "shield");
    shieldSound = GameRegistry.register(new SoundEvent(sound).setRegistryName(sound));
    BattlegearConfig.getConfig(new Configuration(event.getSuggestedConfigurationFile()));

    if((event.getSourceFile().getName().endsWith(".jar") || debug) && event.getSide().isClient()){
        try {
            Class.forName("mods.mud.ModUpdateDetector").getDeclaredMethod("registerMod", ModContainer.class, String.class, String.class).invoke(null,
                    FMLCommonHandler.instance().findContainerFor(this),
                    "https://raw.github.com/Mine-and-blade-admin/Battlegear2/master/battlegear_update.xml",
                    "https://raw.github.com/Mine-and-blade-admin/Battlegear2/master/changelog.md"
            );
        } catch (Throwable e) {
            e.printStackTrace();
        }
    }
    proxy.registerHandlers();
    QuiverArrowRegistry.addArrowToRegistry(Items.ARROW, EntityTippedArrow.class);
    QuiverArrowRegistry.addArrowToRegistry(Items.TIPPED_ARROW, EntityTippedArrow.class);
    QuiverArrowRegistry.addArrowToRegistry(Items.SPECTRAL_ARROW, EntitySpectralArrow.class);
    //Fetch early messages
    IMCEvent imc = new IMCEvent();
    imc.applyModContainer(FMLCommonHandler.instance().findContainerFor(MODID));
    onMessage(imc);
}
 
开发者ID:Mine-and-blade-admin,项目名称:Battlegear2,代码行数:29,代码来源:Battlegear.java

示例5: createArrow

import net.minecraft.entity.projectile.EntitySpectralArrow; //导入依赖的package包/类
public EntityArrow createArrow(World worldIn, ItemStack stack, EntityLivingBase shooter)
{
    return new EntitySpectralArrow(worldIn, shooter);
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:5,代码来源:ItemSpectralArrow.java

示例6: getEntityTexture

import net.minecraft.entity.projectile.EntitySpectralArrow; //导入依赖的package包/类
/**
 * Returns the location of an entity's texture. Doesn't seem to be called unless you call Render.bindEntityTexture.
 */
protected ResourceLocation getEntityTexture(EntitySpectralArrow entity)
{
    return RES_SPECTRAL_ARROW;
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:8,代码来源:RenderSpectralArrow.java

示例7: RenderManager

import net.minecraft.entity.projectile.EntitySpectralArrow; //导入依赖的package包/类
public RenderManager(TextureManager renderEngineIn, RenderItem itemRendererIn)
{
    this.renderEngine = renderEngineIn;
    this.entityRenderMap.put(EntityCaveSpider.class, new RenderCaveSpider(this));
    this.entityRenderMap.put(EntitySpider.class, new RenderSpider(this));
    this.entityRenderMap.put(EntityPig.class, new RenderPig(this, new ModelPig(), 0.7F));
    this.entityRenderMap.put(EntitySheep.class, new RenderSheep(this, new ModelSheep2(), 0.7F));
    this.entityRenderMap.put(EntityCow.class, new RenderCow(this, new ModelCow(), 0.7F));
    this.entityRenderMap.put(EntityMooshroom.class, new RenderMooshroom(this, new ModelCow(), 0.7F));
    this.entityRenderMap.put(EntityWolf.class, new RenderWolf(this, new ModelWolf(), 0.5F));
    this.entityRenderMap.put(EntityChicken.class, new RenderChicken(this, new ModelChicken(), 0.3F));
    this.entityRenderMap.put(EntityOcelot.class, new RenderOcelot(this, new ModelOcelot(), 0.4F));
    this.entityRenderMap.put(EntityRabbit.class, new RenderRabbit(this, new ModelRabbit(), 0.3F));
    this.entityRenderMap.put(EntitySilverfish.class, new RenderSilverfish(this));
    this.entityRenderMap.put(EntityEndermite.class, new RenderEndermite(this));
    this.entityRenderMap.put(EntityCreeper.class, new RenderCreeper(this));
    this.entityRenderMap.put(EntityEnderman.class, new RenderEnderman(this));
    this.entityRenderMap.put(EntitySnowman.class, new RenderSnowMan(this));
    this.entityRenderMap.put(EntitySkeleton.class, new RenderSkeleton(this));
    this.entityRenderMap.put(EntityWitch.class, new RenderWitch(this));
    this.entityRenderMap.put(EntityBlaze.class, new RenderBlaze(this));
    this.entityRenderMap.put(EntityPigZombie.class, new RenderPigZombie(this));
    this.entityRenderMap.put(EntityZombie.class, new RenderZombie(this));
    this.entityRenderMap.put(EntitySlime.class, new RenderSlime(this, new ModelSlime(16), 0.25F));
    this.entityRenderMap.put(EntityMagmaCube.class, new RenderMagmaCube(this));
    this.entityRenderMap.put(EntityGiantZombie.class, new RenderGiantZombie(this, new ModelZombie(), 0.5F, 6.0F));
    this.entityRenderMap.put(EntityGhast.class, new RenderGhast(this));
    this.entityRenderMap.put(EntitySquid.class, new RenderSquid(this, new ModelSquid(), 0.7F));
    this.entityRenderMap.put(EntityVillager.class, new RenderVillager(this));
    this.entityRenderMap.put(EntityIronGolem.class, new RenderIronGolem(this));
    this.entityRenderMap.put(EntityBat.class, new RenderBat(this));
    this.entityRenderMap.put(EntityGuardian.class, new RenderGuardian(this));
    this.entityRenderMap.put(EntityShulker.class, new RenderShulker(this, new ModelShulker()));
    this.entityRenderMap.put(EntityPolarBear.class, new RenderPolarBear(this, new ModelPolarBear(), 0.7F));
    this.entityRenderMap.put(EntityDragon.class, new RenderDragon(this));
    this.entityRenderMap.put(EntityEnderCrystal.class, new RenderEnderCrystal(this));
    this.entityRenderMap.put(EntityWither.class, new RenderWither(this));
    this.entityRenderMap.put(Entity.class, new RenderEntity(this));
    this.entityRenderMap.put(EntityPainting.class, new RenderPainting(this));
    this.entityRenderMap.put(EntityItemFrame.class, new RenderItemFrame(this, itemRendererIn));
    this.entityRenderMap.put(EntityLeashKnot.class, new RenderLeashKnot(this));
    this.entityRenderMap.put(EntityTippedArrow.class, new RenderTippedArrow(this));
    this.entityRenderMap.put(EntitySpectralArrow.class, new RenderSpectralArrow(this));
    this.entityRenderMap.put(EntitySnowball.class, new RenderSnowball(this, Items.SNOWBALL, itemRendererIn));
    this.entityRenderMap.put(EntityEnderPearl.class, new RenderSnowball(this, Items.ENDER_PEARL, itemRendererIn));
    this.entityRenderMap.put(EntityEnderEye.class, new RenderSnowball(this, Items.ENDER_EYE, itemRendererIn));
    this.entityRenderMap.put(EntityEgg.class, new RenderSnowball(this, Items.EGG, itemRendererIn));
    this.entityRenderMap.put(EntityPotion.class, new RenderPotion(this, itemRendererIn));
    this.entityRenderMap.put(EntityExpBottle.class, new RenderSnowball(this, Items.EXPERIENCE_BOTTLE, itemRendererIn));
    this.entityRenderMap.put(EntityFireworkRocket.class, new RenderSnowball(this, Items.FIREWORKS, itemRendererIn));
    this.entityRenderMap.put(EntityLargeFireball.class, new RenderFireball(this, 2.0F));
    this.entityRenderMap.put(EntitySmallFireball.class, new RenderFireball(this, 0.5F));
    this.entityRenderMap.put(EntityDragonFireball.class, new RenderDragonFireball(this));
    this.entityRenderMap.put(EntityWitherSkull.class, new RenderWitherSkull(this));
    this.entityRenderMap.put(EntityShulkerBullet.class, new RenderShulkerBullet(this));
    this.entityRenderMap.put(EntityItem.class, new RenderEntityItem(this, itemRendererIn));
    this.entityRenderMap.put(EntityXPOrb.class, new RenderXPOrb(this));
    this.entityRenderMap.put(EntityTNTPrimed.class, new RenderTNTPrimed(this));
    this.entityRenderMap.put(EntityFallingBlock.class, new RenderFallingBlock(this));
    this.entityRenderMap.put(EntityArmorStand.class, new RenderArmorStand(this));
    this.entityRenderMap.put(EntityMinecartTNT.class, new RenderTntMinecart(this));
    this.entityRenderMap.put(EntityMinecartMobSpawner.class, new RenderMinecartMobSpawner(this));
    this.entityRenderMap.put(EntityMinecart.class, new RenderMinecart(this));
    this.entityRenderMap.put(EntityBoat.class, new RenderBoat(this));
    this.entityRenderMap.put(EntityFishHook.class, new RenderFish(this));
    this.entityRenderMap.put(EntityAreaEffectCloud.class, new RenderAreaEffectCloud(this));
    this.entityRenderMap.put(EntityHorse.class, new RenderHorse(this, new ModelHorse(), 0.75F));
    this.entityRenderMap.put(EntityLightningBolt.class, new RenderLightningBolt(this));
    this.playerRenderer = new RenderPlayer(this);
    this.skinMap.put("default", this.playerRenderer);
    this.skinMap.put("slim", new RenderPlayer(this, true));
    net.minecraftforge.fml.client.registry.RenderingRegistry.loadEntityRenderers(this, this.entityRenderMap);
}
 
开发者ID:F1r3w477,项目名称:CustomWorldGen,代码行数:74,代码来源:RenderManager.java

示例8: createFixer

import net.minecraft.entity.projectile.EntitySpectralArrow; //导入依赖的package包/类
public static DataFixer createFixer()
{
    DataFixer datafixer = new DataFixer(512);
    WorldInfo.registerFixes(datafixer);
    EntityPlayer.registerFixesPlayer(datafixer);
    AnvilChunkLoader.registerFixes(datafixer);
    ItemStack.registerFixes(datafixer);
    EntityArmorStand.registerFixesArmorStand(datafixer);
    EntityArrow.registerFixesArrow(datafixer);
    EntityBat.registerFixesBat(datafixer);
    EntityBlaze.registerFixesBlaze(datafixer);
    EntityCaveSpider.registerFixesCaveSpider(datafixer);
    EntityChicken.registerFixesChicken(datafixer);
    EntityCow.registerFixesCow(datafixer);
    EntityCreeper.registerFixesCreeper(datafixer);
    EntityDragonFireball.registerFixesDragonFireball(datafixer);
    EntityDragon.registerFixesDragon(datafixer);
    EntityEnderman.registerFixesEnderman(datafixer);
    EntityEndermite.registerFixesEndermite(datafixer);
    EntityFallingBlock.registerFixesFallingBlock(datafixer);
    EntityLargeFireball.registerFixesLargeFireball(datafixer);
    EntityFireworkRocket.registerFixesFireworkRocket(datafixer);
    EntityGhast.registerFixesGhast(datafixer);
    EntityGiantZombie.registerFixesGiantZombie(datafixer);
    EntityGuardian.registerFixesGuardian(datafixer);
    EntityHorse.registerFixesHorse(datafixer);
    EntityItem.registerFixesItem(datafixer);
    EntityItemFrame.registerFixesItemFrame(datafixer);
    EntityMagmaCube.registerFixesMagmaCube(datafixer);
    EntityMinecartChest.registerFixesMinecartChest(datafixer);
    EntityMinecartCommandBlock.registerFixesMinecartCommand(datafixer);
    EntityMinecartFurnace.registerFixesMinecartFurnace(datafixer);
    EntityMinecartHopper.registerFixesMinecartHopper(datafixer);
    EntityMinecartEmpty.registerFixesMinecartEmpty(datafixer);
    EntityMinecartMobSpawner.registerFixesMinecartMobSpawner(datafixer);
    EntityMinecartTNT.registerFixesMinecartTNT(datafixer);
    EntityLiving.registerFixesMob(datafixer);
    EntityMob.registerFixesMonster(datafixer);
    EntityMooshroom.registerFixesMooshroom(datafixer);
    EntityOcelot.registerFixesOcelot(datafixer);
    EntityPig.registerFixesPig(datafixer);
    EntityPigZombie.registerFixesPigZombie(datafixer);
    EntityRabbit.registerFixesRabbit(datafixer);
    EntitySheep.registerFixesSheep(datafixer);
    EntityShulker.registerFixesShulker(datafixer);
    EntitySilverfish.registerFixesSilverfish(datafixer);
    EntitySkeleton.registerFixesSkeleton(datafixer);
    EntitySlime.registerFixesSlime(datafixer);
    EntitySmallFireball.registerFixesSmallFireball(datafixer);
    EntitySnowman.registerFixesSnowman(datafixer);
    EntitySnowball.registerFixesSnowball(datafixer);
    EntitySpectralArrow.registerFixesSpectralArrow(datafixer);
    EntitySpider.registerFixesSpider(datafixer);
    EntitySquid.registerFixesSquid(datafixer);
    EntityEgg.registerFixesEgg(datafixer);
    EntityEnderPearl.registerFixesEnderPearl(datafixer);
    EntityExpBottle.registerFixesExpBottle(datafixer);
    EntityPotion.registerFixesPotion(datafixer);
    EntityTippedArrow.registerFixesTippedArrow(datafixer);
    EntityVillager.registerFixesVillager(datafixer);
    EntityIronGolem.registerFixesIronGolem(datafixer);
    EntityWitch.registerFixesWitch(datafixer);
    EntityWither.registerFixesWither(datafixer);
    EntityWitherSkull.registerFixesWitherSkull(datafixer);
    EntityWolf.registerFixesWolf(datafixer);
    EntityZombie.registerFixesZombie(datafixer);
    TileEntityPiston.registerFixesPiston(datafixer);
    TileEntityFlowerPot.registerFixesFlowerPot(datafixer);
    TileEntityFurnace.registerFixesFurnace(datafixer);
    TileEntityChest.registerFixesChest(datafixer);
    TileEntityDispenser.registerFixes(datafixer);
    TileEntityDropper.registerFixesDropper(datafixer);
    TileEntityBrewingStand.registerFixesBrewingStand(datafixer);
    TileEntityHopper.registerFixesHopper(datafixer);
    BlockJukebox.registerFixesJukebox(datafixer);
    TileEntityMobSpawner.registerFixesMobSpawner(datafixer);
    registerFixes(datafixer);
    return datafixer;
}
 
开发者ID:F1r3w477,项目名称:CustomWorldGen,代码行数:80,代码来源:DataFixesManager.java


注:本文中的net.minecraft.entity.projectile.EntitySpectralArrow类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。