mirror of
https://github.com/smartcmd/MinecraftConsoles.git
synced 2026-05-19 09:03:52 +00:00
Renamed and added functions
Renamed functions with skin offset or model offset in there name to have skin adjustment instead. Added two functions in Player.cpp and Player.h to handle model types for player. Altered getModel() function in EntityRenderer.h and moved fuctionallity to EntityRenderer.cpp. Optimized write() function in TextureAndGeometryPacket.cpp with __fastcall (prevents crashes in multiplayer when instances are running on the same PC).
This commit is contained in:
parent
878547dec8
commit
e8064d2ee3
21 changed files with 280 additions and 294 deletions
|
|
@ -19,7 +19,7 @@ ResourceLocation EntityRenderer::SHADOW_LOCATION = ResourceLocation(TN__CLAMP__M
|
|||
EntityRenderer::EntityRenderer()
|
||||
{
|
||||
model = nullptr;
|
||||
modelClassic = nullptr;
|
||||
modelWide = nullptr;
|
||||
modelSlim = nullptr;
|
||||
tileRenderer = new TileRenderer();
|
||||
shadowRadius = 0;
|
||||
|
|
@ -409,4 +409,11 @@ void EntityRenderer::registerTerrainTextures(IconRegister *iconRegister)
|
|||
ResourceLocation *EntityRenderer::getTextureLocation(shared_ptr<Entity> mob)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
Model *EntityRenderer::getModel(int modelType)
|
||||
{
|
||||
if (modelType == 2) return modelSlim;
|
||||
else if (modelType == 1) return modelWide;
|
||||
else return model;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue