7
$\begingroup$

I'm trying to create a pipe that will bend and stretch, which I can then export to Unity. Bending I can do, but I have no idea how or if I could stretch. Is it possible? Thanks :)

What I'm aiming for is, in my Unity game, to be able to anchor one of the pipe to the ground, and then, as I drag the other end of the pipe away, it keeps stretching (increasing it's length).

So - Imaging holding a length of string with one end in each hand. In the dull reality we live in, the string wouldn't stretch, but in lovely virtual world, I'd like the string to extend in length as far as you pull it.

I think I have a handle on doing this in Unity, so if it's not simple for a Blender newb, I'll stick with what I know :)

$\endgroup$
  • $\begingroup$ Do you want it to be able to bend/stretch in Unity? or just in blender then export? $\endgroup$ – gandalf3 Sep 17 '13 at 21:54
  • $\begingroup$ It needs to be able to strech in Unity, but I guess I could take care of the stretching in Unity by adjusting the scale on-the-fly, if that's easier $\endgroup$ – DTownsend Sep 17 '13 at 21:56
  • $\begingroup$ Have you tried scaling the bones in one axis? $\endgroup$ – Haunt_House Sep 17 '13 at 22:12
  • $\begingroup$ I can make the object longer, but what I'm looking for is an object that I can attach stretch in game. Kind of like an accordion but without the concertina. Not explaining myself very well, but thanks anyway! I think I can accomplish this best in Unity itself. $\endgroup$ – DTownsend Sep 17 '13 at 22:24
  • $\begingroup$ I don't think that's something that Blender affects. I'm fairly sure most of it is done in Unity. Materials can tile in Unity and if you scale the pipe by 2 then tile the texture by 2 along that axis, that should work. An alternative, but rather messy way is to model a really long pipe that you push into the ground. $\endgroup$ – CharlesL Sep 17 '13 at 23:24
3
$\begingroup$

I'm not entirely sure what you want, but you can make a "stretchable pipe" in Blender by using Hooks:

  1. Add a cylinder with a fill type of Nothing

  2. Add hook to one end by pressing CtrlH> Hook to new object:

    enter image description here

    This will add an empty with a Hook modifier that you can control the hooked vertices with.

  3. Add a hook to the other end.

Now you can manipulate the newly created empties to stretch the "pipe".

| improve this answer | |
$\endgroup$
2
$\begingroup$

Another option would be Spline IK rig like shown here http://getblended.org/2013/03/385/ It bends and stretches quite nicely; no idea if that is transferable to Unity though.

| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.