* 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>
56 lines
1.2 KiB
C++
56 lines
1.2 KiB
C++
#include "stdafx.h"
|
|
#include "WoodTile.h"
|
|
#include "TreeTile.h"
|
|
#include "net.minecraft.world.level.h"
|
|
#include "net.minecraft.world.level.biome.h"
|
|
#include "net.minecraft.world.item.h"
|
|
#include "net.minecraft.stats.h"
|
|
#include "net.minecraft.world.h"
|
|
|
|
const unsigned int WoodTile::WOOD_NAMES[WOOD_NAMES_LENGTH] = { IDS_TILE_OAKWOOD_PLANKS,
|
|
IDS_TILE_SPRUCEWOOD_PLANKS,
|
|
IDS_TILE_BIRCHWOOD_PLANKS,
|
|
IDS_TILE_JUNGLE_PLANKS,
|
|
};
|
|
|
|
const wstring WoodTile::TEXTURE_NAMES[] = {L"oak", L"spruce", L"birch", L"jungle"};
|
|
|
|
// public static final String[] WOOD_NAMES = {
|
|
// "oak", "spruce", "birch", "jungle"
|
|
// };
|
|
|
|
WoodTile::WoodTile(int id) : Tile(id, Material::wood)
|
|
{
|
|
icons = NULL;
|
|
}
|
|
|
|
unsigned int WoodTile::getDescriptionId(int iData)
|
|
{
|
|
if(iData < 0 || iData >= WOOD_NAMES_LENGTH) iData = 0;
|
|
|
|
return WOOD_NAMES[iData];
|
|
}
|
|
|
|
Icon *WoodTile::getTexture(int face, int data)
|
|
{
|
|
if (data < 0 || data >= WOOD_NAMES_LENGTH)
|
|
{
|
|
data = 0;
|
|
}
|
|
return icons[data];
|
|
}
|
|
|
|
int WoodTile::getSpawnResourcesAuxValue(int data)
|
|
{
|
|
return data;
|
|
}
|
|
|
|
void WoodTile::registerIcons(IconRegister *iconRegister)
|
|
{
|
|
icons = new Icon*[WOOD_NAMES_LENGTH];
|
|
|
|
for (int i = 0; i < WOOD_NAMES_LENGTH; i++)
|
|
{
|
|
icons[i] = iconRegister->registerIcon(getIconName() + L"_" + TEXTURE_NAMES[i]);
|
|
}
|
|
} |