Revert "shared_ptr -> std::shared_ptr"

This reverts commit 7074f35e4b.
This commit is contained in:
void_17
2026-03-02 17:37:16 +07:00
parent 8a2a62ea1d
commit 119bff3514
1373 changed files with 12049 additions and 12049 deletions

View File

@@ -211,9 +211,9 @@ bool OldChunkStorage::saveEntities(LevelChunk *lc, Level *level, CompoundTag *ta
for (int i = 0; i < lc->ENTITY_BLOCKS_LENGTH; i++)
{
AUTO_VAR(itEnd, lc->entityBlocks[i]->end());
for( vector<std::shared_ptr<Entity> >::iterator it = lc->entityBlocks[i]->begin(); it != itEnd; it++ )
for( vector<shared_ptr<Entity> >::iterator it = lc->entityBlocks[i]->begin(); it != itEnd; it++ )
{
std::shared_ptr<Entity> e = *it;
shared_ptr<Entity> e = *it;
lc->lastSaveHadEntities = true;
CompoundTag *teTag = new CompoundTag();
if (e->save(teTag))
@@ -268,10 +268,10 @@ void OldChunkStorage::save(LevelChunk *lc, Level *level, DataOutputStream *dos)
ListTag<CompoundTag> *tileEntityTags = new ListTag<CompoundTag>();
AUTO_VAR(itEnd, lc->tileEntities.end());
for( unordered_map<TilePos, std::shared_ptr<TileEntity>, TilePosKeyHash, TilePosKeyEq>::iterator it = lc->tileEntities.begin();
for( unordered_map<TilePos, shared_ptr<TileEntity>, TilePosKeyHash, TilePosKeyEq>::iterator it = lc->tileEntities.begin();
it != itEnd; it++)
{
std::shared_ptr<TileEntity> te = it->second;
shared_ptr<TileEntity> te = it->second;
CompoundTag *teTag = new CompoundTag();
te->save(teTag);
tileEntityTags->add(teTag);
@@ -357,10 +357,10 @@ void OldChunkStorage::save(LevelChunk *lc, Level *level, CompoundTag *tag)
ListTag<CompoundTag> *tileEntityTags = new ListTag<CompoundTag>();
AUTO_VAR(itEnd, lc->tileEntities.end());
for( unordered_map<TilePos, std::shared_ptr<TileEntity>, TilePosKeyHash, TilePosKeyEq>::iterator it = lc->tileEntities.begin();
for( unordered_map<TilePos, shared_ptr<TileEntity>, TilePosKeyHash, TilePosKeyEq>::iterator it = lc->tileEntities.begin();
it != itEnd; it++)
{
std::shared_ptr<TileEntity> te = it->second;
shared_ptr<TileEntity> te = it->second;
CompoundTag *teTag = new CompoundTag();
te->save(teTag);
tileEntityTags->add(teTag);
@@ -402,7 +402,7 @@ void OldChunkStorage::loadEntities(LevelChunk *lc, Level *level, CompoundTag *ta
for (int i = 0; i < entityTags->size(); i++)
{
CompoundTag *teTag = entityTags->get(i);
std::shared_ptr<Entity> te = EntityIO::loadStatic(teTag, level);
shared_ptr<Entity> te = EntityIO::loadStatic(teTag, level);
lc->lastSaveHadEntities = true;
if (te != NULL)
{
@@ -417,7 +417,7 @@ void OldChunkStorage::loadEntities(LevelChunk *lc, Level *level, CompoundTag *ta
for (int i = 0; i < tileEntityTags->size(); i++)
{
CompoundTag *teTag = tileEntityTags->get(i);
std::shared_ptr<TileEntity> te = TileEntity::loadStatic(teTag);
shared_ptr<TileEntity> te = TileEntity::loadStatic(teTag);
if (te != NULL)
{
lc->addTileEntity(te);