Revert "Project modernization (#630)"
This code was not tested and breaks in Release builds, reverting to restore
functionality of the nightly. All in-game menus do not work and generating
a world crashes.
This reverts commit a9be52c41a.
This commit is contained in:
@@ -102,7 +102,7 @@ void VineTile::updateShape(LevelSource *level, int x, int y, int z, int forceDat
|
||||
|
||||
AABB *VineTile::getAABB(Level *level, int x, int y, int z)
|
||||
{
|
||||
return nullptr;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
bool VineTile::mayPlace(Level *level, int x, int y, int z, int face)
|
||||
@@ -259,7 +259,7 @@ testLoop: if(noSideSpread) break;
|
||||
|
||||
int edgeTile = level->getTile(x + Direction::STEP_X[testDirection], y, z + Direction::STEP_Z[testDirection]);
|
||||
|
||||
if (edgeTile == 0 || Tile::tiles[edgeTile] == nullptr)
|
||||
if (edgeTile == 0 || Tile::tiles[edgeTile] == NULL)
|
||||
{
|
||||
// if the edge tile is air, we could possibly cling
|
||||
// to something
|
||||
@@ -371,7 +371,7 @@ int VineTile::getResourceCount(Random *random)
|
||||
|
||||
void VineTile::playerDestroy(Level *level, shared_ptr<Player>player, int x, int y, int z, int data)
|
||||
{
|
||||
if (!level->isClientSide && player->getSelectedItem() != nullptr && player->getSelectedItem()->id == Item::shears->id)
|
||||
if (!level->isClientSide && player->getSelectedItem() != NULL && player->getSelectedItem()->id == Item::shears->id)
|
||||
{
|
||||
player->awardStat(
|
||||
GenericStats::blocksMined(id),
|
||||
@@ -379,7 +379,7 @@ void VineTile::playerDestroy(Level *level, shared_ptr<Player>player, int x, int
|
||||
);
|
||||
|
||||
// drop leaf block instead of sapling
|
||||
popResource(level, x, y, z, std::make_shared<ItemInstance>(Tile::vine, 1, 0));
|
||||
popResource(level, x, y, z, shared_ptr<ItemInstance>(new ItemInstance(Tile::vine, 1, 0)));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user