Creating "Chains" of objects with smooth motion.
#1 Members - Reputation: 685
Posted 12 November 2012 - 07:48 PM
I'm looking at creating a bit of variety. Simple chains that follow a path are pretty easy, but what about chains that are more "wild." It seems like they are partly IK chain based, but I'm not so sure, considering that I don't think older platforms had enough power to really do IK with this many "links/bones" as these games have. So it seems to me that in general this should not be too difficult to do. I'm pretty sure it wasn't done pre-drawn, also considering the limited space constraints of these old platforms. I have found a few videos so you can see what I'm talking about.
at time 1:54. The guy talking is pretty stupid sounding, but it is a good example, which is the scorpion boss from Legend of Zelda: A Link To The Past(SNES) You can see the scorpion tail is "wagging" for the most part, but then gets shot out towards link.
http://www.youtube.c...?v=NcXuvqwIztc is the final boss to the SNES game BioMetal( a really difficult Shooter). You can see the "arm" chain thing at the bottom that moves around pretty fluid and random, and doesn't appear to follow a given path, or be constrained to an IK chain type thing either.
There are other examples, including bosses from the Contra series of games.
So, does anyone have any insight how to create this effect. I'm sure the ones where the chain objects simply follow the leader is easy, as you can simply have each one follow the next one in line, but how about the fluid circular motion, etc...?
Thanks in advance for the help.
#2 Moderators - Reputation: 5023
Posted 12 November 2012 - 10:59 PM
#3 Members - Reputation: 2108
Posted 12 November 2012 - 11:53 PM
Looks more like some kind of Bezier in the Zelda screen shot.
In the second it looks like delta offsets are passed up the chain. The start of the tail seems to only turn clockwise or counter clock wise and those movements chain along to the outside. When the arm lashes out to the top left it looks like a scintillating series of cw/ccw turns.
#4 Members - Reputation: 685
Posted 13 November 2012 - 05:06 PM
I don't know much about GameMaker, but if it has a physics module you can model something like that as a chain of hinge joints, with angular constraints on the hinges to keep the chain from folding up. (Remove the constraints to provide a movement mode like in the second video, when the chain sort of collapses in on itself). Lightweight 2d physics libraries such as Box2D make this sort of thing relatively easy.
I actually have to agree with the quote below. I seriously doubt any of this is physics related, although GM Studio does now include Box2D physics.
I doubt there's anything remote resembling physics in there.
Looks more like some kind of Bezier in the Zelda screen shot.
In the second it looks like delta offsets are passed up the chain. The start of the tail seems to only turn clockwise or counter clock wise and those movements chain along to the outside. When the arm lashes out to the top left it looks like a scintillating series of cw/ccw turns.
So how do you think they did those in the original console systems? I'm wondering if the SNES even had the processing power to handle bezier curves.
#5 Crossbones+ - Reputation: 1060
Posted 13 November 2012 - 06:36 PM
A wristwatch should have the processing power to handle Bezier curves.So how do you think they did those in the original console systems? I'm wondering if the SNES even had the processing power to handle bezier curves.
That said, they don't need Bezier curves to get that Zelda tail. Like Endyrion said, it could be a simple transform getting re-applied on top of itself to produce the next point on the tail. If a constant transform doesn't quite give them what they want, they might also be slightly nudging the transform between applying it. Neither the initial transform or the nudges need not be rigorously correct, just cheap and good enough.
#6 Members - Reputation: 685
Posted 13 November 2012 - 07:04 PM
#7 Moderators - Reputation: 5023
Posted 13 November 2012 - 10:12 PM
That being said, you could probably also achieve a similar effect by using "canned" animations, by pre-computing animation tracks for each ball in the chain for a particular movement, especially for the Zelda boss, since there isn't the wavy variation that the second one has. I suspect the second one might be canned, too, since those bullet-hell games tended to be pretty tightly timed and patterned.
Edited by JTippetts, 13 November 2012 - 10:18 PM.
#8 Members - Reputation: 685
Posted 13 November 2012 - 10:48 PM
So far, this seems like it is going to be the best solution. In fact, now that I'm thinking more about it, I may be able to come up with a sort of "cheap IK chain" using these same paths...We'll see.






