<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=ThigasSCR</id>
	<title>Multi Theft Auto: Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=ThigasSCR"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/wiki/Special:Contributions/ThigasSCR"/>
	<updated>2026-05-08T07:19:51Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=74486</id>
		<title>GetElementBoneRotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=74486"/>
		<updated>2022-04-26T18:20:59Z</updated>

		<summary type="html">&lt;p&gt;ThigasSCR: /* Example 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Added feature/item|1.5.9|1.5.8|20704|Returns the orientation of a specific bone relative to the [[element]]. Currently the [[Element/Player|Player]] and [[Element/Ped|Ped]] element types are accepted.}}&lt;br /&gt;
{{Tip|If you want to attach an element to a bone, see [[attachElementToBone]].}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementBoneRotation ( element theElement, int boneId )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:The-yaw-pitch-and-roll-angles-in-the-human-head-motion-11.png|thumb|Rotation axes]]&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theElement:''' the [[element]] to get the bone rotation on.&lt;br /&gt;
*'''boneId:''' the ID of the bone to get the rotation of. See [[Bone IDs]].&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns 3 [[Float|floats]], representing the yaw, pitch, roll rotation values.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the yaw, pitch and roll orientation of a specific bone relative to the local player bone specified through a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function getBoneRotation (commandName, boneId)&lt;br /&gt;
    if not tonumber (boneId) then&lt;br /&gt;
        outputChatBox (&amp;quot;You didn't insert an bone ID!&amp;quot;, 255, 0, 0)&lt;br /&gt;
        return false&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    local x, y, z = getElementBoneRotation (localPlayer, boneId)&lt;br /&gt;
    outputChatBox (&amp;quot;The bone rotation is: &amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, getBoneRotation)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Example 2==&lt;br /&gt;
This example takes the current rotation of all player bones. by ThigasDEV&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local settings = {&lt;br /&gt;
    copyDiscord = false; -- true = &amp;quot;yes&amp;quot; // false = &amp;quot;no&amp;quot; - Copy to paste table in discord format.&lt;br /&gt;
    tableName = &amp;quot;bonesPos&amp;quot;; -- Table name to be copied.&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
local boneIDs = {0, 1, 2, 3, 4, 5, 6, 7, 8, 21, 22, 23, 24, 25, 26, 31, 32, 33, 34, 35, 36, 41, 42, 43, 44, 51, 52, 53, 54, 201, 301, 302}&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, function ()&lt;br /&gt;
    local bonesPositions = { }&lt;br /&gt;
    local bonesConverted = &amp;quot;&amp;quot;&lt;br /&gt;
    for _, v in ipairs (boneIDs) do&lt;br /&gt;
        local x, y, z = getElementBoneRotation (localPlayer, v)&lt;br /&gt;
        table.insert (bonesPositions, &amp;quot;[&amp;quot;..v..&amp;quot;] = {&amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z..&amp;quot;};&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
    for i, v in ipairs (bonesPositions) do&lt;br /&gt;
        bonesConverted = &amp;quot;    &amp;quot;..bonesConverted..&amp;quot;\n&amp;quot;..&amp;quot;    &amp;quot;..v&lt;br /&gt;
    end&lt;br /&gt;
    setClipboard ((settings[&amp;quot;copyDiscord&amp;quot;] and &amp;quot;```lua\nlocal &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}\n```&amp;quot; or &amp;quot;local &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}&amp;quot;))&lt;br /&gt;
    outputChatBox (&amp;quot;Copy to clipboard.&amp;quot;)&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|n/a|1.5.8-9.20704|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_element_functions}}&lt;/div&gt;</summary>
		<author><name>ThigasSCR</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73154</id>
		<title>GetElementBoneRotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73154"/>
		<updated>2021-12-11T18:37:01Z</updated>

		<summary type="html">&lt;p&gt;ThigasSCR: /* Example 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Added feature/item|1.5.9|1.5.8|20704|Returns the orientation of a specific bone relative to the [[element]]. Currently the [[Element/Player|Player]] and [[Element/Ped|Ped]] element types are accepted.}}&lt;br /&gt;
{{Tip|If you want to attach an element to a bone, see [[attachElementToBone]].}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementBoneRotation ( element theElement, int boneId )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:The-yaw-pitch-and-roll-angles-in-the-human-head-motion-11.png|thumb|Rotation axes]]&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theElement:''' the [[element]] to get the bone rotation on.&lt;br /&gt;
*'''boneId:''' the ID of the bone to get the rotation of. See [[Bone IDs]].&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns 3 [[Float|floats]], representing the yaw, pitch, roll rotation values.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the yaw, pitch and roll orientation of a specific bone relative to the local player bone specified through a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function getBoneRotation (commandName, boneId)&lt;br /&gt;
    if not tonumber (boneId) then&lt;br /&gt;
        outputChatBox (&amp;quot;You didn't insert an bone ID!&amp;quot;, 255, 0, 0)&lt;br /&gt;
        return false&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    local x, y, z = getElementBoneRotation (localPlayer, boneId)&lt;br /&gt;
    outputChatBox (&amp;quot;The bone rotation is: &amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, getBoneRotation)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Example 2==&lt;br /&gt;
This example takes the current rotation of all player bones.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local settings = {&lt;br /&gt;
    copyDiscord = false; -- true = &amp;quot;yes&amp;quot; // false = &amp;quot;no&amp;quot; - Copy to paste table in discord format.&lt;br /&gt;
    tableName = &amp;quot;bonesPos&amp;quot;; -- Table name to be copied.&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
local boneIDs = {0, 1, 2, 3, 4, 5, 6, 7, 8, 21, 22, 23, 24, 25, 26, 31, 32, 33, 34, 35, 36, 41, 42, 43, 44, 51, 52, 53, 54, 201, 301, 302}&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, function ()&lt;br /&gt;
    local bonesPositions = { }&lt;br /&gt;
    local bonesConverted = &amp;quot;&amp;quot;&lt;br /&gt;
    for _, v in ipairs (boneIDs) do&lt;br /&gt;
        local x, y, z = getElementBoneRotation (localPlayer, v)&lt;br /&gt;
        table.insert (bonesPositions, &amp;quot;[&amp;quot;..v..&amp;quot;] = {&amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z..&amp;quot;};&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
    for i, v in ipairs (bonesPositions) do&lt;br /&gt;
        bonesConverted = &amp;quot;    &amp;quot;..bonesConverted..&amp;quot;\n&amp;quot;..&amp;quot;    &amp;quot;..v&lt;br /&gt;
    end&lt;br /&gt;
    setClipboard ((settings[&amp;quot;copyDiscord&amp;quot;] and &amp;quot;```lua\nlocal &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}\n```&amp;quot; or &amp;quot;local &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}&amp;quot;))&lt;br /&gt;
    outputChatBox (&amp;quot;Copy to clipboard.&amp;quot;)&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|n/a|1.5.8-9.20704|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_element_functions}}&lt;/div&gt;</summary>
		<author><name>ThigasSCR</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73153</id>
		<title>GetElementBoneRotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73153"/>
		<updated>2021-12-11T18:35:28Z</updated>

		<summary type="html">&lt;p&gt;ThigasSCR: /* Example 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Added feature/item|1.5.9|1.5.8|20704|Returns the orientation of a specific bone relative to the [[element]]. Currently the [[Element/Player|Player]] and [[Element/Ped|Ped]] element types are accepted.}}&lt;br /&gt;
{{Tip|If you want to attach an element to a bone, see [[attachElementToBone]].}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementBoneRotation ( element theElement, int boneId )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:The-yaw-pitch-and-roll-angles-in-the-human-head-motion-11.png|thumb|Rotation axes]]&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theElement:''' the [[element]] to get the bone rotation on.&lt;br /&gt;
*'''boneId:''' the ID of the bone to get the rotation of. See [[Bone IDs]].&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns 3 [[Float|floats]], representing the yaw, pitch, roll rotation values.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the yaw, pitch and roll orientation of a specific bone relative to the local player bone specified through a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function getBoneRotation (commandName, boneId)&lt;br /&gt;
    if not tonumber (boneId) then&lt;br /&gt;
        outputChatBox (&amp;quot;You didn't insert an bone ID!&amp;quot;, 255, 0, 0)&lt;br /&gt;
        return false&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    local x, y, z = getElementBoneRotation (localPlayer, boneId)&lt;br /&gt;
    outputChatBox (&amp;quot;The bone rotation is: &amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, getBoneRotation)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Example 2==&lt;br /&gt;
This example takes the current rotation of all player bones.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local settings = {&lt;br /&gt;
    copyDiscord = false; -- true = &amp;quot;yes&amp;quot; // false = &amp;quot;no&amp;quot; - Copy to paste table in discord.&lt;br /&gt;
    tableName = &amp;quot;bonesPos&amp;quot;; -- Table name to be copied.&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
local boneIDs = {0, 1, 2, 3, 4, 5, 6, 7, 8, 21, 22, 23, 24, 25, 26, 31, 32, 33, 34, 35, 36, 41, 42, 43, 44, 51, 52, 53, 54, 201, 301, 302}&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, function ()&lt;br /&gt;
    local bonesPositions = { }&lt;br /&gt;
    local bonesConverted = &amp;quot;&amp;quot;&lt;br /&gt;
    for _, v in ipairs (boneIDs) do&lt;br /&gt;
        local x, y, z = getElementBoneRotation (localPlayer, v)&lt;br /&gt;
        table.insert (bonesPositions, &amp;quot;[&amp;quot;..v..&amp;quot;] = {&amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z..&amp;quot;};&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
    for i, v in ipairs (bonesPositions) do&lt;br /&gt;
        bonesConverted = &amp;quot;    &amp;quot;..bonesConverted..&amp;quot;\n&amp;quot;..&amp;quot;    &amp;quot;..v&lt;br /&gt;
    end&lt;br /&gt;
    setClipboard ((settings[&amp;quot;copyDiscord&amp;quot;] and &amp;quot;```lua\nlocal &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}\n```&amp;quot; or &amp;quot;local &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}&amp;quot;))&lt;br /&gt;
    outputChatBox (&amp;quot;Copy to clipboard.&amp;quot;)&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|n/a|1.5.8-9.20704|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_element_functions}}&lt;/div&gt;</summary>
		<author><name>ThigasSCR</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73152</id>
		<title>GetElementBoneRotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73152"/>
		<updated>2021-12-11T18:31:44Z</updated>

		<summary type="html">&lt;p&gt;ThigasSCR: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Added feature/item|1.5.9|1.5.8|20704|Returns the orientation of a specific bone relative to the [[element]]. Currently the [[Element/Player|Player]] and [[Element/Ped|Ped]] element types are accepted.}}&lt;br /&gt;
{{Tip|If you want to attach an element to a bone, see [[attachElementToBone]].}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementBoneRotation ( element theElement, int boneId )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:The-yaw-pitch-and-roll-angles-in-the-human-head-motion-11.png|thumb|Rotation axes]]&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theElement:''' the [[element]] to get the bone rotation on.&lt;br /&gt;
*'''boneId:''' the ID of the bone to get the rotation of. See [[Bone IDs]].&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns 3 [[Float|floats]], representing the yaw, pitch, roll rotation values.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the yaw, pitch and roll orientation of a specific bone relative to the local player bone specified through a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function getBoneRotation (commandName, boneId)&lt;br /&gt;
    if not tonumber (boneId) then&lt;br /&gt;
        outputChatBox (&amp;quot;You didn't insert an bone ID!&amp;quot;, 255, 0, 0)&lt;br /&gt;
        return false&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    local x, y, z = getElementBoneRotation (localPlayer, boneId)&lt;br /&gt;
    outputChatBox (&amp;quot;The bone rotation is: &amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, getBoneRotation)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Example 2==&lt;br /&gt;
This example takes the current rotation of all player bones.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local settings = {&lt;br /&gt;
    copyDiscord = false; -- true = &amp;quot;yes&amp;quot; // false = &amp;quot;no&amp;quot; - Copy to paste table in discord.&lt;br /&gt;
    tableName = &amp;quot;bonesPos&amp;quot;; -- Table name to be copied.&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
local boneIDs = {0, 1, 2, 3, 4, 5, 6, 7, 8, 21, 22, 23, 24, 25, 26, 31, 32, 33, 34, 35, 36, 41, 42, 43, 44, 51, 52, 53, 54, 201, 301, 302}&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, function ()&lt;br /&gt;
    local bonesPositions = { }&lt;br /&gt;
    local bonesConverted = &amp;quot;&amp;quot;&lt;br /&gt;
    for _, v in ipairs (boneIDs) do&lt;br /&gt;
        local x, y, z = getElementBoneRotation (localPlayer, v)&lt;br /&gt;
        table.insert (bonesPositions, &amp;quot;[&amp;quot;..v..&amp;quot;] = {&amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z..&amp;quot;};&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
    for i, v in ipairs (bonesPositions) do&lt;br /&gt;
        bonesConverted = &amp;quot;    &amp;quot;..bonesConverted..&amp;quot;\n&amp;quot;..&amp;quot;    &amp;quot;..v&lt;br /&gt;
    end&lt;br /&gt;
    setClipboard ((settings[&amp;quot;copyDiscord&amp;quot;] and &amp;quot;```lua\nlocal &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}\n```&amp;quot; or &amp;quot;local &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}&amp;quot;))&lt;br /&gt;
    outputChatBox (settings[&amp;quot;messageSend&amp;quot;])&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|n/a|1.5.8-9.20704|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_element_functions}}&lt;/div&gt;</summary>
		<author><name>ThigasSCR</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73151</id>
		<title>GetElementBoneRotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73151"/>
		<updated>2021-12-11T18:30:44Z</updated>

		<summary type="html">&lt;p&gt;ThigasSCR: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Added feature/item|1.5.9|1.5.8|20704|Returns the orientation of a specific bone relative to the [[element]]. Currently the [[Element/Player|Player]] and [[Element/Ped|Ped]] element types are accepted.}}&lt;br /&gt;
{{Tip|If you want to attach an element to a bone, see [[attachElementToBone]].}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementBoneRotation ( element theElement, int boneId )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:The-yaw-pitch-and-roll-angles-in-the-human-head-motion-11.png|thumb|Rotation axes]]&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theElement:''' the [[element]] to get the bone rotation on.&lt;br /&gt;
*'''boneId:''' the ID of the bone to get the rotation of. See [[Bone IDs]].&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns 3 [[Float|floats]], representing the yaw, pitch, roll rotation values.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the yaw, pitch and roll orientation of a specific bone relative to the local player bone specified through a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function getBoneRotation (commandName, boneId)&lt;br /&gt;
    if not tonumber (boneId) then&lt;br /&gt;
        outputChatBox (&amp;quot;You didn't insert an bone ID!&amp;quot;, 255, 0, 0)&lt;br /&gt;
        return false&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    local x, y, z = getElementBoneRotation (localPlayer, boneId)&lt;br /&gt;
    outputChatBox (&amp;quot;The bone rotation is: &amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, getBoneRotation)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example takes the current rotation of all player bones.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local settings = {&lt;br /&gt;
    copyDiscord = false; -- true = &amp;quot;yes&amp;quot; // false = &amp;quot;no&amp;quot; - Copy to paste table in discord.&lt;br /&gt;
    tableName = &amp;quot;bonesPos&amp;quot;; -- Table name to be copied.&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
local boneIDs = {0, 1, 2, 3, 4, 5, 6, 7, 8, 21, 22, 23, 24, 25, 26, 31, 32, 33, 34, 35, 36, 41, 42, 43, 44, 51, 52, 53, 54, 201, 301, 302}&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, function ()&lt;br /&gt;
    local bonesPositions = { }&lt;br /&gt;
    local bonesConverted = &amp;quot;&amp;quot;&lt;br /&gt;
    for _, v in ipairs (boneIDs) do&lt;br /&gt;
        local x, y, z = getElementBoneRotation (localPlayer, v)&lt;br /&gt;
        table.insert (bonesPositions, &amp;quot;[&amp;quot;..v..&amp;quot;] = {&amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z..&amp;quot;};&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
    for i, v in ipairs (bonesPositions) do&lt;br /&gt;
        bonesConverted = &amp;quot;    &amp;quot;..bonesConverted..&amp;quot;\n&amp;quot;..&amp;quot;    &amp;quot;..v&lt;br /&gt;
    end&lt;br /&gt;
    setClipboard ((settings[&amp;quot;copyDiscord&amp;quot;] and &amp;quot;```lua\nlocal &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}\n```&amp;quot; or &amp;quot;local &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}&amp;quot;))&lt;br /&gt;
    outputChatBox (settings[&amp;quot;messageSend&amp;quot;])&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|n/a|1.5.8-9.20704|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_element_functions}}&lt;/div&gt;</summary>
		<author><name>ThigasSCR</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73150</id>
		<title>GetElementBoneRotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73150"/>
		<updated>2021-12-11T18:26:55Z</updated>

		<summary type="html">&lt;p&gt;ThigasSCR: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Added feature/item|1.5.9|1.5.8|20704|Returns the orientation of a specific bone relative to the [[element]]. Currently the [[Element/Player|Player]] and [[Element/Ped|Ped]] element types are accepted.}}&lt;br /&gt;
{{Tip|If you want to attach an element to a bone, see [[attachElementToBone]].}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementBoneRotation ( element theElement, int boneId )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:The-yaw-pitch-and-roll-angles-in-the-human-head-motion-11.png|thumb|Rotation axes]]&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theElement:''' the [[element]] to get the bone rotation on.&lt;br /&gt;
*'''boneId:''' the ID of the bone to get the rotation of. See [[Bone IDs]].&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns 3 [[Float|floats]], representing the yaw, pitch, roll rotation values.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the yaw, pitch and roll orientation of a specific bone relative to the local player bone specified through a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function getBoneRotation (commandName, boneId)&lt;br /&gt;
    if not tonumber (boneId) then&lt;br /&gt;
        outputChatBox (&amp;quot;You didn't insert an bone ID!&amp;quot;, 255, 0, 0)&lt;br /&gt;
        return false&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    local x, y, z = getElementBoneRotation (localPlayer, boneId)&lt;br /&gt;
    outputChatBox (&amp;quot;The bone rotation is: &amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, getBoneRotation)&lt;br /&gt;
&lt;br /&gt;
-- Other Example.&lt;br /&gt;
&lt;br /&gt;
local settings = {&lt;br /&gt;
    copyDiscord = false; -- true = &amp;quot;yes&amp;quot; // false = &amp;quot;no&amp;quot; - Copy to paste table in discord.&lt;br /&gt;
    tableName = &amp;quot;bonesPos&amp;quot;; -- Table name to be copied.&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
local boneIDs = {0, 1, 2, 3, 4, 5, 6, 7, 8, 21, 22, 23, 24, 25, 26, 31, 32, 33, 34, 35, 36, 41, 42, 43, 44, 51, 52, 53, 54, 201, 301, 302}&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, function ()&lt;br /&gt;
    local bonesPositions = { }&lt;br /&gt;
    local bonesConverted = &amp;quot;&amp;quot;&lt;br /&gt;
    for _, v in ipairs (boneIDs) do&lt;br /&gt;
        local x, y, z = getElementBoneRotation (localPlayer, v)&lt;br /&gt;
        table.insert (bonesPositions, &amp;quot;[&amp;quot;..v..&amp;quot;] = {&amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z..&amp;quot;};&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
    for i, v in ipairs (bonesPositions) do&lt;br /&gt;
        bonesConverted = &amp;quot;    &amp;quot;..bonesConverted..&amp;quot;\n&amp;quot;..&amp;quot;    &amp;quot;..v&lt;br /&gt;
    end&lt;br /&gt;
    setClipboard ((settings[&amp;quot;copyDiscord&amp;quot;] and &amp;quot;```lua\nlocal &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}\n```&amp;quot; or &amp;quot;local &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}&amp;quot;))&lt;br /&gt;
    outputChatBox (settings[&amp;quot;messageSend&amp;quot;])&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|n/a|1.5.8-9.20704|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_element_functions}}&lt;/div&gt;</summary>
		<author><name>ThigasSCR</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73149</id>
		<title>GetElementBoneRotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=GetElementBoneRotation&amp;diff=73149"/>
		<updated>2021-12-11T18:25:26Z</updated>

		<summary type="html">&lt;p&gt;ThigasSCR: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
{{Client function}}&lt;br /&gt;
{{Added feature/item|1.5.9|1.5.8|20704|Returns the orientation of a specific bone relative to the [[element]]. Currently the [[Element/Player|Player]] and [[Element/Ped|Ped]] element types are accepted.}}&lt;br /&gt;
{{Tip|If you want to attach an element to a bone, see [[attachElementToBone]].}}&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
float, float, float getElementBoneRotation ( element theElement, int boneId )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:The-yaw-pitch-and-roll-angles-in-the-human-head-motion-11.png|thumb|Rotation axes]]&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''theElement:''' the [[element]] to get the bone rotation on.&lt;br /&gt;
*'''boneId:''' the ID of the bone to get the rotation of. See [[Bone IDs]].&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns 3 [[Float|floats]], representing the yaw, pitch, roll rotation values.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example outputs the yaw, pitch and roll orientation of a specific bone relative to the local player bone specified through a command:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function getBoneRotation (commandName, boneId)&lt;br /&gt;
    if not tonumber (boneId) then&lt;br /&gt;
        outputChatBox (&amp;quot;You didn't insert an bone ID!&amp;quot;, 255, 0, 0)&lt;br /&gt;
        return false&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    local x, y, z = getElementBoneRotation (localPlayer, boneId)&lt;br /&gt;
    outputChatBox (&amp;quot;The bone rotation is: &amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, getBoneRotation)&lt;br /&gt;
&lt;br /&gt;
local settings = {&lt;br /&gt;
    copyDiscord = false; -- true = &amp;quot;sim / yes&amp;quot; // false = &amp;quot;não / no&amp;quot; - Copiar para colar a tabela no discord / &lt;br /&gt;
Copy to paste table in discord.&lt;br /&gt;
    tableName = &amp;quot;bonesPos&amp;quot;; -- Nome da tabela que será copiado / &lt;br /&gt;
Table name to be copied.&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
local boneIDs = {0, 1, 2, 3, 4, 5, 6, 7, 8, 21, 22, 23, 24, 25, 26, 31, 32, 33, 34, 35, 36, 41, 42, 43, 44, 51, 52, 53, 54, 201, 301, 302}&lt;br /&gt;
&lt;br /&gt;
addCommandHandler (&amp;quot;getbonerotation&amp;quot;, function ()&lt;br /&gt;
    local bonesPositions = { }&lt;br /&gt;
    local bonesConverted = &amp;quot;&amp;quot;&lt;br /&gt;
    for _, v in ipairs (boneIDs) do&lt;br /&gt;
        local x, y, z = getElementBoneRotation (localPlayer, v)&lt;br /&gt;
        table.insert (bonesPositions, &amp;quot;[&amp;quot;..v..&amp;quot;] = {&amp;quot;..x..&amp;quot;, &amp;quot;..y..&amp;quot;, &amp;quot;..z..&amp;quot;};&amp;quot;)&lt;br /&gt;
    end&lt;br /&gt;
    for i, v in ipairs (bonesPositions) do&lt;br /&gt;
        bonesConverted = &amp;quot;    &amp;quot;..bonesConverted..&amp;quot;\n&amp;quot;..&amp;quot;    &amp;quot;..v&lt;br /&gt;
    end&lt;br /&gt;
    setClipboard ((settings[&amp;quot;copyDiscord&amp;quot;] and &amp;quot;```lua\nlocal &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}\n```&amp;quot; or &amp;quot;local &amp;quot;..string.gsub(settings[&amp;quot;tableName&amp;quot;], &amp;quot; &amp;quot;, &amp;quot;_&amp;quot;)..&amp;quot; = {&amp;quot;..bonesConverted..&amp;quot;\n}&amp;quot;))&lt;br /&gt;
    outputChatBox (settings[&amp;quot;messageSend&amp;quot;])&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|n/a|1.5.8-9.20704|}}&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{Client_element_functions}}&lt;/div&gt;</summary>
		<author><name>ThigasSCR</name></author>
	</entry>
</feed>