/set transform 1 = Get piece's global position and rotation.
/set transform X Y Z A B C T
/set transform Global Origin Position(X, Y, Z), Rotation(A, B, C), Rotation Accumulation(T)
Apparently you can't modify a rectangular piece to have a trapezoid-like shape in which the side on one end of an axis is smaller than the side on the other end of the same axis.
This behavior is challenging to work with. The only way you'll really be able to use this practically is by feeding in desired coordinates into a script, and having it spit out a scale, position, and axis angle parameter for you. What's happening here is a non-normalized rotation is being fed directly into the homogeneous vertex transformation matrix. A well formed matrix will normally enable you to scale a shape, move a shape in worldspace, and perform any sort of orientation through a single vector-matrix multiplication for each vertex in the shapefile.
The code that transforms axis-angles into this rotation matrix assumes that the axis given is of unit length (plus or minus machine epsilon). If that's not the case, the first 3x3 part of the matrix (scale parameters along the diagonal, rotation params over the entire 3x3 area) will inconsistently "cancel out" the orientation specific transformation. In effect, this lets you do a shear transformation for all 3 axises.
Since the shear values aren't being set directly, and are as a consequence of the invalid rotation parameter, it's really bloody hard to control the sheer transform you get from it, and keep sane orientation. Certainly well beyond the mental capabilities of a human. I'm also not exactly sure that you'll be able to set rotation and these sheer parameters completely independently. So, even with a script, it might only be possible to select sheer parameters for a subset of possible orientations.
It's certainly possible to write a script that would take four object-space coordinates in 3D and give you the scale/transform parameters to sheer a piece to have four corners where specified (the other four corners would be in their fixed mirror image positions). I don't know if you'll be able to spin that piece around without affecting the shear params. If there's not enough freedom in the rotation specification to set them independently, it might be possible to shear one or two of the axises, instead of all three and specify free rotation.
In any case, it's some extremely nasty linear algebra to make such a script happen.
Since it seems none of us can use the command to its full potential, I figure it's at least useful if you want to make sure what you're building conforms to the 3 axises of the map.
One way to do so is using /set transform X Y Z 0 0 0 0 , where X Y and Z are where in the coordinate space you want the orientation for your base piece (Integer values recommended) and the 0's keep your piece completely level and the sides conform to the corresponding axises.
Can't really simplify that any further without having to go through the trouble of making a diagram.
Comments
[img]http://iplop.the-construct.net/T2/what the hell 3.png[/img]
[img]http://iplop.the-construct.net/T2/what the hell 4.png[/img]
/set transform (piece pos) 1 1 0 3.14 (or something similar)
to make it a diamond ;o
/set transform X Y Z A B C T
/set transform Global Origin Position(X, Y, Z), Rotation(A, B, C), Rotation Accumulation(T)
I THINK that's how it works.
awesome find though
I am sad now.
I never tried using them to fill oddly shaped gaps, but I'd imagine they're hard to work with
The code that transforms axis-angles into this rotation matrix assumes that the axis given is of unit length (plus or minus machine epsilon). If that's not the case, the first 3x3 part of the matrix (scale parameters along the diagonal, rotation params over the entire 3x3 area) will inconsistently "cancel out" the orientation specific transformation. In effect, this lets you do a shear transformation for all 3 axises.
Since the shear values aren't being set directly, and are as a consequence of the invalid rotation parameter, it's really bloody hard to control the sheer transform you get from it, and keep sane orientation. Certainly well beyond the mental capabilities of a human. I'm also not exactly sure that you'll be able to set rotation and these sheer parameters completely independently. So, even with a script, it might only be possible to select sheer parameters for a subset of possible orientations.
It's certainly possible to write a script that would take four object-space coordinates in 3D and give you the scale/transform parameters to sheer a piece to have four corners where specified (the other four corners would be in their fixed mirror image positions). I don't know if you'll be able to spin that piece around without affecting the shear params. If there's not enough freedom in the rotation specification to set them independently, it might be possible to shear one or two of the axises, instead of all three and specify free rotation.
In any case, it's some extremely nasty linear algebra to make such a script happen.
One way to do so is using /set transform X Y Z 0 0 0 0 , where X Y and Z are where in the coordinate space you want the orientation for your base piece (Integer values recommended) and the 0's keep your piece completely level and the sides conform to the corresponding axises.
Can't really simplify that any further without having to go through the trouble of making a diagram.