Skip to content

Commit

Permalink
Do predict when sneak-place to node with on_rightclick
Browse files Browse the repository at this point in the history
  • Loading branch information
Desour authored and sfan5 committed Jul 8, 2019
1 parent 0971a14 commit 140aeab
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/client/game.cpp
Expand Up @@ -3322,7 +3322,8 @@ bool Game::nodePlacementPrediction(const ItemDefinition &playeritem_def,
if (!is_valid_position)
return false;

if (!prediction.empty() && !nodedef->get(node).rightclickable) {
if (!prediction.empty() && !(nodedef->get(node).rightclickable &&
!isKeyDown(KeyType::SNEAK))) {
verbosestream << "Node placement prediction for "
<< playeritem_def.name << " is "
<< prediction << std::endl;
Expand Down

0 comments on commit 140aeab

Please sign in to comment.