[RESOLVED]error #5 register_item_raw

Post Reply
User avatar
ulla
Member
Posts: 146
Joined: Wed Feb 04, 2015 09:22
GitHub: IIIullaIII
IRC: ulla
In-game: ulla

[RESOLVED]error #5 register_item_raw

by ulla » Post

Hi i update minetest in manjaro archlinux from 5.1 to 5.3 now i have problem with my mod

Code: Select all

ModError: Failed to load and run script from C:\Users\ulla\Downloads\minetest-5.3.0-win64\bin\..\mods\CANNABIS_MOD\init.lua:
...ds\minetest-5.3.0-win64\bin\..\builtin\game\register.lua:182: bad argument #5 to 'register_item_raw' (table expected, got string)
stack traceback:
	[C]: in function 'register_item_raw'
	...ds\minetest-5.3.0-win64\bin\..\builtin\game\register.lua:182: in function 'register_item'
	...ds\minetest-5.3.0-win64\bin\..\builtin\game\register.lua:208: in function 'register_node'
	...t-5.3.0-win64\bin\..\mods\CANNABIS_MOD/canapa.lua:5: in main chunk
	[C]: in function 'dofile'
	...est-5.3.0-win64\bin\..\mods\CANNABIS_MOD\init.lua:23: in main chunk
Controlla debug.txt per i dettagli.
someone can help me.?
The string n 5 of my script is simple minetest.register_node...........
Last edited by ulla on Mon Aug 17, 2020 10:07, edited 1 time in total.
X4cna2d4UqsiawIzUumDgPoYNx3JLGII

User avatar
Andrey01
Member
Posts: 2596
Joined: Wed Oct 19, 2016 15:18
GitHub: Andrey2470T
In-game: Andrey01
Location: Russia, Moscow

Re: error #5 register_item_raw

by Andrey01 » Post

I had the same problem with your mod and opened the issue in your repo: https://github.com/IIIullaIII/CANNABIS_MOD/issues/4 Since I had not got a reply, I decided to fix it in my local copy of your mod. On 19th line

Code: Select all

sounds = "cannabis_canapa_s", 
that has to be a table: https://github.com/minetest/minetest/bl ... .txt#L7206

User avatar
ulla
Member
Posts: 146
Joined: Wed Feb 04, 2015 09:22
GitHub: IIIullaIII
IRC: ulla
In-game: ulla

Re: error #5 register_item_raw

by ulla » Post

Andrey01 wrote:
Mon Aug 17, 2020 07:50
I had the same problem with your mod and opened the issue in your repo: https://github.com/IIIullaIII/CANNABIS_MOD/issues/4 Since I had not got a reply, I decided to fix it in my local copy of your mod. On 19th line

Code: Select all

sounds = "cannabis_canapa_s", 
that has to be a table: https://github.com/minetest/minetest/bl ... .txt#L7206
Thank you for answer
yes the problem is sounds
need table

Code: Select all

sounds = "cannabis_canapa_s", 
i correct
with

Code: Select all

sounds = {"cannabis_canapa_s"}, 
same problem with my mod mobu
i going fix and update all two
first i want see if table work then with old version or if ineed create a new repository for 5.3+
X4cna2d4UqsiawIzUumDgPoYNx3JLGII

User avatar
ulla
Member
Posts: 146
Joined: Wed Feb 04, 2015 09:22
GitHub: IIIullaIII
IRC: ulla
In-game: ulla

Re: error #5 register_item_raw

by ulla » Post

ulla wrote:
Mon Aug 17, 2020 10:02
Andrey01 wrote:
Mon Aug 17, 2020 07:50
I had the same problem with your mod and opened the issue in your repo: https://github.com/IIIullaIII/CANNABIS_MOD/issues/4 Since I had not got a reply, I decided to fix it in my local copy of your mod. On 19th line

Code: Select all

sounds = "cannabis_canapa_s", 
that has to be a table: https://github.com/minetest/minetest/bl ... .txt#L7206
Thank you for answer
yes the problem is sounds
need table

Code: Select all

sounds = "cannabis_canapa_s", 
i correct
with

Code: Select all

sounds = {"cannabis_canapa_s"}, 
same problem with my mod mobu
i going fix and update all two
first i want see if table work then with old version or if ineed create a new repository for 5.3+
P.S. the problem is not only line 19 but is in all sounds = "......." i have updated cannabis mod summer mod nodeu and mobu
X4cna2d4UqsiawIzUumDgPoYNx3JLGII

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests