minetest-LOTR / Lord-of-the-Test

LOTR-inspired Subgame for Minetest. Rewrite: https://github.com/minetest-LOTR/Third-Age
Other
67 stars 31 forks source link

`lottthrowing` mod crash #181

Closed MoNTE48 closed 2 years ago

MoNTE48 commented 2 years ago

https://github.com/minetest-LOTR/Lord-of-the-Test/blob/master/mods/lottthrowing/fire_arrow.lua#L103

ModError: ModError: Failed to load and run script from
.../games/lordofthetest/mods/lottthrowing/init.lua: .../games/lordofthetest/mods/lottthrowing/fire_arrow.lua:103:
attempt to perform arithmetic on global 'LIGHT_MAX' (a nil value) stack traceback:
.../games/lordofthetest/mods/lottthrowing/fire_arrow.lua:103: in main chunk [C]: in function 'dofile'
.../games/lordofthetest/mods/lottthrowing/init.lua:432: in main chunk Check debug.txt for details.

LIGHT_MAX should be minetest.LIGHT_MAX

neinwhal commented 2 years ago

Bit of code rot I suppose; But it should technically work, since its a global variable defined at https://github.com/minetest-LOTR/Lord-of-the-Test/blob/master/mods/default/init.lua#L9 But yeah, lottthrowing needs a cleanup, I'll do that soon and that should remedy this issue too.

neinwhal commented 2 years ago

https://github.com/minetest-LOTR/Lord-of-the-Test/commit/c07b06d14821a2b72a9881be13cfa334d44b66ac