diff options
author | PilzAdam <pilzadam@minetest.net> | 2013-06-19 21:00:14 +0000 |
---|---|---|
committer | PilzAdam <pilzadam@minetest.net> | 2013-06-19 21:42:12 +0000 |
commit | 9b6f1d647c612bddbc994357b9e9fc8348868234 (patch) | |
tree | f5691cabb04ecf4b2137a794fc7bfd9bdcfe4867 /src | |
parent | 53066024f6a91d5f83241b379b94d8557d43a646 (diff) | |
download | minetest-9b6f1d647c612bddbc994357b9e9fc8348868234.tar.gz minetest-9b6f1d647c612bddbc994357b9e9fc8348868234.tar.bz2 minetest-9b6f1d647c612bddbc994357b9e9fc8348868234.zip |
Dont dig or place nodes if interact priv is missing (clientside)
Diffstat (limited to 'src')
-rw-r--r-- | src/game.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/game.cpp b/src/game.cpp index 88be47b39..f00e4c949 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -2589,7 +2589,8 @@ void the_game( Handle digging */ - if(nodig_delay_timer <= 0.0 && input->getLeftState()) + if(nodig_delay_timer <= 0.0 && input->getLeftState() + && client.checkPrivilege("interact")) { if(!digging) { @@ -2716,8 +2717,10 @@ void the_game( camera.setDigging(0); // left click animation } - if(input->getRightClicked() || - repeat_rightclick_timer >= g_settings->getFloat("repeat_rightclick_time")) + if((input->getRightClicked() || + repeat_rightclick_timer >= + g_settings->getFloat("repeat_rightclick_time")) && + client.checkPrivilege("interact")) { repeat_rightclick_timer = 0; infostream<<"Ground right-clicked"<<std::endl; |