minetest.line_of_sight

From Minetest Developer Wiki
Jump to: navigation, search

Syntax

minetest.line_of_sight(pos1, pos2, stepsize)

Description

Returns true/false, pos

  • Check if there is a direct line of sight between pos1 and pos2
  • Returns the position of the blocking node when false
  • pos1 First position
  • pos2 Second position
  • stepsize smaller gives more accurate results but requires more computing time. Default is 1.



This article is missing examples, feel free to add them.




This article is incomplete.


Personal tools
Namespaces

Variants
Actions
Navigation
API
Toolbox