Skip to content
Closed
Binary file added game/assets/console/Graphics/360ctrl.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/Armour_Slot_Body.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/Armour_Slot_Feet.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/Armour_Slot_Head.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/Arrow_Off.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/Arrow_On.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/Arrow_Small_Off.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/Arrow_Small_On.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonA.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonB.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonBack.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonDpadL.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonDpadR.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonLeftBumper.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonLeftStick.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonRS.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonRightStick.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added game/assets/console/Graphics/ButtonStart.png
Binary file added game/assets/console/Graphics/ButtonX.png
Binary file added game/assets/console/Graphics/ButtonY.png
Binary file added game/assets/console/Graphics/Crafting_Panel.png
Binary file added game/assets/console/Graphics/Crouch_Frame1.png
Binary file added game/assets/console/Graphics/Crouch_Frame2.png
Binary file added game/assets/console/Graphics/Flame_Off.png
Binary file added game/assets/console/Graphics/Flame_Off_Small.png
Binary file added game/assets/console/Graphics/Flame_On.png
Binary file added game/assets/console/Graphics/Flame_On_Small.png
Binary file added game/assets/console/Graphics/Focus_circle.png
Binary file added game/assets/console/Graphics/HowToPlay_Chest.png
Binary file added game/assets/console/Graphics/HowToPlay_HUD.png
Binary file added game/assets/console/Graphics/IconHolder.png
Binary file added game/assets/console/Graphics/IconHolderRed.png
Binary file added game/assets/console/Graphics/IconHolder_Small.png
Binary file added game/assets/console/Graphics/ListButton_Norm.png
Binary file added game/assets/console/Graphics/ListButton_Over.png
Binary file added game/assets/console/Graphics/MenuButton_Down.png
Binary file added game/assets/console/Graphics/MenuButton_Norm.png
Binary file added game/assets/console/Graphics/MenuTitle.png
Binary file added game/assets/console/Graphics/PanelBlue_Bot_L.png
Binary file added game/assets/console/Graphics/PanelBlue_Bot_M.png
Binary file added game/assets/console/Graphics/PanelBlue_Bot_R.png
Binary file added game/assets/console/Graphics/PanelBlue_Mid_L.png
Binary file added game/assets/console/Graphics/PanelBlue_Mid_M.png
Binary file added game/assets/console/Graphics/PanelBlue_Mid_R.png
Binary file added game/assets/console/Graphics/PanelBlue_Top_L.png
Binary file added game/assets/console/Graphics/PanelBlue_Top_M.png
Binary file added game/assets/console/Graphics/PanelBlue_Top_R.png
Binary file added game/assets/console/Graphics/Panel_BL.png
Binary file added game/assets/console/Graphics/Panel_BM.png
Binary file added game/assets/console/Graphics/Panel_BR.png
Binary file added game/assets/console/Graphics/Panel_ML.png
Binary file added game/assets/console/Graphics/Panel_MM.png
Binary file added game/assets/console/Graphics/Panel_MR.png
Binary file added game/assets/console/Graphics/Panel_TL.png
Binary file added game/assets/console/Graphics/Panel_TM.png
Binary file added game/assets/console/Graphics/Panel_TR.png
Binary file added game/assets/console/Graphics/Pointer.png
Binary file added game/assets/console/Graphics/SaveArrow.png
Binary file added game/assets/console/Graphics/SaveChest.png
Binary file added game/assets/console/Graphics/Shine_Pill.png
Binary file added game/assets/console/Graphics/Shine_Pill_Press.png
Binary file added game/assets/console/Graphics/Slider_Button.png
Binary file added game/assets/console/Graphics/Slider_Track.png
Binary file added game/assets/console/Graphics/Tab_Left.png
Binary file added game/assets/console/Graphics/Tab_Middle.png
Binary file added game/assets/console/Graphics/Tab_Right.png
Binary file added game/assets/console/Graphics/Tab_Small_Left.png
Binary file added game/assets/console/Graphics/Tab_Small_Middle.png
Binary file added game/assets/console/Graphics/Tab_Small_Right.png
Binary file added game/assets/console/Graphics/TaskComplete.png
Binary file added game/assets/console/Graphics/TaskIncomplete.png
Binary file added game/assets/console/Graphics/Terra003.png
Binary file added game/assets/console/Graphics/Terra007.png
Binary file added game/assets/console/Graphics/Terra016.png
Binary file added game/assets/console/Graphics/Terra021.png
Binary file added game/assets/console/Graphics/Tick.png
Binary file added game/assets/console/Graphics/Tickbox_Norm.png
Binary file added game/assets/console/Graphics/Tickbox_Over.png
Binary file added game/assets/console/Graphics/Warning.png
Binary file added game/assets/console/Graphics/a_graphic.png
Binary file added game/assets/console/Graphics/b_graphic.png
Binary file added game/assets/console/Graphics/caret.png
Binary file added game/assets/console/Graphics/graphic_X.png
Binary file added game/assets/console/Graphics/graphic_scene.png
Binary file added game/assets/console/Graphics/scene_shine.png
Binary file added game/assets/console/Graphics/shine_arrow_down.png
Binary file added game/assets/console/Graphics/shine_arrow_left.png
Binary file added game/assets/console/Graphics/shine_arrow_right.png
Binary file added game/assets/console/Graphics/shine_arrow_up.png
Binary file added game/assets/console/Graphics/voiceMuted.png
Binary file added game/assets/console/Graphics/voiceNotSpeaking.png
Binary file added game/assets/console/Graphics/voiceSpeaking.png
Binary file added game/assets/console/Graphics/x_graphic.png
Binary file added game/assets/console/Graphics/y_graphic.png
Binary file added game/assets/console/MenuTitle.png
Binary file added game/assets/console/Panel.png
Binary file added game/assets/console/Panel_Bot_L.png
Binary file added game/assets/console/Panel_Bot_M.png
Binary file added game/assets/console/Panel_Bot_R.png
Binary file added game/assets/console/Panel_Mid_L.png
Binary file added game/assets/console/Panel_Mid_M.png
Binary file added game/assets/console/Panel_Mid_R.png
Binary file added game/assets/console/Panel_Top_L.png
Binary file added game/assets/console/Panel_Top_M.png
Binary file added game/assets/console/Panel_Top_R.png
Binary file added game/assets/console/Panorama_Background_N.png
Binary file added game/assets/console/Panorama_Background_S.png
Binary file added game/assets/console/scrollDown.png
Binary file added game/assets/console/scrollLeft.png
Binary file added game/assets/console/scrollRight.png
Binary file added game/assets/console/scrollUp.png
Binary file modified game/assets/gui/gui.png
16 changes: 15 additions & 1 deletion source/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,9 @@ add_library(reminecraftpe-core STATIC
client/gui/screens/inventory/ContainerScreen.cpp
client/gui/screens/inventory/InventoryScreen.cpp
client/gui/screens/inventory/CraftingScreen.cpp
client/gui/screens/inventory/ClassicCraftingScreen_Console.cpp
client/gui/screens/inventory/FurnaceScreen.cpp
client/gui/screens/inventory/ChestScreen.cpp
client/gui/screens/inventory/ClassicCraftingScreen_Console.cpp
client/gui/components/ScrolledSelectionList.cpp
client/gui/components/AvailableGamesList.cpp
client/gui/components/RolledSelectionList.cpp
Expand Down Expand Up @@ -350,6 +351,7 @@ add_library(reminecraftpe-core STATIC
world/item/TilePlanterItem.cpp
world/item/CameraItem.cpp
world/item/TileItem.cpp
world/item/CoalItem.cpp
world/item/Inventory.cpp
world/item/crafting/Recipes.cpp
world/item/crafting/FurnaceRecipes.cpp
Expand All @@ -360,10 +362,12 @@ add_library(reminecraftpe-core STATIC
world/inventory/ContainerMenu.cpp
world/inventory/InventoryMenu.cpp
world/inventory/CraftingMenu.cpp
world/inventory/FurnaceMenu.cpp
world/inventory/ChestMenu.cpp
world/inventory/Slot.cpp
world/inventory/ResultSlot.cpp
world/inventory/ArmorSlot.cpp
world/inventory/FurnaceResultSlot.cpp
world/inventory/CraftingContainer.cpp
world/inventory/ResultContainer.cpp
world/inventory/SimpleContainer.cpp
Expand All @@ -386,6 +390,7 @@ add_library(reminecraftpe-core STATIC
world/item/SlabItem.cpp
world/particle/RedDustParticle.cpp
world/particle/TerrainParticle.cpp
world/particle/NoteParticle.cpp
world/particle/BubbleParticle.cpp
world/particle/ExplodeParticle.cpp
world/particle/ParticleEngine.cpp
Expand Down Expand Up @@ -421,6 +426,9 @@ add_library(reminecraftpe-core STATIC
world/tile/OreTile.cpp
world/tile/StairTile.cpp
world/tile/SandStoneTile.cpp
world/tile/ChestTile.cpp
world/tile/FurnaceTile.cpp
world/tile/MusicTile.cpp
world/tile/FireTile.cpp
world/tile/StoneSlabTile.cpp
world/tile/LiquidTile.cpp
Expand All @@ -442,6 +450,12 @@ add_library(reminecraftpe-core STATIC
world/tile/Web.cpp
world/tile/FenceTile.cpp
world/tile/CraftingTableTile.cpp
world/tile/entity/TileEntity.cpp
world/tile/entity/TileEntityType.cpp
world/tile/entity/ChestTileEntity.cpp
world/tile/entity/FurnaceTileEntity.cpp
world/tile/entity/MusicTileEntity.cpp
world/Facing.cpp
renderer/GL/GL.cpp
renderer/Attribute.cpp
renderer/ConstantBufferMetaData.cpp
Expand Down
4 changes: 3 additions & 1 deletion source/client/app/NinecraftApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#include "world/item/Item.hpp"
#include "world/entity/MobCategory.hpp"
#include "world/entity/MobFactory.hpp"
#include "world/tile/entity/TileEntityType.hpp"
#include "client/player/input/GameControllerHandler.hpp"
#include "client/player/input/Multitouch.hpp"
#include "client/gui/screens/StartMenuScreen.hpp"
Expand Down Expand Up @@ -182,7 +183,7 @@ void NinecraftApp::_initAll()
Tile::initTiles();
Item::initItems();
Biome::initBiomes();
//TileEntity::initTileEntities();
TileEntityType::InitTileEntities();
}

_initOptions();
Expand Down Expand Up @@ -340,6 +341,7 @@ void NinecraftApp::onGraphicsReset()

void NinecraftApp::teardown()
{
TileEntityType::TeardownTileEntities();
teardownRenderer();
Resource::teardownLoaders();
// Stop our SoundSystem before we nuke our sound buffers and cause it to implode
Expand Down
57 changes: 57 additions & 0 deletions source/client/gui/screens/inventory/FurnaceScreen.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
#include "FurnaceScreen.hpp"
#include "world/inventory/FurnaceMenu.hpp"
#include "renderer/ShaderConstants.hpp"

FurnaceScreen::FurnaceScreen(Inventory* inventory, FurnaceTileEntity* container)
: ContainerScreen(new FurnaceMenu(inventory, container)), m_inventory(inventory), m_furnace(container)
{
m_uiTheme = UI_JAVA;
}

void FurnaceScreen::tick()
{
ContainerScreen::tick();
}

void FurnaceScreen::_renderLabels()
{
m_pFont->draw(m_furnace->getName(), 66, 6, 0x404040);
m_pFont->draw(m_inventory->getName(), 8, m_imageHeight - 96 + 2, 0x404040);
}

void FurnaceScreen::_renderBg(float a)
{
currentShaderColor = Color::WHITE;

m_pMinecraft->m_pTextures->loadAndBindTexture("gui/furnace.png");

blit(m_leftPos, m_topPos, 0, 0, m_imageWidth, m_imageHeight, 0, 0);

int p;
if (m_furnace->isLit())
{
p = m_furnace->getLitProgress(12);
blit(m_leftPos + 56, m_topPos + 36 + 12 - p, 176, 12 - p, 14, p + 2, 0, 0);
}

p = m_furnace->getBurnProgress(24);
blit(m_leftPos + 79, m_topPos + 34, 176, 14, p + 1, 16, 0, 0);
}

SlotDisplay FurnaceScreen::_createSlotDisplay(const Slot& slot)
{
constexpr int slotSize = 18;
switch (slot.m_group)
{
case Slot::INPUT:
return SlotDisplay(56, 17 + (slot.m_slot % 2) * (slotSize * 2));
case Slot::OUTPUT:
return SlotDisplay(116, 35);
case Slot::INVENTORY:
return SlotDisplay(8 + (slot.m_slot % 9) * slotSize, 84 + ((slot.m_slot / 9) - 1) * slotSize, slotSize);
case Slot::HOTBAR:
return SlotDisplay(8 + (slot.m_slot % 9) * slotSize, 142, slotSize);
default:
return SlotDisplay();
}
}
20 changes: 20 additions & 0 deletions source/client/gui/screens/inventory/FurnaceScreen.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#pragma once

#include "ContainerScreen.hpp"
#include "world/tile/entity/FurnaceTileEntity.hpp"

class FurnaceScreen : public ContainerScreen
{
public:
FurnaceScreen(Inventory* inventory, FurnaceTileEntity* container);
void tick() override;

protected:
void _renderLabels() override;
void _renderBg(float a) override;
SlotDisplay _createSlotDisplay(const Slot&) override;

private:
Inventory* m_inventory;
FurnaceTileEntity* m_furnace;
};
5 changes: 3 additions & 2 deletions source/client/player/LocalPlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include "network/packets/PlayerEquipmentPacket.hpp"
#include "client/gui/screens/inventory/CraftingScreen.hpp"
#include "client/gui/screens/inventory/ChestScreen.hpp"
#include "client/gui/screens/inventory/FurnaceScreen.hpp"

int dword_250ADC, dword_250AE0;

Expand Down Expand Up @@ -134,11 +135,11 @@ void LocalPlayer::startCrafting(const TilePos& pos)
m_pMinecraft->getScreenChooser()->pushCraftingScreen(this, pos);
}

/*void LocalPlayer::openFurnace(FurnaceTileEntity* furnace)
void LocalPlayer::openFurnace(FurnaceTileEntity* furnace)
{
// PE 0.3.2 doesn't let you cook in creative mode
m_pMinecraft->setScreen(new FurnaceScreen(m_pInventory, furnace));
}*/
}

void LocalPlayer::openContainer(Container* container)
{
Expand Down
2 changes: 1 addition & 1 deletion source/client/player/LocalPlayer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class LocalPlayer : public Player
void setPlayerGameType(GameType gameType) override;
void swing() override;
void startCrafting(const TilePos&) override;
//void openFurnace(FurnaceTileEntity* furnace) override;
void openFurnace(FurnaceTileEntity* furnace) override;
void openContainer(Container* container) override;
void closeContainer() override;
//void openTrap(DispenserTileEntity* tileEntity) override;
Expand Down
49 changes: 48 additions & 1 deletion source/client/renderer/Chunk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,9 @@ void Chunk::rebuild()

LevelChunk::touchedSky = false;

std::set<TileEntity*> tmpSet(m_renderableTileEntities.begin(), m_renderableTileEntities.end());
m_renderableTileEntities.clear();

for (int i = Tile::RENDER_LAYERS_MIN; i <= Tile::RENDER_LAYERS_MAX; i++)
{
m_empty[i] = true;
Expand Down Expand Up @@ -169,6 +172,16 @@ void Chunk::rebuild()
t.setOffset(-m_pos);
}

if (!layer && Tile::isEntityTile[tile])
{
/*
// @TODO: ADD TILE ENTITY RENDER DISPATCHER
TileEntity* et = region.getTileEntity(tp);
if (TileEntityRenderDispatcher::getInstance()->hasRenderer(et))
m_renderableTileEntities.push_back(et);
*/
}

Tile* pTile = Tile::tiles[tile];

if (layer == pTile->getRenderLayer())
Expand Down Expand Up @@ -201,11 +214,45 @@ void Chunk::rebuild()
break;
}

std::set<TileEntity*> newSet(m_renderableTileEntities.begin(), m_renderableTileEntities.end());
std::vector<TileEntity*> toAdd, toRemove;

std::set_difference(
newSet.begin(), newSet.end(),
tmpSet.begin(), tmpSet.end(),
std::back_inserter(toAdd)
);

std::set_difference(
tmpSet.begin(), tmpSet.end(),
newSet.begin(), newSet.end(),
std::back_inserter(toRemove)
);

// Add
for (std::vector<TileEntity*>::iterator it = toAdd.begin(); it != toAdd.end(); ++it)
{
m_globalRenderableTileEntities.push_back(*it);
}

// Remove
for (std::vector<TileEntity*>::iterator it = toRemove.begin(); it != toRemove.end(); ++it)
{
std::vector<TileEntity*>::iterator f =
std::find(m_globalRenderableTileEntities.begin(),
m_globalRenderableTileEntities.end(),
*it);

if (f != m_globalRenderableTileEntities.end())
m_globalRenderableTileEntities.erase(f);
}

field_54 = LevelChunk::touchedSky;
m_bCompiled = true;
}

Chunk::Chunk(Level* level, const TilePos& pos, int size, int lists)
Chunk::Chunk(Level* level, std::vector<TileEntity*>& renderableTileEntities, const TilePos& pos, int size, int lists)
: m_globalRenderableTileEntities(renderableTileEntities)
{
m_bOcclusionVisible = true;
m_bOcclusionQuerying = false;
Expand Down
5 changes: 4 additions & 1 deletion source/client/renderer/Chunk.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,12 @@

class Level;
class Entity;
class TileEntity;

class Chunk
{
public:
Chunk(Level*, const TilePos& pos, int, int);
Chunk(Level*, std::vector<TileEntity*>& renderableTileEntities, const TilePos& pos, int, int);

public:
float distanceToSqr(const Entity& entity) const;
Expand All @@ -42,6 +43,8 @@ class Chunk

public:
Level* m_pLevel;
std::vector<TileEntity*>& m_globalRenderableTileEntities;
std::vector<TileEntity*> m_renderableTileEntities;
TilePos m_pos;
TilePos m_posS;
bool m_empty[Tile::RENDER_LAYERS_COUNT];
Expand Down
19 changes: 17 additions & 2 deletions source/client/renderer/LevelRenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,7 @@ void LevelRenderer::allChanged()
m_zMinChunk = 0;

m_dirtyChunks.clear();
//m_renderableTileEntities.clear();
m_renderableTileEntities.clear();

m_xMaxChunk = m_xChunks;
m_yMaxChunk = m_yChunks;
Expand All @@ -638,7 +638,7 @@ void LevelRenderer::allChanged()
{
int index = (cp.z * m_yChunks + cp.y) * m_xChunks + cp.x;

Chunk* pChunk = new Chunk(m_pLevel, cp * 16, 16, id + m_chunkLists);
Chunk* pChunk = new Chunk(m_pLevel, m_renderableTileEntities, cp * 16, 16, id + m_chunkLists);

if (m_bOcclusionCheck)
pChunk->m_occlusionId = 0; // m_occlusionCheckIds.get(count)
Expand Down Expand Up @@ -1421,6 +1421,11 @@ void LevelRenderer::addParticle(const std::string& name, const Vec3& pos, const
pe->add(new SmokeParticle(m_pLevel, pos, dir, 1.0f));
return;
}
if (name == "note")
{
pe->add(new NoteParticle(m_pLevel, pos, dir));
return;
}
if (name == "explode")
{
pe->add(new ExplodeParticle(m_pLevel, pos, dir));
Expand Down Expand Up @@ -1599,6 +1604,16 @@ void LevelRenderer::renderEntities(Vec3 pos, Culler* culler, float f)
EntityRenderDispatcher::getInstance()->render(*entity, f);
}
}

/*
// @TODO: TileEntityRenderDispatcher
for (std::vector<TileEntity*>::const_iterator it = m_renderableTileEntities.begin();
it != m_renderableTileEntities.end(); ++it)
{
TileEntity* tileEntity = *it;
TileEntityRenderDispatcher::getInstance()->render(tileEntity, f);
}
*/
}

void LevelRenderer::renderShadow(const Entity& entity, const Vec3& pos, float r, float pow, float a)
Expand Down
1 change: 1 addition & 0 deletions source/client/renderer/LevelRenderer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -223,4 +223,5 @@ class LevelRenderer : public LevelListener, public AppPlatformListener
mce::Mesh m_darkMesh;
//...
Textures* m_pTextures;
std::vector<TileEntity*> m_renderableTileEntities;
};
2 changes: 1 addition & 1 deletion source/client/sound/SoundRepository.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ bool SoundRepository::get(const std::string& name, SoundDesc& sd)
std::map<std::string, std::vector<SoundDesc> >::iterator iter = m_repo.find(name);
if (iter == m_repo.end())
{
LOG_E("Couldn't find a sound with id: %s", name.c_str());
LOG_W("Couldn't find a sound with id: %s", name.c_str());
return false;
}

Expand Down
12 changes: 12 additions & 0 deletions source/client/sound/sound_list.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,12 @@ SOUND(ui, press)
SOUND(ui, scroll)

SOUND(fire, fire)
SOUND(fire, ignite)
SOUND_NUM(fire, fire_crackle, 1)
SOUND_NUM(fire, fire_crackle, 2)
SOUND_NUM(fire, fire_crackle, 3)
SOUND_NUM(fire, fire_crackle, 4)
SOUND_NUM(fire, fire_crackle, 5)

SOUND_NUM(damage, fallbig, 1)
SOUND_NUM(damage, fallbig, 2)
Expand Down Expand Up @@ -103,3 +109,9 @@ SOUND_NUM(mob, zombie, 3)
SOUND_NUM(mob, zombiehurt, 1)
SOUND_NUM(mob, zombiehurt, 2)
SOUND(mob, zombiedeath)

SOUND(note, harp)
SOUND(note, bd)
SOUND(note, hat)
SOUND(note, snare)
SOUND(note, bassattack)
4 changes: 2 additions & 2 deletions source/common/Mth.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,13 @@ float Mth::invSqrt(float number)
// they just stole it from Quake.

float x2, y;
const float threehalfs = 1.5F;
const float threehalfs = 1.5f;
union {
float f;
int32_t i;
} un;

x2 = number * 0.5F;
x2 = number * 0.5f;
un.f = number; // evil floating point bit level hacking
un.i = 0x5f3759df - ( un.i >> 1 ); // what the fuck?
y = un.f;
Expand Down
Loading
Loading