aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.Client/PlayerConnection.cpp
diff options
context:
space:
mode:
authorvoid_17 <heroerror3@gmail.com>2026-03-02 17:10:34 +0700
committervoid_17 <heroerror3@gmail.com>2026-03-02 17:10:34 +0700
commit07ad68bc156b3ab70401723bb074a29588ad3cb7 (patch)
treefcd5c35bb393920e46af6c9b643d0544e78b5ab8 /Minecraft.Client/PlayerConnection.cpp
parent7bee4770df1540c2daf3121c0790332fb41e72dd (diff)
dynamic_pointer_cast -> std::dynamic_pointer_cast
Diffstat (limited to 'Minecraft.Client/PlayerConnection.cpp')
-rw-r--r--Minecraft.Client/PlayerConnection.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/Minecraft.Client/PlayerConnection.cpp b/Minecraft.Client/PlayerConnection.cpp
index 393ae105..51e48e54 100644
--- a/Minecraft.Client/PlayerConnection.cpp
+++ b/Minecraft.Client/PlayerConnection.cpp
@@ -1273,9 +1273,9 @@ void PlayerConnection::handleSignUpdate(std::shared_ptr<SignUpdatePacket> packet
{
std::shared_ptr<TileEntity> te = level->getTileEntity(packet->x, packet->y, packet->z);
- if (dynamic_pointer_cast<SignTileEntity>(te) != NULL)
+ if (std::dynamic_pointer_cast<SignTileEntity>(te) != NULL)
{
- std::shared_ptr<SignTileEntity> ste = dynamic_pointer_cast<SignTileEntity>(te);
+ std::shared_ptr<SignTileEntity> ste = std::dynamic_pointer_cast<SignTileEntity>(te);
if (!ste->isEditable())
{
server->warn(L"Player " + player->name + L" just tried to change non-editable sign");
@@ -1284,12 +1284,12 @@ void PlayerConnection::handleSignUpdate(std::shared_ptr<SignUpdatePacket> packet
}
// 4J-JEV: Changed to allow characters to display as a [].
- if (dynamic_pointer_cast<SignTileEntity>(te) != NULL)
+ if (std::dynamic_pointer_cast<SignTileEntity>(te) != NULL)
{
int x = packet->x;
int y = packet->y;
int z = packet->z;
- std::shared_ptr<SignTileEntity> ste = dynamic_pointer_cast<SignTileEntity>(te);
+ std::shared_ptr<SignTileEntity> ste = std::dynamic_pointer_cast<SignTileEntity>(te);
for (int i = 0; i < 4; i++)
{
wstring lineText = packet->lines[i].substr(0,15);
@@ -1512,7 +1512,7 @@ void PlayerConnection::handleCustomPayload(std::shared_ptr<CustomPayloadPacket>
void PlayerConnection::handleDebugOptions(std::shared_ptr<DebugOptionsPacket> packet)
{
- //Player player = dynamic_pointer_cast<Player>( player->shared_from_this() );
+ //Player player = std::dynamic_pointer_cast<Player>( player->shared_from_this() );
player->SetDebugOptions(packet->m_uiVal);
}
@@ -1528,7 +1528,7 @@ void PlayerConnection::handleCraftItem(std::shared_ptr<CraftItemPacket> packet)
if(app.DebugSettingsOn() && (player->GetDebugOptions()&(1L<<eDebugSetting_CraftAnything)))
{
- pTempItemInst->onCraftedBy(player->level, dynamic_pointer_cast<Player>( player->shared_from_this() ), pTempItemInst->count );
+ pTempItemInst->onCraftedBy(player->level, std::dynamic_pointer_cast<Player>( player->shared_from_this() ), pTempItemInst->count );
if(player->inventory->add(pTempItemInst)==false )
{
// no room in inventory, so throw it down
@@ -1542,7 +1542,7 @@ void PlayerConnection::handleCraftItem(std::shared_ptr<CraftItemPacket> packet)
// TODO 4J Stu - Assume at the moment that the client can work this out for us...
//if(pRecipeIngredientsRequired[iRecipe].bCanMake)
//{
- pTempItemInst->onCraftedBy(player->level, dynamic_pointer_cast<Player>( player->shared_from_this() ), pTempItemInst->count );
+ pTempItemInst->onCraftedBy(player->level, std::dynamic_pointer_cast<Player>( player->shared_from_this() ), pTempItemInst->count );
// and remove those resources from your inventory
for(int i=0;i<pRecipeIngredientsRequired[iRecipe].iIngC;i++)