Ambiera ForumDiscussions, Help and Support. |
|
|
|||||
|
Because I was asked this a few times alreay via mail: Did you know you can adjust the Grass / Wind speed dynamically? You can do this in the Windows .exe and Mac OS X .app target easily, because all properties shown in the property window are available automatically in JavaScript. Use code like this: var r = ccbGetRootSceneNode(); Works of course only if you have checked that 'Wind' property in the root scene node. |
||||
|
Is this means if i use this script i can set Wsp and Wstr on each node? It's good |
||||
|
No, it's global, you only set it once and it affects the whole scene. |
||||
|
Yes, but I found changing either one during runtime will reset the plants to their starting position so if you do this a lot with changing wind speeds will jerk them around a lot and look terrible. Niko, can this be fixed so no resetting occurs ? |
||||
|
I had the same problem with changes during runtime - so I finally didn't use it. Would be great if this could be fixed... |
||||
|
If you guys want you can try using my Custom wind Shader, that Allows you to have more control over the wind. Maybe you can try changing the speed or other parameters of the default wind shader, by send a different value for the global variables of the wind and use 26 as the base material when creating new material out of it. So that it won't reset and can use the variables independently. |
|