HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Adding Animated Layers

07-04-2004, 08:42 PM#1
GoonGoon16
Uh...... somebody please elaborate? I'm guessing there is a way to make the model switch between a number of textures, which you could slighty edit each, giving it a animated texture, but thats just me.
07-04-2004, 08:55 PM#2
jerre Khan
Yeah I wanna do that too but it turns out its mdl. editing.
07-04-2004, 09:39 PM#3
Oinkerwinkle
Cookie has a tutorial on this here, if you're talking about in 3ds max. I don't know about MDL form, but you should be able to figure it out by looking at the water elemental.
07-05-2004, 06:30 AM#4
Alfred
Quote:
Originally Posted by Oinkerwinkle
Cookie has a tutorial on this here, if you're talking about in 3ds max. I don't know about MDL form, but you should be able to figure it out by looking at the water elemental.

Yep. It just simply needs a tvertexanim section. You can CnP straight from the water elemental. However, there are 2 types of animated texture.
1) One that moves, but with only 1 texture
2) Multiple textures that changes from time to time.

For 1, you will need the tvertexanim section. For 2, you will only need to tweak the materials section. Remember, if you need to make a layer ABOVE the normal model(like Cookie's fire infernal), you will need to make a copy of the geoset but scale it up a little bit. Then make it use the material that has the animated texture.

To summarise things up, you copy the tvertexanim portion from which ever model you want. Then create a globalsequence that suits what you want(small value for fast, high value for slow... But it depends, since long time taken in same distance tend to make the thing slower and vice versa.) Then make a new material and texture. Make the tvertexanim you want link to the globalsequence. Look at water elemental's material, it has something like TvertexAnimID x, copy that and change the value to 0(which is the first tvertexanim in the model). Then make a copy of the geoset which you want the animated texture on, scale it larger than normal. Then assign it the material. Then you are done :)
07-05-2004, 06:33 AM#5
Pheonix-IV
how about somone posts a nice long detailed step-by-step tutorial instead of Alfred trying to tell us how to do something that takes awhile and is reasonably complecated (thats what u told me) in 1 paragraph?
07-05-2004, 06:35 AM#6
Alfred
Quote:
Originally Posted by Pheonix-IV
how about somone posts a nice long detailed step-by-step tutorial instead of Alfred trying to tell us how to do something that takes awhile and is reasonably complecated (thats what u told me) in 1 paragraph?

How about you learn it yourself? :P

I will write a tut sometime. But I always think that tut is not enough. Since it will only explain one model, but people might not get the concept. I was only explainning the concept.
07-05-2004, 06:37 AM#7
Pheonix-IV
great, now we have the concept, so lets get the tut, since that concept made absolutly no sense whatsoever. I would love to learn how to do it myself, thats why i want a tutorial!
07-05-2004, 07:34 AM#8
Alfred
Quote:
Originally Posted by Pheonix-IV
great, now we have the concept, so lets get the tut, since that concept made absolutly no sense whatsoever. I would love to learn how to do it myself, thats why i want a tutorial!

If that doesn't makes sense to you, the tut will be of no use to you. Since all I will have to do is to explain the same old thing again.
07-05-2004, 07:42 AM#9
Pheonix-IV
Where the hell is Xaran, or Cookie, where is somone who can do a "Adding an Animated Layer for Noobs" totorial?
07-06-2004, 06:12 AM#10
Ari
Once upon a time, I seem to recall answering somebody's questions about animated textures with my (admitedly limited) knowledge. A quick search for "animated textures" (or for that matter, recent posts by me) should probably unearth it. Overall, though, I'd reverse engineer the water elemental for actual animated textures, and perhaps a druid to demonstrate how to change static textures (err, at least I think druids have both forms within the same model; if I'm wrong, obviously use a model where both forms are within the same model).

Edit: I suspect human towers change skins on a single model as they upgrade. Guess you could reverse engineer that.
07-06-2004, 07:45 AM#11
Pheonix-IV
i dont think there is a model with multple forms from the same model. The druids 2 forms are modelled seperately, and the 2 meshes only appear in certain anims. The Human towers are done the same way, all the towers have seperate models, but the meshes are hidden in all but their correct animations. The human tower has one of the highest poly counts in the entire game if you look at all its seperate meshes at once.
07-06-2004, 04:01 PM#12
Oinkerwinkle
After looking at the water elemental, I'm going to try to post an explaination of its animated material.

Firstly, the textures, which are pretty self-explainatory. It has each of the frames of the animation listed one after another. I'd assume that WrapWidth and WrapHeight makes it so that in the case of uv-mapping going over the edges, the texture loops around.

Now, the materials. The first one is evidently the main one, so that's the only one I'll go over. There are two layers: one is the base and the other is an 'additive' layer over that, meaning that it adds to/brightens the colors.

Layer 1:
Code:
		Layer {
			FilterMode Blend,
			Unshaded,
			TextureID 8 {
				DontInterp,
				GlobalSeqId 0,
				0: 0,
				83: 1,
				166: 2,
				249: 3,
				332: 4,
				415: 5,
				498: 6,
				581: 7,
			}
			TVertexAnimId 0,
			Alpha 5 {
				Linear,
				0: 0.99,
				2167: 0.99,
				4867: 0.99,
				10167: 0.99,
				16633: 0.99,
			}
		}

The important part here is that the texture id changes over time, going from 0 to 7 and back. To understand why it always loops instead of only from frames 0 to 581, you need to know what a global sequence is. Essentially, it is it's own frame counter that runs independently from the main one. You can see that this references GlobalSeqId 0, and that sequence, if you look up in its section says Duration 664. So, when it's internal ticker reaches 664, it will go back to 0 and the TextureId will go back to 0 as well. Using that, they have a constant animation playing.

The alpha part just makes it not quite entirely transparent. They've added a key for each animation for 99% opacity.

The next layer is basically identical, but it is additive and uses different timing. By having the different timings, they end up with all sorts of different combinations of the two frames and it doesn't look like it's simply looping through seven frames.

Another thing worth mentioning is the TVertexAnims. As far as I can tell, they are just shifting the whole uv-map around, adding to the watery look. (That also explains why they would need the WrapWidth and WrapHeight bits in their texture.)
07-07-2004, 04:02 AM#13
Pheonix-IV
the thing is, i'm pritty sure the Water Elemental dosnt use 1 skin for its animated texture, it uses about 10 of them. I need to animate with just 1 skin.
07-08-2004, 01:16 AM#14
Oinkerwinkle
You can't have an animation with just one frame. You'll need to use multiple skins. Or, you could try that TVertAnim thing, but it probably won't get you what you want.
07-08-2004, 05:29 AM#15
Pheonix-IV
Alfred assured me there were 2 ways to do animated layers, one that uses many skins and one that uses 1 skin.