For a project, I need to build a mosaic of squares, that align perfectly. Therefor I need to transform the squares by dragging one side slightly in or out (only one side!) so that the spaces inbetween are more or less the same. Every time I try to do this it mirrors the action horizontally or vertically, depending on which side I wanna drag. So the opposite side of the shape drags out or in as well. If there is only one side of the square I need to align this is such a pain. How can I only drag one side? It is so frustrating, in every other program this is a casual thing but apparently not in AE. Is there a good reason for this to work this way?
And one more thing: is there an easy way to get the spaces inbetween the shapes the same width? Besides my sense of proportion. To get an idea for my issue i'm going to add some screenshots of the mosaic.
You have to modofy the position of the anchor point that will control any transformation in your layer. You can change the anchor point using the Pan Behind (Anchor Point) tool. Place the anchor point in the opposite side of the side you want to transform.
If these squares can be a shape layer, then adding repeaters to a single square rectangle shape will do what you are trying to do in about 30 seconds. This is what the Shape layer would look like. All of the values are calculated by simple math.
If you want to use a bunch of layers instead of a simple shape layer then apply some kind of math to an expression and use the index of the layer as a multiplier.
For example, if your layer is 200 by 200 and your comp is 1920 X 1080, and you want 50 pixels between the layers then you have to add 300 pixels to the position of the first layer. It's all the math and the expressions are not too difficult. There are also some scripts at aescripts.com that will automate the process.