aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.Client/PlayerRenderer.h
diff options
context:
space:
mode:
Diffstat (limited to 'Minecraft.Client/PlayerRenderer.h')
-rw-r--r--Minecraft.Client/PlayerRenderer.h42
1 files changed, 42 insertions, 0 deletions
diff --git a/Minecraft.Client/PlayerRenderer.h b/Minecraft.Client/PlayerRenderer.h
new file mode 100644
index 00000000..10564104
--- /dev/null
+++ b/Minecraft.Client/PlayerRenderer.h
@@ -0,0 +1,42 @@
+#pragma once
+#include "MobRenderer.h"
+#include "..\Minecraft.World\Player.h"
+class HumanoidModel;
+using namespace std;
+
+class PlayerRenderer : public MobRenderer
+{
+private:
+ // 4J Added
+ static const unsigned int s_nametagColors[MINECRAFT_NET_MAX_PLAYERS];
+
+ HumanoidModel *humanoidModel;
+ HumanoidModel *armorParts1;
+ HumanoidModel *armorParts2;
+
+public:
+ PlayerRenderer();
+
+ static unsigned int getNametagColour(int index);
+
+private:
+ static const wstring MATERIAL_NAMES[5];
+
+protected:
+ virtual int prepareArmor(shared_ptr<Mob> _player, int layer, float a);
+ virtual void prepareSecondPassArmor(shared_ptr<Mob> mob, int layer, float a);
+public:
+ virtual void render(shared_ptr<Entity> _mob, double x, double y, double z, float rot, float a);
+protected:
+ virtual void renderName(shared_ptr<Mob> _mob, double x, double y, double z);
+ virtual void additionalRendering(shared_ptr<Mob> _mob, float a);
+ virtual void scale(shared_ptr<Mob> _player, float a);
+public:
+ void renderHand();
+protected:
+ virtual void setupPosition(shared_ptr<Mob> _mob, double x, double y, double z);
+ virtual void setupRotations(shared_ptr<Mob> _mob, float bob, float bodyRot, float a);
+
+private:
+ virtual void renderShadow(shared_ptr<Entity> e, double x, double y, double z, float pow, float a); // 4J Added override
+}; \ No newline at end of file