animating a weapon (tags)


(urgrund) #1

I’ve been trying to animate my weapon. The animations will be from scratch but I am going by what the RtCW animation config is for the Mauser… as I’m trying to animate a Enfield (similar rifle).

Take these keyframes below.

a…b…c…d

Ok, between a - b - c is the weapon drop and raise frames (when changing weapon).
d is something else.

This is how i approached it… a and b are idle in the models original position.

All I did was modify the model position at b so it was off the screen.
Assuming that it would be a smooth “in - out” animation because I did not touch a or b and they are in their original positions.

When I play back the animation it is in the correct position for a - c but then takes another journey back to c in order to sync up or something with d (which is also idle position).

Do I have the wrong understanding of keyframes? I thought that at a key frame you can do anything you want… and the animation will animate the model to that frame from its previous key.

I’ve searched and searched and there seem to be no tutorials on how to make animations for a weapon (only setting up tags and exporting which I already know).

I mean, there are thousands of weapons in many games… has no-one made a tutorial on how to animate, say, inserting a new clip at reload - ect?
/Thanks


(editor666au) #2

Well, I’m not going to be any help, other than to let you know that someone does actually still frequent this forum, but Urgrund man, you are soooo way ahead of me in mapping!

Maybe try the q3forums?
or rtcwukforums
or planetwolfenstein?

Editor


(Ghast) #3

TiCal at Tram might be the one to ask?


(pants) #4

Well, writing a tut on how to animate is like writing a tut on how to write a story. That said, the basics of keyframing is like grammar so i will give it a stab. Or, maybe making an analogy of painting a texture would be better.

If you set 2 keyframes over time, the computer will inbetween it for you, moving the object over the course of time depending on how it’s interpolating the points. By default, max sucks for animation. The keyframes allow for massive drifting especially when doing what you’re describing. Max creates a spline between keyframes thus it pulls some inbetweens way out. I think a really quick illustration would help…


This is what’s happening now. In between c and d, the spline is going way out of whack with what you want.

There’s a few solutions, you can add more keyframes, but then you get something that looks like this…

Or you could change the way the keys are interpolated, which might suit you best. As i have no clue what’s going on between c and d, if you want it not to move at all, change the key to a stepped key as in this picture…

Or perhaps that isn’t good enough, then you can use the function curves to control how the spline interpolates…

Use the tangent handles like a regular bezier spline (alt+mouse1 to break the tangents).

There’s other ways of interpolation but i’m not going to write up about them all.

Onward to rotation!
I’m going to quickly write this up because it’s 3.30 in the morning. If you set Key A’s rotation, copy it to point C and then create a B inbetween, it will flop like a drunken hoola dancer. Soo… just go straight through, set A, set B, copy A to C. no diagrams for you. :frowning:

hopefully this is what you needed to get a better grasp of this. Hopefully i’m not talking down to you (if so, sorry!). If this didn’t help, feel free to ask more questions. And if this didn’t help, i blame it solely on the fact that it’s 3.30 in the morning.
>>
<
<
:moo:


(Ghast) #5

Woo Hoo! Of course I am interested in this!!! So keep drinking coffee cause I have questions too! I am working on a Third Person platform series of levels, all monsters, so no weapons. However

  1. I did notice that zombies hold weapons pointing down. Pushable chairs jump below surface if zombie/player picks them up? G And grenades get held/tossed but of course there is no throw animations (or ladder climbing LOL)

  2. With Max Payne there was a four legged rat/dog??? I have seen used before & since with other games/tuts, and I have played with the loper and some SKEL remains included with RTCW???

  3. Just being able to create new pushables/holdables would be quite an asset!!! Doable??? Would it serve as applicable tut material?

  4. I know, I know, this is all SP stuff, and everyone is probably still trying to heal, and Doom3 will either make or break player created SPs, so I don’t really need any answers, just posting I am interested in learning more, even if its mainly MP related! G


(pants) #6

i don’t mean to sound daft, but i don’t really get what you’re asking… :huh:


(Ghast) #7

Is it possible to create pushable entities for RTCW SP? Can I make a crate and make it pushable. Can I make a torch (unlit) and make it holdable. Can I change the way an AI model holds stuff?

Should I assume RTCW is pretty troublesome SP wise and just wait for Doom3.

I guess if I have a question that’s the big one G

Mostly, like many mappers I am just hungry for any inside info about how to make RTCW behave, and miss the regular postings here?

And just wanted to say how interesting I found your posting even though adding “new” weapons is a very strange obsession IMHO WEG


(pants) #8

makes perfect sense now :banana:

i know nothing about mapping :frowning: maybe someone else can answer this.

Troublesome in terms of mapping? /me points above :slight_smile: I also know nothing about sp.

I’m glad you found this somewhat interesting, I only added weapons bc we needed new weapons. Having people pick up the panzerfaust and not having it work like normal i think would make people upset. And, rtcw doesn’t have a dartgun, grenadelauncher, flamegrenade (among other grenades), nor a shotgun.


(editor666au) #9

Do you mean push buttons, (which are pushable entities) or furniture that you can push around? Anway, the answer to both is “yes”, it’s readily do-able on RtCW.

Can I make a crate and make it pushable.

Yes.

Should I assume RTCW is pretty troublesome SP wise and just wait for Doom3.

Well that is up to you, but SP mapping is generally not impossible in RtCW. There is a distinct lack of information as opposed to mp, but trial and error will get you there.

HTH

Editor


(Ghast) #10

Woo hoo! I am using the zombie as player model so it holds stuff low. If I can alter or replace a movable prop like a chair with a burned out torch???

Please point the way, give a hint, I have never come across this as doable before.

Just getting the player model to hold a shield by the handle without putting his elbow through the shield itself or cutting off his head with it would be plenty peachie! LOL

AND I think the Great Crusade is really needed!!! World War One is a better fit gameplaywise for the RTCW engine IMHO (fewer weapons of mass destruction than WWII or present day) Its just amazing to me how many other mod groups seem to be based on weapon fanaticism only! G


(urgrund) #11

thanks for the keyframe help Pants, helped me learn some new things.

Now… =D
I’m getting some wierd export results.

Sometimes the bolt of the rifle is positioned up centre and high in the players view. Even though in v_[weapon]_hand.md3 the bolts tag_barrel is in the correct position.

I’ll look over your weapon export guide again as well as a few others to make sure its not somethign stupid I’m missing! :stuck_out_tongue:


(urgrund) #12

"Onward to rotation!
I’m going to quickly write this up because it’s 3.30 in the morning. If you set Key A’s rotation, copy it to point C and then create a B inbetween, it will flop like a drunken hoola dancer. Soo… just go straight through, set A, set B, copy A to C. no diagrams for you. "

Problem is, when I try to rotate (or move) multiple tags the func curve options don’t display. Only for individual objects.

Also, with rotation, if I’m rotating with Animation off, it roates them all relative to a “group” axis (wherever it calculates the centre of the entire selected objects) but with Animation ON it rotates the individual objects around their individual axis’!! eh… why the change?

So I can’t figure out how to get a neat rotation of the gun (such as a recoil kickback) for all the tags!


(pants) #13

i ususally group everything in my weapon files (all tags, all parts of the gun). After i group it, i go Group->Open. After that, you can animate the group’s bounding box and it will affect everythign inside (perfect for animating the core of the motion such as the gun recoil). After i’m happy with the general animation, i then go in and animate the individual parts. I don’t know any other way of animating all the parts relative to their groups center without actually grouping it.

Sorry for my delay in getting back to you. been buseh :disgust:

Also, you still having the problems you were having in your post above your most recent?


(urgrund) #14

well, still got rotation troubles…

what I need is for separate groups to exist only for certain keyframes.
(or some technique that provides a solution) =D

For example:
For one part, i need the hand to be separate from everything (for my raise/lower animation)

Another requires the main gun body and the bolt to be grouped whilst the hand and clip act independantly from the 2 latter objects. (reload)

So, in that second case, I want to rotate the whole animation (this is whilst the seperate parts work independantly) so that the gun is loaded at an angle (as is common in gun reload animations).

Problem is, its rather difficult to animate a clip coming back in at a weird angle, so I animate everything on a striaght plane, then try to rotate it… I then get the problem of the objects rotating only around their individual origins because they aren’t a group.

And if I ungroup (that is, the old group for the raise lower animation) in order to regroup for this part… the old group that had animations is lost. >:\


(pants) #15

i still think this could be solved by grouping, opening the group and animating the individual objects. Perhaps making a few smaller groups where you can work with specifics, opening those groups and grouping them to a larger group would help.

You could also try animating the links of the objects. I do that for animations where during the attack, a shell flys out, but during the reload, the shell is in the player’s hand.

and for the global rotation at the end of an animation, i really suggest a group :slight_smile: Even if you don’t use a group for everything else, you could use it here with no problems.


(Malus) #16

Wow that’s a realy nice reply from you Pants…putting so much effort in explaining people how it works has to be respected I think.

Anyway Pants, you say that animation in MAX sux,…did you ever try it in Maya?
I find it even worse there, the tangents of the splines realy screw up there if you’re not carefull :slight_smile:

Though Maya is modeling/Unwrapping heaven compared to MAX IMO.


(pants) #17

it’s funny bc i think the exact opposite of you. i hate modeling/uv in maya, but love it in max. and i hate animating in max 4 but love it in maya. :slight_smile:

however, recently i’ve started animating in max 5 and i can safely say i don’t think i’ll be using maya for much anymore for my independent stuff :clap: max 5 implemented a lot of stuff that i’ve loved about maya’s animation (set key, flat tangents (why it took them 5 versions to implement this i’ll never know…), vastly improved trackview (graph editor), etc.). oh, also, all the rotation problems that i have with max 4 are much much more manageable with 5.

i wish my school still taught xsi as xsi is teh roxor of teh world. :o
yay for demo versions of kick butt software though :smiley:


(Malus) #18

Yeh I often hear that, people loving the modeling tools of MAX and don’t like them in Maya. but I never found out why :slight_smile:

What do think makes MAX stand out beter as a modeler then Maya?


(pants) #19

well, i’m sure a lot of my dislike of maya comes from not really knowing it that well. It’s odd when i go to cgtalk and i see amazing poly models done in maya bc i just don’t understand how it could be done with the toolsets available. anyway, why i like max over maya…

Edge Connect. There’s a way to select 2 edges, click connect and poof, you now have a perfectly subdivided face. you can change the amount of iterations, etc.
Create vertex, face, poly mode. I can lay out a rough model in vertices and just sit there and connect them all. I’ll be the first to admit that i’ve never met anyone else out there that builds their models like this but the ability to do this whenever you want is fantastic. i modeled something in maya and if i wanted to do something like this, it took a lot of extruding and vertex welding.
Target welding and Collapse. You can click a vertex, then click the one you want it to weld to. or, you can select both and hit collapse and it welds the vertices in the exact middle of where they were.
Modifier stack. You can always go back through your modifier stack and make changes in the bottom most layer of a model. With the channel box, it’s very limited for what i like to do.

eh, there’s more but the list is going to get very long. and it’s probably goign to be even more trivial than the things i’ve listed already and quite possibly will make even less sense. :smiley: As for the UV tools, i can’t even comment bc i have literally 100% no clue how to use them in maya.

in the end, what it comes down to for me is control. i can do basically whatever the hell i want to in max and i know that no matter what, i can always rebuild a mistake. In Maya, i feel locked down to the decisions that i make and that’s no good for me.

ack, one last thing :slight_smile: This one kiiiiills me, but in Maya, there doesn’t seem to be any culling on the models. So if you’re in wireframe view, you can see through the model and see the backside which is absolutely frustrating when you start selecting stuff on the back of the model bc you can’t see properly.

and again, most likely all of this stuff is trivial as there are indeed ways to do it all, but i’m inexperienced with it so… :lookaround:


(Malus) #20

Allright! you convinced me I’m switching to MAX!!!
hehe no just kidding. I guess it all comes down to what you are most experienced with. For me the main thing about Maya is how fast the interface works for me. And you can always go back and fix your mistakes too. Just don’t delete your history.
But I must say merging edges and creating as much iterations as you want sounds pretty intersting :slight_smile:

About the culling, that ofcourse is also possible in Maya :banana:
got to: > display >component display, and select: ‘backfaces’

Hope it helps :drink: