TheTermos / mobkit

Entity API for Minetest
MIT License
26 stars 12 forks source link

game crashes if nodebox is nil #3

Closed berengma closed 5 years ago

berengma commented 5 years ago

makes a server unplayable because game crashes repeatedly when a mob meets a node with nodebox = nil.

easy solution line 180: if node.drawtype == 'nodebox' then if node.node_box == nil then return nil end -- <- This is new and to be added if node.node_box.type == 'fixed' then

TheTermos commented 5 years ago

First I need to investigate why such a node exists, then maybe I'll be able to determine the height instead of making it impassable by returning nil.

Would be grateful if you'd be kind to temporarily add this to your local fix and report the result:

if node.node_box == nil then minetest.chat_send_all('nodeboxless: '.. node.name) return nil end

berengma commented 5 years ago

good idea.

i tried to find it with grep yesterday, but failed in using the right parameters and sorting output

berengma commented 5 years ago

it is farming_redo on Lilly:

2019-10-07 22:39:00: ACTION[Server]: [mobkit] farming:melon_8 uses nodebox without node_box defined

TheTermos commented 5 years ago

Thanks, master updated, please check if it solved the problem.

berengma commented 5 years ago

mobkit updated on server, until now it is save, even with players and mobs near melons

TheTermos commented 5 years ago

Case closed then, thanks!