# Grid of Cubes controlled by center cube?

basically I know this is easily achievable in Houdini, but am having difficulty in working it out in Touch,

what i would like is a grid of cubes (in Houdini using a grid sop and cubes to the vertexes using a copy sop)

and then to have the center 4 cubes grouped and controlling the rest of the cubes,

so when i pull the center cubes out the other ones follow but with a slight delay,
so its a bit like im pinching the grid,

also I would only like 1 axis on the grid to move so no rotating of the cubes

heres what i mean

and then pulling the middle cubes out the others would follow like thus

cheers, any help would be appreciated!

Ok making the grid of squares is done now,
for some reason it bugged the first time, and wouldnâ€™t let me do anything

now is just a question of making the center blocks controll the blocks around it? any one have any idea how id go about this?

nevermind, I worked this one out,
my touch was playing up, but its sorted its self out,

thanks

Hi,

a little to late but here is an all SOPs and CHOPs based approach Rob and I worked out:

after converting all points via a SOP to CHOP you calculate the distance off all points to the points that get initially transformed by taking the absolute x and z position of each point and then combining x and z via choosing the maximum value. The distance from the originally transformed point is then inverted and multiplied by the amount of the original transform. That was the solution to getting surrounding points to the same height.

Out of interest, how did you solve it?

cheers
markus
blocks.tox (48.5 KB)

ahh thats very cool!, thanks for that.

I just solved it by using a magnet and meta ball into a cube and grid and copy SOP. and then controlled the metalball, which did the job I needed

cheers again, this is still usefull