Add the rotation operation to the previous blog.

Source: Internet
Author: User
Tags xform

-- This is very useful for the rule axis script that needs to be compiled. It is still a bit confusing for modeling,
-- $ [1]. Pos = $ [2]. Pos
--- The idea already exists, but it is to find out how many factors are selected, such as the question.
---*************************************** *****************************
-- 2011.4.15 understands what the range box is,
-- The range box is just a reference. When the basic operation is performed (that is, there is no modifier on the modification Panel), it does not change. However, after the modifier is added, the modifier is added to the base according to its own direction,
--- We found that we had no solution after using max for more than five years.
--- If the modifier we want to add is global-based, it will take a long time.
-- To put it bluntly, it is better to return to zero and add the rotation to return to zero.
-- I don't have to add the XForm
---
Macroscript gt_xform_ling

Category: "gaitian tool"
Buttontext: "XForm"
Tooltip: "XForm"
(
Try (
FN gt_xform_tt =
(
--- The following process needs to be calculated.
-- 1. First find the object's Transform
-- 2. Add a modifier to return the object to zero.
-- 3. Turning his gizmo
-- 4. Collapse it

-- The script specifies that the rotation of an object is processed, and the scaling of the object is also processed.
For I in selection do
(
OO = [I. Rotation. x_rotation, I. Rotation. y_rotation, I. Rotation. z_rotation]
-- I changed my mind during production. That's all.
Pos_pos = I. Pos

I. Rotation. x_rotation = 0
I. Rotation. y_rotation = 0
I. Rotation. z_rotation = 0

--- Process scaling
Secle_a = I. Scale

I. Scale = [1, 1]

Addmodifier I (XForm ())


I. modifiers [1]. Gizmo [2]. Controller [1]. value = OO [1]
I. modifiers [1]. Gizmo [2]. Controller [2]. value = OO [2]
I. modifiers [1]. Gizmo [2]. Controller [3]. value = OO [3]

I. modifiers [1]. Gizmo [3]. Controller. value = secle_a

Converteci editable_poly
)
--- The above is the script solution process. Now I have a deep understanding of XForm.


)
Gt_xform_tt ()
) Catch ()


)
-- [$. Rotation. x_rotation, $. Rotation. y_rotation, $. Rotation. z_rotation]
-- No matter how many axes are
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.