Skip to content

Commit 088a8bf

Browse files
truedinoplayzSymcryptc
andauthored
edf: Add Pullout button to copy position and rotation together (#650)
Co-authored-by: Symcryptc <[email protected]>
1 parent c140520 commit 088a8bf

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

[editor]/editor_gui/client/elementproperties.lua

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ layout.pullout = {
4040
items = {
4141
"Clone",
4242
"Delete",
43+
"CopyPOS",
4344
}
4445
}
4546
layout.line = {
@@ -1046,3 +1047,9 @@ function pulloutAction.Delete()
10461047
move_keyboard.disable()
10471048
end
10481049

1050+
function pulloutAction.CopyPOS()
1051+
local x, y, z = getElementPosition(selectedElement)
1052+
local rx, ry, rz = getElementRotation(selectedElement)
1053+
setClipboard(x..","..y..","..z..","..rx..","..ry..","..rz)
1054+
outputChatBox("Position "..x..","..y..","..z..","..rx..","..ry..","..rz.." copied to clipboard")
1055+
end

0 commit comments

Comments
 (0)