feat: TU19 (Dec 2014) Features & Content (#155)
* try to resolve merge conflict
* feat: TU19 (Dec 2014) Features & Content (#32)
* December 2014 files
* Working release build
* Fix compilation issues
* Add sound to Windows64Media
* Add DLC content and force Tutorial DLC
* Revert "Add DLC content and force Tutorial DLC"
This reverts commit 97a4399472.
* Disable broken light packing
* Disable breakpoint during DLC texture map load
Allows DLC loading but the DLC textures are still broken
* Fix post build not working
* ...
* fix vs2022 build
* fix cmake build
---------
Co-authored-by: Loki <lokirautio@gmail.com>
This commit is contained in:
@@ -3,12 +3,17 @@
|
||||
#include "MultiPlayerLocalPlayer.h"
|
||||
#include "..\Minecraft.World\net.minecraft.world.entity.animal.h"
|
||||
|
||||
ResourceLocation *WolfRenderer::WOLF_LOCATION = new ResourceLocation(TN_MOB_WOLF);
|
||||
ResourceLocation *WolfRenderer::WOLF_TAME_LOCATION = new ResourceLocation(TN_MOB_WOLF_TAME);
|
||||
ResourceLocation *WolfRenderer::WOLF_ANGRY_LOCATION = new ResourceLocation(TN_MOB_WOLF_ANGRY);
|
||||
ResourceLocation *WolfRenderer::WOLF_COLLAR_LOCATION = new ResourceLocation(TN_MOB_WOLF_COLLAR);
|
||||
|
||||
WolfRenderer::WolfRenderer(Model *model, Model *armor, float shadow) : MobRenderer(model, shadow)
|
||||
{
|
||||
setArmor(armor);
|
||||
}
|
||||
|
||||
float WolfRenderer::getBob(shared_ptr<Mob> _mob, float a)
|
||||
float WolfRenderer::getBob(shared_ptr<LivingEntity> _mob, float a)
|
||||
{
|
||||
// 4J - dynamic cast required because we aren't using templates/generics in our version
|
||||
shared_ptr<Wolf> mob = dynamic_pointer_cast<Wolf>(_mob);
|
||||
@@ -16,7 +21,7 @@ float WolfRenderer::getBob(shared_ptr<Mob> _mob, float a)
|
||||
return mob->getTailAngle();
|
||||
}
|
||||
|
||||
int WolfRenderer::prepareArmor(shared_ptr<Mob> mob, int layer, float a)
|
||||
int WolfRenderer::prepareArmor(shared_ptr<LivingEntity> mob, int layer, float a)
|
||||
{
|
||||
if (mob->isInvisibleTo(Minecraft::GetInstance()->player)) return -1; // 4J-JEV: Todo, merge with java fix in '1.7.5'.
|
||||
|
||||
@@ -24,14 +29,14 @@ int WolfRenderer::prepareArmor(shared_ptr<Mob> mob, int layer, float a)
|
||||
if (layer == 0 && wolf->isWet())
|
||||
{
|
||||
float brightness = wolf->getBrightness(a) * wolf->getWetShade(a);
|
||||
bindTexture(wolf->getTexture());
|
||||
bindTexture(WOLF_LOCATION);
|
||||
glColor3f(brightness, brightness, brightness);
|
||||
|
||||
return 1;
|
||||
}
|
||||
if (layer == 1 && wolf->isTame())
|
||||
{
|
||||
bindTexture(TN_MOB_WOLF_COLLAR);
|
||||
bindTexture(WOLF_COLLAR_LOCATION);
|
||||
float brightness = SharedConstants::TEXTURE_LIGHTING ? 1 : wolf->getBrightness(a);
|
||||
int color = wolf->getCollarColor();
|
||||
glColor3f(brightness * Sheep::COLOR[color][0], brightness * Sheep::COLOR[color][1], brightness * Sheep::COLOR[color][2]);
|
||||
@@ -40,3 +45,17 @@ int WolfRenderer::prepareArmor(shared_ptr<Mob> mob, int layer, float a)
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
ResourceLocation *WolfRenderer::getTextureLocation(shared_ptr<Entity> _mob)
|
||||
{
|
||||
shared_ptr<Wolf> mob = dynamic_pointer_cast<Wolf>(_mob);
|
||||
if (mob->isTame())
|
||||
{
|
||||
return WOLF_TAME_LOCATION;
|
||||
}
|
||||
if (mob->isAngry())
|
||||
{
|
||||
return WOLF_ANGRY_LOCATION;
|
||||
}
|
||||
return WOLF_LOCATION;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user