mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-20 20:22:33 +00:00
Fix all remaining non-worldgen compile errors
This commit is contained in:
1 parent
d9f444eab4
commit
3eaf807132
7 files changed
+44
-42
No files matched your search
@@ -60,7 +60,7 @@ public final class BossBarHandler {
|
||||
int tx = c - mc.fontRenderer.func_238414_a_(name) / 2;
|
||||
|
||||
RenderSystem.color4f(1F, 1F, 1F, 1F);
|
||||
int auxHeight = currentBoss.bossBarRenderCallback(x, y);
|
||||
int auxHeight = currentBoss.bossBarRenderCallback(ms, x, y);
|
||||
RenderSystem.enableBlend();
|
||||
RenderSystem.blendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
|
||||
mc.textureManager.bindTexture(currentBoss.getBossBarTexture());
|
||||
|
||||
@@ -153,13 +153,14 @@ public class ClientProxy implements IProxy {
|
||||
}
|
||||
}
|
||||
|
||||
registerRenderTypes();
|
||||
|
||||
DeferredWorkQueue.runLater(() -> {
|
||||
CORPOREA_REQUEST = new KeyBinding("key.botania_corporea_request", KeyConflictContext.GUI, InputMappings.getInputByCode(GLFW.GLFW_KEY_C, 0), LibMisc.MOD_NAME);
|
||||
ClientRegistry.registerKeyBinding(ClientProxy.CORPOREA_REQUEST);
|
||||
registerPropertyGetters();
|
||||
});
|
||||
|
||||
registerPropertyGetters();
|
||||
registerRenderTypes();
|
||||
}
|
||||
|
||||
private static void registerPropertyGetter(IItemProvider item, ResourceLocation id, IItemPropertyGetter propGetter) {
|
||||
|
||||
@@ -13,7 +13,10 @@ import net.minecraft.block.Block;
|
||||
import net.minecraft.block.Blocks;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityType;
|
||||
import net.minecraft.entity.MobEntity;
|
||||
import net.minecraft.entity.ai.attributes.Attribute;
|
||||
import net.minecraft.entity.ai.attributes.Attributes;
|
||||
import net.minecraft.entity.ai.attributes.GlobalEntityTypeAttributes;
|
||||
import net.minecraft.inventory.container.ContainerType;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.crafting.IRecipeSerializer;
|
||||
@@ -85,6 +88,7 @@ import vazkii.botania.common.core.loot.*;
|
||||
import vazkii.botania.common.core.proxy.IProxy;
|
||||
import vazkii.botania.common.core.proxy.ServerProxy;
|
||||
import vazkii.botania.common.crafting.ModRecipeTypes;
|
||||
import vazkii.botania.common.entity.EntityDoppleganger;
|
||||
import vazkii.botania.common.entity.ModEntities;
|
||||
import vazkii.botania.common.impl.corporea.CorporeaItemStackMatcher;
|
||||
import vazkii.botania.common.impl.corporea.CorporeaStringMatcher;
|
||||
@@ -223,6 +227,14 @@ public class Botania {
|
||||
new WorldTypeSkyblock();
|
||||
}
|
||||
|
||||
GlobalEntityTypeAttributes.put(ModEntities.DOPPLEGANGER, MobEntity.func_233666_p_()
|
||||
.func_233815_a_(Attributes.field_233821_d_, 0.4)
|
||||
.func_233815_a_(Attributes.field_233818_a_, EntityDoppleganger.MAX_HP)
|
||||
.func_233815_a_(Attributes.field_233820_c_, 1.0)
|
||||
.func_233813_a_());
|
||||
GlobalEntityTypeAttributes.put(ModEntities.PIXIE, MobEntity.func_233666_p_()
|
||||
.func_233815_a_(Attributes.field_233818_a_, 2.0)
|
||||
.func_233813_a_());
|
||||
ModBanners.init();
|
||||
ColorHelper.init();
|
||||
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
package vazkii.botania.common.entity;
|
||||
|
||||
import com.google.common.collect.ImmutableList;
|
||||
import com.mojang.blaze3d.matrix.MatrixStack;
|
||||
import com.mojang.blaze3d.platform.GlStateManager;
|
||||
import com.mojang.blaze3d.systems.RenderSystem;
|
||||
|
||||
@@ -91,7 +92,7 @@ public class EntityDoppleganger extends MobEntity implements IEntityAdditionalSp
|
||||
public static final int ARENA_HEIGHT = 5;
|
||||
|
||||
private static final int SPAWN_TICKS = 160;
|
||||
private static final float MAX_HP = 320F;
|
||||
public static final float MAX_HP = 320F;
|
||||
|
||||
private static final int MOB_SPAWN_START_TICKS = 20;
|
||||
private static final int MOB_SPAWN_END_TICKS = 80;
|
||||
@@ -427,14 +428,6 @@ public class EntityDoppleganger extends MobEntity implements IEntityAdditionalSp
|
||||
world.addParticle(ParticleTypes.EXPLOSION_EMITTER, getPosX(), getPosY(), getPosZ(), 1D, 0D, 0D);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void registerAttributes() {
|
||||
super.registerAttributes();
|
||||
getAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).setBaseValue(0.4);
|
||||
getAttribute(SharedMonsterAttributes.MAX_HEALTH).setBaseValue(MAX_HP);
|
||||
getAttribute(SharedMonsterAttributes.KNOCKBACK_RESISTANCE).setBaseValue(1.0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canDespawn(double dist) {
|
||||
return false;
|
||||
@@ -631,7 +624,7 @@ public class EntityDoppleganger extends MobEntity implements IEntityAdditionalSp
|
||||
EntityPixie pixie = new EntityPixie(world);
|
||||
pixie.setProps(players.get(rand.nextInt(players.size())), this, 1, 8);
|
||||
pixie.setPosition(getPosX() + getWidth() / 2, getPosY() + 2, getPosZ() + getWidth() / 2);
|
||||
pixie.onInitialSpawn(world, world.getDifficultyForLocation(new BlockPos(pixie)),
|
||||
pixie.onInitialSpawn(world, world.getDifficultyForLocation(pixie.func_233580_cy_()),
|
||||
SpawnReason.MOB_SUMMONED, null, null);
|
||||
world.addEntity(pixie);
|
||||
}
|
||||
@@ -641,13 +634,13 @@ public class EntityDoppleganger extends MobEntity implements IEntityAdditionalSp
|
||||
}
|
||||
|
||||
if (entity != null) {
|
||||
if (!entity.isImmuneToFire()) {
|
||||
if (!entity.func_230279_az_()) {
|
||||
entity.addPotionEffect(new EffectInstance(Effects.FIRE_RESISTANCE, 600, 0));
|
||||
}
|
||||
float range = 6F;
|
||||
entity.setPosition(getPosX() + 0.5 + Math.random() * range - range / 2, getPosY() - 1,
|
||||
getPosZ() + 0.5 + Math.random() * range - range / 2);
|
||||
entity.onInitialSpawn(world, world.getDifficultyForLocation(new BlockPos(entity)),
|
||||
entity.onInitialSpawn(world, world.getDifficultyForLocation(entity.func_233580_cy_()),
|
||||
SpawnReason.MOB_SUMMONED, null, null);
|
||||
if (entity instanceof WitherSkeletonEntity && hardMode) {
|
||||
entity.setItemStackToSlot(EquipmentSlotType.MAINHAND, new ItemStack(ModItems.elementiumSword));
|
||||
@@ -700,7 +693,7 @@ public class EntityDoppleganger extends MobEntity implements IEntityAdditionalSp
|
||||
|
||||
//also see SleepingHandler
|
||||
if (player.isSleeping()) {
|
||||
player.func_225652_a_(true, true);
|
||||
player.wakeUp();
|
||||
}
|
||||
|
||||
clearPotions(player);
|
||||
@@ -944,8 +937,8 @@ public class EntityDoppleganger extends MobEntity implements IEntityAdditionalSp
|
||||
}
|
||||
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public int bossBarRenderCallback(int x, int y) {
|
||||
RenderSystem.pushMatrix();
|
||||
public int bossBarRenderCallback(MatrixStack ms, int x, int y) {
|
||||
ms.push();
|
||||
int px = x + 160;
|
||||
int py = y + 12;
|
||||
|
||||
@@ -953,8 +946,8 @@ public class EntityDoppleganger extends MobEntity implements IEntityAdditionalSp
|
||||
ItemStack stack = new ItemStack(Items.PLAYER_HEAD);
|
||||
mc.getItemRenderer().renderItemIntoGUI(stack, px, py);
|
||||
|
||||
mc.fontRenderer.func_238405_a_("" + playerCount, px + 15, py + 4, 0xFFFFFF);
|
||||
RenderSystem.popMatrix();
|
||||
mc.fontRenderer.func_238405_a_(ms, Integer.toString(playerCount), px + 15, py + 4, 0xFFFFFF);
|
||||
ms.pop();
|
||||
|
||||
return 5;
|
||||
}
|
||||
|
||||
@@ -52,12 +52,6 @@ public class EntityPixie extends FlyingEntity {
|
||||
return NetworkHooks.getEntitySpawningPacket(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void registerAttributes() {
|
||||
super.registerAttributes();
|
||||
getAttribute(SharedMonsterAttributes.MAX_HEALTH).setBaseValue(2.0);
|
||||
}
|
||||
|
||||
public void setPixieType(int type) {
|
||||
dataManager.set(PIXIE_TYPE, type);
|
||||
}
|
||||
|
||||
@@ -219,14 +219,14 @@ public final class ModItems {
|
||||
public static final Item manasteelAxe = new ItemManasteelAxe(unstackable());
|
||||
public static final Item manasteelSword = new ItemManasteelSword(unstackable());
|
||||
public static final Item manasteelShears = new ItemManasteelShears(unstackable());
|
||||
public static final Item terrasteelHelm = new ItemTerrasteelHelm(unstackable());
|
||||
public static final Item terrasteelHelmRevealing = new ItemTerrasteelHelmRevealing(unstackable());
|
||||
public static final Item terrasteelChest = new ItemTerrasteelArmor(EquipmentSlotType.CHEST, unstackable());
|
||||
public static final Item terrasteelLegs = new ItemTerrasteelArmor(EquipmentSlotType.LEGS, unstackable());
|
||||
public static final Item terrasteelBoots = new ItemTerrasteelArmor(EquipmentSlotType.FEET, unstackable());
|
||||
public static final Item terraSword = new ItemTerraSword(unstackable());
|
||||
public static final Item terraPick = new ItemTerraPick(unstackable());
|
||||
public static final Item terraAxe = new ItemTerraAxe(unstackable());
|
||||
public static final Item terrasteelHelm = new ItemTerrasteelHelm(unstackable().func_234689_a_());
|
||||
public static final Item terrasteelHelmRevealing = new ItemTerrasteelHelmRevealing(unstackable().func_234689_a_());
|
||||
public static final Item terrasteelChest = new ItemTerrasteelArmor(EquipmentSlotType.CHEST, unstackable().func_234689_a_());
|
||||
public static final Item terrasteelLegs = new ItemTerrasteelArmor(EquipmentSlotType.LEGS, unstackable().func_234689_a_());
|
||||
public static final Item terrasteelBoots = new ItemTerrasteelArmor(EquipmentSlotType.FEET, unstackable().func_234689_a_());
|
||||
public static final Item terraSword = new ItemTerraSword(unstackable().func_234689_a_());
|
||||
public static final Item terraPick = new ItemTerraPick(unstackable().func_234689_a_());
|
||||
public static final Item terraAxe = new ItemTerraAxe(unstackable().func_234689_a_());
|
||||
public static final Item tinyPlanet = new ItemTinyPlanet(unstackable());
|
||||
public static final Item manaRing = new ItemManaRing(unstackable());
|
||||
public static final Item auraRing = new ItemAuraRing(unstackable());
|
||||
@@ -367,13 +367,13 @@ public final class ModItems {
|
||||
public static final Item phantomInk = new Item(defaultBuilder());
|
||||
public static final Item poolMinecart = new ItemPoolMinecart(unstackable());
|
||||
public static final Item pinkinator = new ItemPinkinator(unstackable());
|
||||
public static final Item infiniteFruit = new ItemInfiniteFruit(unstackable());
|
||||
public static final Item kingKey = new ItemKingKey(unstackable());
|
||||
public static final Item flugelEye = new ItemFlugelEye(unstackable());
|
||||
public static final Item thorRing = new ItemThorRing(unstackable());
|
||||
public static final Item odinRing = new ItemOdinRing(unstackable());
|
||||
public static final Item lokiRing = new ItemLokiRing(unstackable());
|
||||
public static final Item dice = new ItemDice(unstackable());
|
||||
public static final Item infiniteFruit = new ItemInfiniteFruit(unstackable().func_234689_a_());
|
||||
public static final Item kingKey = new ItemKingKey(unstackable().func_234689_a_());
|
||||
public static final Item flugelEye = new ItemFlugelEye(unstackable().func_234689_a_());
|
||||
public static final Item thorRing = new ItemThorRing(unstackable().func_234689_a_());
|
||||
public static final Item odinRing = new ItemOdinRing(unstackable().func_234689_a_());
|
||||
public static final Item lokiRing = new ItemLokiRing(unstackable().func_234689_a_());
|
||||
public static final Item dice = new ItemDice(unstackable().func_234689_a_());
|
||||
public static final Item keepIvy = new ItemKeepIvy(defaultBuilder());
|
||||
public static final Item blackHoleTalisman = new ItemBlackHoleTalisman(unstackable());
|
||||
public static final Item recordGaia1 = new ItemModRecord(1, ModSounds.gaiaMusic1, unstackable());
|
||||
|
||||
Reference in new issue
Block a user