rubenwardy wrote:It would have to be a separate api function, as returning an object would equate to true, which will break old mods.
rubenwardy wrote:It would have to be a separate api function, as returning an object would equate to true, which will break old mods.
PilzAdam wrote:We could also return false, blocking_node
stu wrote:PilzAdam wrote:We could also return false, blocking_node
But wouldn't returning a table still be interpreted as not-nil? It's a real pity as i can think of a number of potential uses for
such a silmple modification.
PilzAdam wrote:Not a table, in Lua functions can have more than one return value.
if not minetest.line_of_sight(p1, p2) then
--code here
end
rubenwardy wrote:I used it in capture the flag 3 months ago.
Users browsing this forum: No registered users and 13 guests