aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/game.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/game.cpp b/src/game.cpp
index a8f6bc992..12bc695a6 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -2786,8 +2786,13 @@ void the_game(bool &kill, bool random_input, InputHandler *input,
if(pointed != pointed_old)
{
infostream<<"Pointing at "<<pointed.dump()<<std::endl;
- if (g_settings->getBool("enable_node_highlighting"))
- client.setHighlighted(pointed.node_undersurface, show_hud);
+ if (g_settings->getBool("enable_node_highlighting")) {
+ if (pointed.type == POINTEDTHING_NODE) {
+ client.setHighlighted(pointed.node_undersurface, show_hud);
+ } else {
+ client.setHighlighted(pointed.node_undersurface, false);
+ }
+ }
}
/*