add "include_non_selectable" parameter to blocks raycast

This commit is contained in:
clasher113 2026-01-05 23:05:47 +02:00
parent ce769143f8
commit 8f1739c85b
10 changed files with 57 additions and 23 deletions

View file

@ -63,8 +63,9 @@ entities.get_all_in_radius(center: vec3, radius: number) -> array<int>
```
```lua
entities.raycast(start: vec3, dir: vec3, max_distance: number,
ignore: int, [optional] destination: table, [optional] filter: table) -> table or nil
entities.raycast(start: vec3, dir: vec3, max_distance: number, ignore: int, [optional] destination: table,
[optional] filter: table, [optional] include_non_selectable = false
) -> table or nil
```
The function is an extended version of [block.raycast](libblock.md#raycast). Returns a table with the results if the ray touches a block or entity.