Genete wrote:Simply brilliant.
You're to so many few steps to create a gravity chain... It would be very difficult but you could achieve it.
Good luck
Funny you should mention that!
I'm not as far away as you think. I started converting another Actionscript for linking chains of bones using nodes for my aimer script rig. It is based on the same sort of code as this but it has "links". Each "node" is linked to each other node.
Now that I know this works I can try to implement that code.
There is another script I found that simulates "springy strings"... hard to explain. It has this cool flexible rubbery type connections where the lines "bend" and "warp". The guy who invented it uses it to simulate water surface effects. No reason not to try that one either. Skies the limit as far as I'm concerned now that I know how to convert Actionscript to lua.
I should try to create a grep search pattern to speed up the conversion process. Actionscript and lua are not that different... well they are but not that much. The best part is they both have nearly identical math functions. No need to reinvent the wheel. The main difference is fixing the opening and closing structures of functions. Actionscript uses brakets "{}" and lua uses "if" or "do" to open and "end" to close the functions.
I can even keep the variables from the Actionscript, just "add on" or change the extra bits needed for lua.
For instance to initialize a variable in Actionscript you use "var". I just replace "var" with "local" or delete it completely if it's a global. Piece of cake.
-vern