Wind?

Moho allows users to write new tools and plugins. Discuss scripting ideas and problems here.

Moderators: Víctor Paredes, Belgarath, slowtiger

Post Reply
User avatar
Víctor Paredes
Site Admin
Posts: 5646
Joined: Wed Jan 26, 2005 12:18 am
Location: Barcelona/Chile
Contact:

Wind?

Post by Víctor Paredes »

Do you know if something like wind could be done by a layer script?
I'm imagining having chains of bones reacting to wind. Something very similar to Dynamics, but having an external force pushing them instead of the body movement.
I'm thinking about this concept:

- In a bone layer, there are some bone chains with dynamics activated
- In the same layer, a bone called 'source1.wind' (or another name), defines the direction and strength of the wind
- The strength is defined by the bone Scale (so it can also be animated)
- The direction is defined by the angle of the bone
- Maybe the position of the bone can also play a role (as everything behind the bone won't be affected by the wind)
- I'm still thinking about how to control the spreading angle (angle constraints could be an option, but it's not an animated value animated)

Image
I remember some very old posts from Heyvern playing with physics in version 5, maybe. So I'm thinking there is a chance something like this could be done.
What do you think?
Image Image Image Image
Moho Product Manager

www.mohoanimation.com
Rigged animation supervisor in My father's dragon - Lead Moho artist in Wolfwalkers - Cartoon Saloon - My personal Youtube Channel
User avatar
hayasidist
Posts: 3492
Joined: Wed Feb 16, 2011 8:12 pm
Location: Kent, England

Re: Wind?

Post by hayasidist »

first reaction to this is that "wind" is not a point source (so no Spread as such) unlike a fan (which obviously does).

so for a wind simulation (rather than a fan), I'd address "spread" (and turbulence) by having many "source" bones that can operate independently (for turbulence) or in unison; and I'd (probably??) have them placed off screen and oriented such that their length and rotation is a vector with {x,y} components that map to {x,z} wind strengths (i.e. a bone as you've illustrated has an "across the screen component" and a "from behind the screen" component). Typically these bones will be set up as a set of (initially) parallel bones from bottom to top of the "target" area. Keeping life easy, (and to make the "fan" work as below) I'd not try to use z at this time!! (and, therefore, the bone chains don't scale to simulate motion in z) and all the wind bones are parallel to the x axis.

For a "fan" simulation (e.g. helicopter rotors; blast from a jet engine; ...) much the same model; but the bones are "at the source" and (rather than spread out and parallel) are positioned to define the spread. e.g. 3 bones all at the same origin {x,y} the outer bones have minimal length and are oriented to define the spread; the centre bone defines the direction and intensity as you've suggested.

Next is to take into account that some objects will significantly reduce the intensity of the force felt by objects behind them wrt the wind, others won't (e.g. a tree is a better windbreak than a reed).

then it's a "just" a question of deciding which bone in each bone chain to rotate by how much and when (e.g. if a "wind bone" has a keyframe - if this "reactive bone" is inside the "blast envelope" - rotate it...)
User avatar
jahnocli
Posts: 3471
Joined: Fri Oct 29, 2004 2:13 pm
Location: UK

Re: Wind?

Post by jahnocli »

It sounds easy when you put it like that...
You can't have everything. Where would you put it?
User avatar
gilcartunista
Posts: 55
Joined: Mon Mar 14, 2016 7:13 pm
Location: https://www.facebook.com/gil.cartunista
Contact:

Re: Wind?

Post by gilcartunista »

hello there! Today, I worked on your idea of wind ... I would like you to look. thankful
https://drive.google.com/drive/folders/ ... sp=sharing
User avatar
synthsin75
Posts: 9935
Joined: Mon Jan 14, 2008 11:20 pm
Location: Oklahoma
Contact:

Re: Wind?

Post by synthsin75 »

gilcartunista wrote: Thu Dec 24, 2020 3:09 pm hello there! Today, I worked on your idea of wind ... I would like you to look. thankful
https://drive.google.com/drive/folders/ ... sp=sharing
Interesting ideas there.
User avatar
Víctor Paredes
Site Admin
Posts: 5646
Joined: Wed Jan 26, 2005 12:18 am
Location: Barcelona/Chile
Contact:

Re: Wind?

Post by Víctor Paredes »

gilcartunista wrote: Thu Dec 24, 2020 3:09 pm hello there! Today, I worked on your idea of wind ... I would like you to look. thankful
https://drive.google.com/drive/folders/ ... sp=sharing
This is very interesting, gilcartunista! Thank you very much for sharing it.
It's different to the wind I'm looking for, but I think it's a very nice concept to create interaction between objects. For instance, feet walking over grass.
Image Image Image Image
Moho Product Manager

www.mohoanimation.com
Rigged animation supervisor in My father's dragon - Lead Moho artist in Wolfwalkers - Cartoon Saloon - My personal Youtube Channel
User avatar
gilcartunista
Posts: 55
Joined: Mon Mar 14, 2016 7:13 pm
Location: https://www.facebook.com/gil.cartunista
Contact:

Re: Wind?

Post by gilcartunista »

Ok, Victor.Thanks for your answer! Thankful!
User avatar
gilcartunista
Posts: 55
Joined: Mon Mar 14, 2016 7:13 pm
Location: https://www.facebook.com/gil.cartunista
Contact:

Re: Wind?

Post by gilcartunista »

Glad you liked it, Wes! Thankful!
Post Reply