Blocks are usable in adventure mode (#4464)
This commit is contained in:
parent
3f78ea7745
commit
6d938c0e3f
@ -1453,7 +1453,7 @@ void cClientHandle::HandleRightClick(int a_BlockX, int a_BlockY, int a_BlockZ, e
|
|||||||
cBlockHandler * BlockHandler = cBlockInfo::GetHandler(BlockType);
|
cBlockHandler * BlockHandler = cBlockInfo::GetHandler(BlockType);
|
||||||
|
|
||||||
bool Placeable = ItemHandler->IsPlaceable() && !m_Player->IsGameModeAdventure() && !m_Player->IsGameModeSpectator();
|
bool Placeable = ItemHandler->IsPlaceable() && !m_Player->IsGameModeAdventure() && !m_Player->IsGameModeSpectator();
|
||||||
bool BlockUsable = BlockHandler->IsUseable() && !m_Player->IsGameModeAdventure() && (!m_Player->IsGameModeSpectator() || cBlockInfo::IsUseableBySpectator(BlockType));
|
bool BlockUsable = BlockHandler->IsUseable() && (!m_Player->IsGameModeSpectator() || cBlockInfo::IsUseableBySpectator(BlockType));
|
||||||
|
|
||||||
if (BlockUsable && !(m_Player->IsCrouched() && !HeldItem.IsEmpty()))
|
if (BlockUsable && !(m_Player->IsCrouched() && !HeldItem.IsEmpty()))
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user