aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.Client/SkullTileRenderer.h
blob: ea509b8b3c3fd607c8cc77ac92245d44fb4c7a74 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#pragma once

#include "TileEntityRenderer.h"

class SkeletonHeadModel;

class SkullTileRenderer : public TileEntityRenderer
{
public:
	static SkullTileRenderer *instance;

private:
	static ResourceLocation SKELETON_LOCATION;
	static ResourceLocation WITHER_SKELETON_LOCATION;
	static ResourceLocation ZOMBIE_LOCATION;
	static ResourceLocation CREEPER_LOCATION;

	// note: this head fits most mobs, just change texture
	SkeletonHeadModel *skeletonModel;
	SkeletonHeadModel *zombieModel;

public:
	SkullTileRenderer();
	~SkullTileRenderer();

	void render(shared_ptr<TileEntity> skull, double x, double y, double z, float a, bool setColor, float alpha, bool useCompiled = true);
	void init(TileEntityRenderDispatcher *tileEntityRenderDispatcher);
	void renderSkull(float x, float y, float z, int face, float rot, int type, const wstring &extra);
};