[MOD]Keys to lockable chests, doors[WIP]
[MOD]Keys to lockable chests, doors[WIP]
this mod adds
(Un)Locking keys for lockable objects!
This mod introduces a single new item in the inventory - a skeleton key. The key can be generated from a steel ingot, and then used on a lockable chest, a lockable door (or a lockable trapdoor, if you have my other mod). Any existing locking chest, or door will work.
Once the skeletonkey is used on a lockable item, it is converted to a node-specific key. The node-specific key is yellow, and will from there on only ever fit that one chest or door.
The key can then be given to a friend or other player, allowing them access to the chest contents or allowing them to open and close doors that they otherwise could not. They will have to wield the key and right-click the door or chest to interact with the item.
The key can be recycled in an oven, smelting it back to an ingot.
If the owner of the lockable node destroys that object, and puts a new lockable object back in the same position, the old key will not open the new lockable object. Keys are really specific to the chest they were used, and are useless afterwards.
An issue is currently that there's no way to distinguish keys from each other. oops. Better keep your keys in order. I am working on a method to rename items that will resolve this in the future.
Code: this is a fork from minetest_game:
https://github.com/sofar/minetest_game/tree/keys
License: equal to minetest_game (derivative)
(Un)Locking keys for lockable objects!
This mod introduces a single new item in the inventory - a skeleton key. The key can be generated from a steel ingot, and then used on a lockable chest, a lockable door (or a lockable trapdoor, if you have my other mod). Any existing locking chest, or door will work.
Once the skeletonkey is used on a lockable item, it is converted to a node-specific key. The node-specific key is yellow, and will from there on only ever fit that one chest or door.
The key can then be given to a friend or other player, allowing them access to the chest contents or allowing them to open and close doors that they otherwise could not. They will have to wield the key and right-click the door or chest to interact with the item.
The key can be recycled in an oven, smelting it back to an ingot.
If the owner of the lockable node destroys that object, and puts a new lockable object back in the same position, the old key will not open the new lockable object. Keys are really specific to the chest they were used, and are useless afterwards.
An issue is currently that there's no way to distinguish keys from each other. oops. Better keep your keys in order. I am working on a method to rename items that will resolve this in the future.
Code: this is a fork from minetest_game:
https://github.com/sofar/minetest_game/tree/keys
License: equal to minetest_game (derivative)
Last edited by sofar on Sat Dec 26, 2015 19:45, edited 1 time in total.
Re: [MOD]Keys to lockable chests, doors[WIP]
There is a 'node ownership' mod that allows editing a node's metadata via a formspec - perhaps that will suit this mod as well?sofar wrote:this mod adds
~snip~
An issue is currently that there's no way to distinguish keys from each other. oops. Better keep your keys in order. I am working on a method to rename items that will resolve this in the future.
+10
Re: [MOD]Keys to lockable chests, doors[WIP]
There are so many mods that implement mechanisms like that, they all feel somewhat artificial. I chose to do a clean implementation of one that requires no chat commands for that reason. And it should be fun to play as well - instead of typing in some metadata in a form the player can now physically hand a key to a friend - that just has so much more gameplay value.KCoombes wrote:There is a 'node ownership' mod that allows editing a node's metadata via a formspec - perhaps that will suit this mod as well?sofar wrote:this mod adds
~snip~
An issue is currently that there's no way to distinguish keys from each other. oops. Better keep your keys in order. I am working on a method to rename items that will resolve this in the future.
+10
Under the hood this mod uses node metadata, obviously. It honors the 'owner' field as well (relies on it, even). And yes, if you can edit node metadata, you can indeed look at this mod's variables, although there's nothing to do with that info, really.
The actual issue of keys not being identifiable has nothing to do with node metadata, but with ItemStack names. I should have a solution for it soon, though.
Re: [MOD]Keys to lockable chests, doors[WIP]
Where is download link?????
Can you add support for protected chest and protected doors from protector-redo mod? Because players already has this items and i don't want to delete them.
About keys names. For the first time you can add to the key name name of chest owner and name of item (for example "Key for sofar's chest").
Can you add support for protected chest and protected doors from protector-redo mod? Because players already has this items and i don't want to delete them.
About keys names. For the first time you can add to the key name name of chest owner and name of item (for example "Key for sofar's chest").
Re: [MOD]Keys to lockable chests, doors[WIP]
This "mod" currently integrates in the default minetest_game, since it's too involved to make it separate (it needs to modify the event handlers for all the doors and chests that lock). I haven't posted the code just yet, that will come soon (once the steel trapdoor merges in minetest_game, I think)amadin wrote:Where is download link?????
Can you add support for protected chest and protected doors from protector-redo mod? Because players already has this items and i don't want to delete them.
About keys names. For the first time you can add to the key name name of chest owner and name of item (for example "Key for sofar's chest").
I will _not_ add support for protection mods, mods that add custom lockable items should themselves write the code that make these keys work, not the other way around.
Item names are a core change, and I'm working on code to make that work - see my concept PR for minetest core on github.
Re: [MOD]Keys to lockable chests, doors[WIP]
Do you mean currently integrates in the default minetest_game 0.4.13 stable????? I don't saw any keys in craft guide. How can i get it with /giveme?
- everamzah
- Member
- Posts: 490
- Joined: Thu Jan 29, 2015 00:47
- GitHub: everamzah
- IRC: everamzah
- In-game: everamzah
Re: [MOD]Keys to lockable chests, doors[WIP]
minetest 0.4.13-dev is the version currently being worked on for minetest 0.4.14, or whatever the next version is. Oddly enough.
Re: [MOD]Keys to lockable chests, doors[WIP]
It's not in the official minetest_game.amadin wrote:Do you mean currently integrates in the default minetest_game 0.4.13 stable????? I don't saw any keys in craft guide. How can i get it with /giveme?
You can get the current code from my personal branch:
https://github.com/sofar/minetest_game/tree/keys
You'll need to replace your copy of minetest_game with this one, or install it as a separate game and choose that in the client.
Re: [MOD]Keys to lockable chests, doors[WIP]
Does this branch from stable 0.4.13 or development version? Can i replace only default mod and doors mod?
Re: [MOD]Keys to lockable chests, doors[WIP]
development, although it may apply to 0.4.13.amadin wrote:Does this branch from stable 0.4.13 or development version? Can i replace only default mod and doors mod?
Yes, the patch only changes default and doors mods, so you can omit the rest. You can also just fetch the patch and patch your own minetest_game to get the changeset.
Who is online
Users browsing this forum: Kazooo and 40 guests