Can't get access to locked chests [solved]

User avatar
Ragnarok
Member
 
Posts: 213
Joined: Thu Mar 22, 2012 12:56

Can't get access to locked chests [solved]

by Ragnarok » Tue Jul 10, 2012 21:18

After update to 0.4.dev-20120606 I can't move items between inventory and locked chest. I suppose I haven't apropriate priviledges. Any idea how to fix this?
Last edited by Ragnarok on Wed Jul 11, 2012 17:22, edited 1 time in total.
 

User avatar
Topywo
Member
 
Posts: 1718
Joined: Fri May 18, 2012 20:27

by Topywo » Tue Jul 10, 2012 22:27

Try one of the following:

1. Changing true and false (Works in one version, but I don't expect it to work between versions after an upgrade, but you never know)
Search in the init.lua (under games/minetest_game/mods/default) "locked". The third or fourth one will show you this alinea:
local function has_locked_chest_privilege(meta, player)
if player:get_player_name() ~= meta:get_string("owner") then
return false
end
return true
end

Change false in true and true in false

Remove the stuff from the locked chest. Don't forget to change it back

2. Probably didn't work... This is the text in the init.lua from an older (april) version. Maybe copying it and pasting it over the (much larger) new text (starting from the alinea mentioned under 1. and ending where furnace begins) gives you the change to empty the locked chest. Then paste the new text back over the old.

minetest.register_node("default:chest_locked", {
description = "Locked Chest",
tile_images = {"default_chest_top.png", "default_chest_top.png", "default_chest_side.png",
"default_chest_side.png", "default_chest_side.png", "default_chest_lock.png"},
paramtype2 = "facedir",
metadata_name = "locked_chest",
groups = {snappy=2,choppy=2,oddly_breakable_by_hand=2},
legacy_facedir_simple = true,
sounds = default.node_sound_wood_defaults(),
})
 

lkjoel
Member
 
Posts: 778
Joined: Wed Feb 29, 2012 19:27

by lkjoel » Tue Jul 10, 2012 23:51

Nice tutorial Topywo! If his problem is just that it's his own locked chest but he can't access it, your #1 should work (unless there are "copypasted" parts of the code, to which he'll have to do the same to them)
My mods: The Nether | Doctor Who (WIP)

I have quit minetest ... again. I am heavily unimpressed by both the game and the community.
 

User avatar
Ragnarok
Member
 
Posts: 213
Joined: Thu Mar 22, 2012 12:56

by Ragnarok » Wed Jul 11, 2012 09:31

Thanks a lot :) It helped. In my case (on Ubuntu Studio) init.lua is located under path: /usr/local/share/minetest/games/minetest_game/mods/default/init.lua
 


Return to Minetest Problems

Who is online

Users browsing this forum: Bing [Bot] and 6 guests

cron