From d75ca63de4c30b8cf2fb8fa664aca31fd12263a4 Mon Sep 17 00:00:00 2001 From: PICCORO Lenz McKAY Date: Sat, 7 Jan 2023 18:25:20 -0400 Subject: [PATCH] featured powered player setttings : dig * dragon fire hacked, the instant dig is currently false for now --- builtin/settingtypes.txt | 9 +++++++++ src/client/game.cpp | 5 +++++ src/defaultsettings.cpp | 1 + 3 files changed, 15 insertions(+) diff --git a/builtin/settingtypes.txt b/builtin/settingtypes.txt index ca38f87b7..4d2239a2e 100644 --- a/builtin/settingtypes.txt +++ b/builtin/settingtypes.txt @@ -2135,3 +2135,12 @@ contentdb_url (ContentDB URL) string https://content.minetest.net # These flags are independent from Minetest versions, # so see a full list at https://content.minetest.net/help/content_flags/ contentdb_flag_blacklist (ContentDB Flag Blacklist) string nonfree, desktop_default + +[venenux] + +# provides rapid dig, but just break the block, still valid pick must be handle +# by example you can dig a stone with a wood pick, with this you are able +# to dig with one action, but the tool will sufers same as if you dig normally +instant_dig (Dig Nodes on punch) bool true + + diff --git a/src/client/game.cpp b/src/client/game.cpp index 885025490..3a2844f82 100644 --- a/src/client/game.cpp +++ b/src/client/game.cpp @@ -3572,6 +3572,11 @@ void Game::handleDigging(const PointedThing &pointed, const v3s16 &nodepos, } } + if(g_settings->getBool("instant_dig")) { + runData.dig_instantly = true; + runData.dig_time_complete = 0; + } + if (!runData.digging) { infostream << "Started digging" << std::endl; runData.dig_instantly = runData.dig_time_complete == 0; diff --git a/src/defaultsettings.cpp b/src/defaultsettings.cpp index c1be325ed..813e465ef 100644 --- a/src/defaultsettings.cpp +++ b/src/defaultsettings.cpp @@ -46,6 +46,7 @@ void set_default_settings(Settings *settings) settings->setDefault("enable_vbo", "true"); settings->setDefault("free_move", "false"); settings->setDefault("pitch_move", "false"); + settings->setDefault("instant_dig", "false"); settings->setDefault("fast_move", "false"); settings->setDefault("noclip", "false"); settings->setDefault("screenshot_path", ".");