* 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>
47 lines
1.3 KiB
C++
47 lines
1.3 KiB
C++
#pragma once
|
|
#include "Textures.h"
|
|
#include "..\Minecraft.World\JavaIntHash.h"
|
|
class Mob;
|
|
class Level;
|
|
class TileEntityRenderer;
|
|
class TileEntity;
|
|
|
|
class TileEntityRenderDispatcher
|
|
{
|
|
public:
|
|
static void staticCtor(); // 4J added
|
|
|
|
private:
|
|
typedef unordered_map<eINSTANCEOF, TileEntityRenderer *, eINSTANCEOFKeyHash, eINSTANCEOFKeyEq> classToTileRendererMap;
|
|
classToTileRendererMap renderers;
|
|
|
|
public:
|
|
static TileEntityRenderDispatcher *instance;
|
|
private:
|
|
Font *font;
|
|
|
|
public:
|
|
static double xOff, yOff, zOff;
|
|
|
|
Textures *textures;
|
|
Level *level;
|
|
shared_ptr<LivingEntity> cameraEntity;
|
|
float playerRotY;
|
|
float playerRotX;
|
|
double xPlayer, yPlayer, zPlayer;
|
|
|
|
private:
|
|
TileEntityRenderDispatcher();
|
|
|
|
public:
|
|
TileEntityRenderer *getRenderer(eINSTANCEOF e);
|
|
bool hasRenderer(shared_ptr<TileEntity> e);
|
|
TileEntityRenderer * getRenderer(shared_ptr<TileEntity> e);
|
|
void prepare(Level *level, Textures *textures, Font *font, shared_ptr<LivingEntity> player, float a);
|
|
void render(shared_ptr<TileEntity> e, float a, bool setColor = true);
|
|
void render(shared_ptr<TileEntity> entity, double x, double y, double z, float a, bool setColor = true, float alpha=1.0f, bool useCompiled = true); // 4J Added useCompiled
|
|
void setLevel(Level *level);
|
|
double distanceToSqr(double x, double y, double z);
|
|
Font *getFont();
|
|
};
|