mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 10:31:50 +00:00
update block.raycast docs
This commit is contained in:
parent
9cec475866
commit
498b4c3694
2 changed files with 7 additions and 1 deletions
|
|
@ -489,13 +489,16 @@ block.raycast(start: vec3, dir: vec3, max_distance: number) -> {
|
|||
iendpoint: vec3, -- position of the block hit by the ray
|
||||
length: number, -- ray length
|
||||
normal: vec3, -- normal vector of the surface hit by the ray
|
||||
[optional] dest: table -- destination table
|
||||
} or nil
|
||||
```
|
||||
|
||||
Casts a ray from the start point in the direction of dir. Max_distance specifies the maximum ray length.
|
||||
Casts a ray from the start point in the direction of *dir*. Max_distance specifies the maximum ray length.
|
||||
|
||||
The function returns a table with the results or nil if the ray does not hit any block.
|
||||
|
||||
The result will use the destination table instead of creating a new one if the optional argument specified.
|
||||
|
||||
## *item* library
|
||||
|
||||
```python
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue