Hard Light Productions Forums

Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: Raven2001 on September 12, 2002, 09:43:37 am

Title: Suggestion: model animation triggers
Post by: Raven2001 on September 12, 2002, 09:43:37 am
Ok, I dunno if this has been already discussed or anything so here goes:
I think that a very cool thing to have in FS would be model animation triggered by a certain action or SEXP.

What I mean is, in triggered by a certain action:
- You want to have a fighter with weapon barrels like a minigun type primary. In PCS you would make the minigun sub-object, that would rotate if a certain primary point is fired (or any other action, combinations could be many... but the point is that the rotating animation would be triggered by a certain action on the model...). Another useful uses could be a single barrel kickback when fired, or any other thing...

By a certain SEXP:
- for example, you have a capitalship that has a super weapon, but its turret is very weak due to plot issues. Obvously you would want to have some kind of protection for the turret, so you would make a kind of shield door, that protects the turret. Now in a mission you want the super weapon to fire, but it is obstructed by the door, so you would make a SEXP that would make the door open, so that the weapon could fire...



What do you think of these???
Title: Re: Suggestion: model animation triggers
Post by: Sandwich on September 12, 2002, 09:46:47 am
Quote
Originally posted by Raven2001
What do you think of these???


I think that we'd all best run and hide before the RoboTech guys get here and start p1mping this idea.

Seriously, though, I'd be very surprised if this hasn't been mentioned before. As a matter of fact, I think I even mentioned something like this with reference to how the models were jointed and animated in Total Annihilation.
Title: Suggestion: model animation triggers
Post by: Nico on September 12, 2002, 10:03:40 am
we (the robotech team ) already have programmers working on all the animation related stuff :D
Title: Suggestion: model animation triggers
Post by: LtNarol on September 12, 2002, 04:44:32 pm
*cough* hangar doors *cough*

*cough* docking clamps *cough*

*cough* Sathanas arms *cough*

*cough* the living [CENSORED] that I want to include in Into the Night *cough*

;)
Title: Suggestion: model animation triggers
Post by: Sandwich on September 12, 2002, 05:39:45 pm
Quote
Originally posted by venom2506
we (the robotech team ) already have programmers working on all the animation related stuff :D


Are you guys working alongside the SCP team?
Title: Suggestion: model animation triggers
Post by: Nuke on September 12, 2002, 08:04:01 pm
i think think i convinced people to implement a descent style movement system, dont know if anyone is working on it.

ok, raven, i dont mean to overstep my athority in out little mod team, but CIM needs a phucking programmer! If you want to program for an EPIC scale campaign that will continue the legacy of the glorious game that is freespace, then join us now!
Title: Suggestion: model animation triggers
Post by: Inquisitor on September 13, 2002, 07:57:26 am
I was about to ask if they wanted to share that code any time soon :)
Title: Suggestion: model animation triggers
Post by: Nico on September 13, 2002, 08:26:56 am
Quote
Originally posted by Sandwich


Are you guys working alongside the SCP team?


dunno, I guess so.
Title: Suggestion: model animation triggers
Post by: Raven2001 on September 13, 2002, 10:13:02 am
Quote
Originally posted by Nuke
i think think i convinced people to implement a descent style movement system, dont know if anyone is working on it.

ok, raven, i dont mean to overstep my athority in out little mod team, but CIM needs a phucking programmer! If you want to program for an EPIC scale campaign that will continue the legacy of the glorious game that is freespace, then join us now!


No authority stepping :) just your opinion, wich I tottally agree, but you gotta understand that almost every programer is workinh her on the SCP... I'm sure we will have the changes we require but it will take time... :(

I've tried to dig out a programmer here in my vicinities, but everyone is very busy (shoving their a$$es, cause I know what are these people business...)

*p1mp ALERT* BUT, if you want to take part in one of the best campaigns in the comunity ever, just E-mail to:
[email protected]
Satisfaction is 99% guaranteed, and if you don't, you get your money back in 30 days :D *p1mp ALERT*
Title: Suggestion: model animation triggers
Post by: Stunaep on September 13, 2002, 10:21:24 am
of course first we need the animations to begin with.
Title: Suggestion: model animation triggers
Post by: LAW ENFORCER on September 13, 2002, 04:07:29 pm
Really? I would have though you make the best animation system possible (or sutible) first?
Title: There you go...
Post by: Star Dragon on September 13, 2002, 08:14:08 pm
That's what I was asking in my robot thread (move over RT guys)...

   Soon I'll be testing a Zaku for the Gundam TC. What I wanna know is can we do dynamic animations to give it a little life... Like jerking a little when afterburners go on. Or that Idea I had for the beam saber or any solid melee weapon. a key is programmed and that arm moves once out and back so you position yourself to hit a target at melee range. One sword stroke... Maybe l8ter other anis could be made for things like a martial arts kick (Getter or G gundam).... But I think it would look wicked cool... Thoughts?

   ;7
Title: Suggestion: model animation triggers
Post by: Solatar on September 13, 2002, 11:19:30 pm
Yeah, that would be cool. Also don't forget about the Mechwarrior TC ( I think someone was doing one).
Title: hehehe
Post by: Star Dragon on September 13, 2002, 11:53:21 pm
You're right... And I think I know who it is...
You guys said it couldn't be done. Well there is a ground now :) At least it's a start :nod:
Title: Suggestion: model animation triggers
Post by: Nuke on September 17, 2002, 08:29:37 pm
i still want fully detailed gatling guns, with all the features, theese include:

barrel acceleration/deceleration, aka spin-up/spin-down.

multiple ammo types (tracer, armor pircing, high explosive, shield distortion, and so on) .

deflection angles (scattering shots), scaled up with rpm.

limeted ammo.

finally, a rotating subobject (part of the ship) that spins in a manner syncronized with the fire rate of the gun.

and that is a simple as i can state it. not that this is not a turret, and is under player control as a primary weapon.
Title: Suggestion: model animation triggers
Post by: Unknown Target on September 19, 2002, 06:32:28 am
Sic 'em, Venom!

Actually, I don't think so. You guys'll have tp ask Max...


What is going on in the SCP?The only things I've seen are nav lights and beams on fighters. And while the former looks quite useful, isn't there anything else? Please excuse my ignorance.
Title: Suggestion: model animation triggers
Post by: WMCoolmon on September 19, 2002, 09:31:03 pm
Well, last I heard, Penguin was working on dynamically allocating the tables using values from the registry, and a lot of the coding work is going into the DX8 upgrade. This involves rewriting a rather large portion of the rendering code-thus the lull in new things.
Several features have been put on hold until the DX8 routines are added, because upgrading the engine will make it much easier to add them and it means that less code will have to be rewritten.
That's the current situation as far as I know.
Title: Suggestion: model animation triggers
Post by: Sandwich on September 23, 2002, 07:55:35 am
Quote
Originally posted by WMCoolmon
Well, last I heard, Penguin was working on dynamically allocating the tables using values from the registry...



Meaning exactly what?
Title: Suggestion: model animation triggers
Post by: Nico on September 23, 2002, 08:32:28 am
Quote
Originally posted by Sandwich



Meaning exactly what?


what you don't know what it means? it's like remotly cycling the superzaformer spline while creatorving the spoonz. What? it's not that? damn :shaking:
Title: Suggestion: model animation triggers
Post by: Sandwich on September 23, 2002, 08:42:14 am
Quote
Originally posted by venom2506


what you don't know what it means? it's like remotly cycling the superzaformer spline while creatorving the spoonz. What? it's not that? damn :shaking:


:blah:
Title: Suggestion: model animation triggers
Post by: Bobboau on September 23, 2002, 12:06:45 pm
it means we'll have bigger tables, but it won't break peoples computers that can't handel it
Title: Suggestion: model animation triggers
Post by: aldo_14 on September 23, 2002, 04:40:07 pm
So, (I think) a registry entry dictates the maximum allowed tbl size for a Pc so it doesn't overruse RAM?  That's pretty cool. :nod: :yes:
Title: Suggestion: model animation triggers
Post by: Sandwich on September 23, 2002, 05:05:52 pm
Quote
Originally posted by aldo_14
So, (I think) a registry entry dictates the maximum allowed tbl size for a Pc so it doesn't overruse RAM?  That's pretty cool. :nod: :yes:


Ahh, ok - as long as it's not something as ridiculous as storing the table data itself in the registry... :nervous:
Title: Suggestion: model animation triggers
Post by: Nuke on September 25, 2002, 03:31:14 pm
i hope we are not contaminating the game with microsoft, thatwould be bad. i have added maby a dozen or so ships and even more weapons to the tables with no problems. table limit expansion is over rated.

i like the binary table idea though, but someone would have to make a gui. it would be nice if it was built into fred, along with the pof tools, ani tools, and a vp compiler. fred would save vp files and could be used to assemble mods directly. take it even farther than that and you could use fred's 3d interface as a basis for a pof modeller. that would make fred all you really need to make a full mod.
Title: Suggestion: model animation triggers
Post by: r0nin on September 25, 2002, 10:06:31 pm
Errr, as the programmer (sort of) for the RT mod, I've been looking over the animation question for a while now.  Three main issues exist:

One, the specific method of storing the different frames are undefined.  Storing various frames in the model itself might require any or all of the following: changing the pof file format, changing the way the code reads the model file, and/or changing the way FS2 actually renders the model.  This is a problem because, quite frankly, I don't know how to do any of the above! :D  At least, I would have to develop the new routines by trial-and-error, and that takes LOTS of time.

Two, using methods already in FS2 might cause severe performance hits... and there's no way to tell without trying.  Two examples of methods that mimic routines already in FS2 would be recoding the LOD function to allow more LODs and cycling through them for the animation or creating a pof for each frame and switching pofs after rendering with a timestamp.  The second will almost certainly hog memory.  As for the former, some code would have to be implemented to tell FS2 which ships use LOD as normal and which have it reserved for animations.  Plus, the effect on the performance of the much larger pofs is an additional unknown.

Three, the engine instelf was not really designed for animation, so there are a number of completely unexpected bugs that could crop up (I'm betting on lot's of them).

So, the whole thing isn't as simple as dropping in a new model and changing a few lines of code.  There are probably coders here on the SCP who could work this out in a relatively short time, but I ain't one of 'em... ;)
Title: Suggestion: model animation triggers
Post by: Nuke on September 25, 2002, 10:24:32 pm
we dont really need some fancy vertex by vertex animation, a simplie method of subobject animation, there keyframes are used at various points in time to indicate subobjet rotation, translation and possibly scale. for the idea of gatling guns, the fire comand calls a function that begins to increase the rotational velocity of the barrels, which in turn calls the function the fire the weapon. you could simply have 4 keframes every where the barrels rotate 90 degrees. the time between yframes is then scaled as the barrels spin up or down. the end resuld is a fully syncrhonized gatling gun effect. the same stuff could be applied to docking bay doors, which will translate (move) between two vectors when a ship is spawned inside the bay. descent 2 is a good example of what im talking about, robots seem animated but its just relitave subobject movements.

anything beyond that (rippeling surfaces, shadow vessels) could use vertex shaders, which i belive are in direct-x 8.1. you see the alive effect on some surfaces in certain quake 3 maps.
Title: Suggestion: model animation triggers
Post by: Nico on September 26, 2002, 03:38:17 am
vertex by vert-ex animation? whoa, a new one :rolleyes:

animating surfaces does not require vertex shading, an ani will do fine. rippeling surface ( I mean real, volumetric ), is out of our range.
Descent2 robots are animated, they use keyframes. relative movements of subobjects is just one way.
Title: Suggestion: model animation triggers
Post by: Sandwich on September 26, 2002, 05:20:59 am
Quote
Originally posted by r0nin
Errr, as the programmer (sort of) for the RT mod, I've been looking over the animation question for a while now.  Three main issues exist:

One, the specific method of storing the different frames are undefined.  Storing various frames in the model itself might require any or all of the following: changing the pof file format, changing the way the code reads the model file, and/or changing the way FS2 actually renders the model.  This is a problem because, quite frankly, I don't know how to do any of the above! :D  At least, I would have to develop the new routines by trial-and-error, and that takes LOTS of time.

Two, using methods already in FS2 might cause severe performance hits... and there's no way to tell without trying.  Two examples of methods that mimic routines already in FS2 would be recoding the LOD function to allow more LODs and cycling through them for the animation or creating a pof for each frame and switching pofs after rendering with a timestamp.  The second will almost certainly hog memory.  As for the former, some code would have to be implemented to tell FS2 which ships use LOD as normal and which have it reserved for animations.  Plus, the effect on the performance of the much larger pofs is an additional unknown.

Three, the engine instelf was not really designed for animation, so there are a number of completely unexpected bugs that could crop up (I'm betting on lot's of them).

So, the whole thing isn't as simple as dropping in a new model and changing a few lines of code.  There are probably coders here on the SCP who could work this out in a relatively short time, but I ain't one of 'em... ;)


Or you could simply copy the manner that was used in Total Annihilation. Versatile, simple, and powerful. :)
Title: Suggestion: model animation triggers
Post by: Nuke on September 26, 2002, 09:36:24 pm
you forget that there is a difference between pixel shaders and vertex shaders. vertex shaders create a 3d effect by distorting the vertices that make up the model in a pre scripted manner. a pixel shader creates effects by distorting the pixels in a texture, also in a pre scripted manner. as far as i know shaders have far less overhead than preanimated textures, because your video and/or system memory must store many images, while shaders use only a couple. they require a tad more processing though, but most modern video cards can do this easily. personally i think shaders look alot better than any animation can.

vertex by vertex animation means that your model has frames. each frame is virtually a different model for each frame in the animation. some games intrepolate between frames by calculating new frames to fill in the gaps. skelatal systems are used in fps games, it has potential in a gundam or mechwarrior type game. for spaceships i see no use for it. its probibly beyond the scope of the programmers we got working on freespace. it could be done though, if people want to spend the time on it.

seriously though, descent 2's animation system would work like a charm. its fast and it would be easy for modders to implement (for the programmers it will be a little more trickey). it would of course need to be alot more sophisticated than descent 2's.
Title: Suggestion: model animation triggers
Post by: r0nin on September 27, 2002, 02:06:07 pm
Quote
Originally posted by Sandwich


Or you could simply copy the manner that was used in Total Annihilation. Versatile, simple, and powerful. :)


Which is?  Seriously, I don't know how they did it, nor do I have the source code, and I would be seriously interested.  Let me know where to find it!
Title: Suggestion: model animation triggers
Post by: Nico on September 27, 2002, 03:33:01 pm
Quote
Originally posted by Nuke
you forget that there is a difference between pixel shaders and vertex shaders. vertex shaders create a 3d effect by distorting the vertices that make up the model in a pre scripted manner. a pixel shader creates effects by distorting the pixels in a texture, also in a pre scripted manner. as far as i know shaders have far less overhead than preanimated textures, because your video and/or system memory must store many images, while shaders use only a couple. they require a tad more processing though, but most modern video cards can do this easily. personally i think shaders look alot better than any animation can.

vertex by vertex animation means that your model has frames. each frame is virtually a different model for each frame in the animation. some games intrepolate between frames by calculating new frames to fill in the gaps. skelatal systems are used in fps games, it has potential in a gundam or mechwarrior type game. for spaceships i see no use for it. its probibly beyond the scope of the programmers we got working on freespace. it could be done though, if people want to spend the time on it.

seriously though, descent 2's animation system would work like a charm. its fast and it would be easy for modders to implement (for the programmers it will be a little more trickey). it would of course need to be alot more sophisticated than descent 2's.


1 I didn't mix up, don't worry :) the pb is that vertex shader requires the creation of an awful lot of polys, it's not just a visula effect, and the imapct on performances IS important.
vertex by vertex aanimation as you call it, is just a simple key animation. the name fooled me, sorry.
And yeah, I agree Descent2 way is the best ( even more when you think the freespace engine is a derivative from the descent engine )
Title: Suggestion: model animation triggers
Post by: Sandwich on September 27, 2002, 05:13:34 pm
Quote
Originally posted by r0nin


Which is?  Seriously, I don't know how they did it, nor do I have the source code, and I would be seriously interested.  Let me know where to find it!


http://www.planetannihilation.com/tamec/helpdesk/TA/ta_design_guide/tadesign/unitdsgn.htm

Scroll down to the section called "Animate Your Unit", read it, and follow the BOS (http://www.planetannihilation.com/tamec/helpdesk/TA/ta_design_guide/tadesign/bosdesc.htm) link. Hope that helps! :nod: