From 2960c16afb5ef2bfedacf2567f01ad4af1019587 Mon Sep 17 00:00:00 2001 From: bi0qaw Date: Sat, 25 Nov 2017 16:30:34 +0100 Subject: [PATCH] Updated Frame (markdown) --- Frame.md | 36 +++++++++++++++++------------------- 1 file changed, 17 insertions(+), 19 deletions(-) diff --git a/Frame.md b/Frame.md index 8123e71..9351406 100644 --- a/Frame.md +++ b/Frame.md @@ -1,3 +1,20 @@ +``` +frame of %entity% +``` +Creates a frame from an entities orientation. Returns a frame object. + +``` +frame with yaw %number% and pitch %number% +``` +Creates a frame with a custom yaw and pitch. Returns a frame object. + +``` +%vectors% in %frame% +``` +Converts the vectors from the Minecraft coordinate system to the frame coordinates. Returns a new list of vectors. + +*** + Frames are used whenever you want to change the direction of a bunch of vectors. Instead of rotating the list of vectors you can just grab a frame and let it do the correct rotations. This is best shown with a small example: ![](https://i.imgur.com/ObIhdQz.png?1) ![](https://i.imgur.com/iWdfVQ2.png?1) @@ -21,25 +38,6 @@ You can see that the circle is still in the "*horizontal*" XZ-plane but the whol *** -## Syntax - -``` -frame of %entity% -``` -Creates a frame from an entities orientation. Returns a frame object. - -``` -frame with yaw %number% and pitch %number% -``` -Creates a frame with a custom yaw and pitch. Returns a frame object. - -``` -%vectors% in %frame% -``` -Converts the vectors from the Minecraft coordinate system to the frame coordinates. Returns a new list of vectors. - -*** - ## When should I use frames? * When you need the same shape in multiple directions * When you need to update the direction of a shape over and over again