Skip to content

Commit

Permalink
Creative: Override the hand instead of re-registering
Browse files Browse the repository at this point in the history
Allows the initial hand registration to alter the 'wield_scale' without
needing to also alter it in creative mod.
Also make default mod a dependency again, as the initial hand
registration is required.
  • Loading branch information
paramat committed Aug 31, 2019
1 parent 5c3e4b1 commit e8097c9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
6 changes: 2 additions & 4 deletions mods/creative/init.lua
Expand Up @@ -40,10 +40,8 @@ if creative_mode_cache then
local digtime = 42
local caps = {times = {digtime, digtime, digtime}, uses = 0, maxlevel = 256}

minetest.register_item(":", {
type = "none",
wield_image = "wieldhand.png",
wield_scale = {x = 1, y = 1, z = 2.5},
-- Override the hand tool
minetest.override_item("", {
range = 10,
tool_capabilities = {
full_punch_interval = 0.5,
Expand Down
3 changes: 1 addition & 2 deletions mods/creative/mod.conf
@@ -1,4 +1,3 @@
name = creative
description = Minetest Game mod: creative
depends = sfinv
optional_depends = default
depends = default, sfinv

0 comments on commit e8097c9

Please sign in to comment.