Page 2 of 2

Posted: Mon Sep 30, 2013 13:03
by tinoesroho
Yeah, you can edit. Look in the "actionbar" beneath a post, to the right, and you should see Edit on your own. :-)

Re: [books] Books Mod

Posted: Tue Oct 14, 2014 15:56
by gamergardencat
10:47:21: ERROR[main]: ========== ERROR FROM LUA ===========
10:47:21: ERROR[main]: Failed to load and run script from
10:47:21: ERROR[main]: C:\Users\gamergardencat\Desktop\Workbench\MinetestMain\minetest-0.4.10-64bit\bin\..\mods\books\init.lua:
10:47:21: ERROR[main]: ...estMain\minetest-0.4.10-64bit\bin\..\mods\books\init.lua:121: unexpected symbol near 'then'

Lines 117-130

Code: Select all

minetest.register_on_punchnode(function(pos, node, puncher) 	
if node.name == "default:bookshelf" then
hit_with = puncher:get_wielded_item()				
if hit_with_name == "books:pencil" then
then
			local meta = minetest.env:get_meta(pointed_thing.under)
			meta:set_string("formspec", get_write_formspec(meta))
			meta:set_string("infotext", "Bookshelf (editable)")
			itemstack:add_wear(65535/50)
			return itemstack
		end
	end,
})
Misplaced then?
minetest.register_on_punchnode looks like old api. Or maybe not. http://dev.minetest.net/minetest.register_on_punchnode

Re: [books] Books Mod

Posted: Tue Oct 14, 2014 16:15
by gamergardencat
Replacement code.

Code: Select all

minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
	if puncher:get_wielded_item():get_name() == "default:bookshelf"
  then
    hit_with = puncher:get_wielded_item()
    if hit_with_name == "books:pencil"
    then
      local meta = minetest.env:get_meta(pointed_thing.under)
        meta:set_string("formspec", get_write_formspec(meta))
        meta:set_string("infotext", "Bookshelf (editable)")
        itemstack:add_wear(65535/50)
        return itemstack
    end
  end
end)
Image

I don't see how to write in it.

Re: [books] Books Mod

Posted: Thu Jan 01, 2015 21:47
by gumangel
i cant start a new line i press shift+(a specific key) to write | but is not working.beside that the mod is amazing!

Re: [books] Books Mod

Posted: Thu Jan 01, 2015 21:59
by tinoesroho
Hi!

Sorry to hear that it's broken. I don't maintain this mod, but you should check out it's modern successor: Bookex. Kaeza includes it as part of his mods collection - you can download it all as a zip, here.

Re: [books] Books Mod

Posted: Fri Jan 02, 2015 10:09
by gumangel
tinoesroho wrote:Hi!

Sorry to hear that it's broken. I don't maintain this mod, but you should check out it's modern successor: Bookex. Kaeza includes it as part of his mods collection - you can download it all as a zip, here.
thank you really much!