Modify look (#848)
* Added modify(e,'look',... * Added modify(e,'look',... * Not change yaw and pitch if vector length is 0 or straight up/down * Added to docs * Update docs/scarpet/api/Entities.md Co-authored-by: gnembon <41132274+gnembon@users.noreply.github.com>
This commit is contained in:
1 parent
47f8e0d26b
commit
6a06b0fb61
2 files changed
+22
-1
No files matched your search
@@ -589,6 +589,12 @@ Changes entity's location in the specified direction.
|
||||
|
||||
Changes entity's pitch or yaw angle.
|
||||
|
||||
### `modify(e, 'look', x, y, z), modify(e, 'look', [x,y,z] )`
|
||||
|
||||
Sets entity's 3d vector where the entity is looking.
|
||||
For cases where the vector has a length of 0, yaw and pitch won't get changed.
|
||||
When pointing straight up or down, yaw will stay the same.
|
||||
|
||||
### `modify(e, 'head_yaw', angle)`, `modify(e, 'body_yaw', angle)`
|
||||
|
||||
For living entities, controls their head and body yaw angle.
|
||||
|
||||
Reference in new issue
Block a user