Hard Light Productions Forums
Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: TrashMan on January 25, 2005, 05:54:24 pm
-
Say, how about adding a $shockwaveAni: field in the tables?
Each weapon can have it's own specific shockwave it will produce.
To keep backwards compability, if none is specified, it uses the default one.
Oh..and hte ability to ORDER ships via events in FRED to PUT POWER IN THEIR ENGINES. Would be usefull to give capships a small speed max increase...
-
Originally posted by TrashMan
Say, how about adding a $shockwaveAni: field in the tables?
Each weapon can have it's own specific shockwave it will produce.
To keep backwards compability, if none is specified, it uses the default one.
Oh..and hte ability to ORDER ships via events in FRED to PUT POWER IN THEIR ENGINES. Would be usefull to give capships a small speed max increase...
*BUMP*
*tries to get the attention of hte code wizzards, since one shockwave is really starting to piss him off*
-
I think they're ignoring you until you realise that this wasn't a request thread :p
-
:wtf:
This most certainly is not a request thread. And I think that was rather disrespectful.
And coming on the tail of all the other things...
*bans TrashMan from posting in the SCP forum*
-
Either you're taking the piss again, or the power is seriously starting to go to your head Goob.
edit: corrected Heard to head. It appears I thought Goober was creating an over zealous mass of farm-yard animals.
-
It's not just this one incident... he's had a history of this sort of thing. We've been talking about implementing such a policy anyway. I'll see how it works out.
-
Just sad, that is had to happen on such a thread like this (even though it's justified).
-
Good point. Thread split. :)
-
ERm...any of you code wizzards care to comment on this?
Too stupid? Not worth it? No time?
Hell, I would do it myself, but I got only basic programming skillz (Basic, Pascal, Prolog, LIST..oh and C++ and Java too)
I do have a friend who is a master programmer (worked on several games, made dozens of programs for some firms and stuff), and I tried to get him to help wihth the SCP, and alltough he is interested, he sez he regretfully doesn't have the time.
But from what I know (and what he told me), adding that shockwave feature would be a simple thing to do...
-
Add the tbl entry is uber simple. Making it support more than one shockwave type takes a little more work but is certainly doable with a few hours work. There is only one major problem, memory. Having it load multiple shockwave animations is going to suck up RAM by the basket full. We would have to restrict it to 2 or 3 types at most, including the default, in order to keep memory usage down. It can be done but the end result might be more trouble than it's worth for the end user.
-
How much memory can 3 shockwave ani's take?
And who needs uber-shockvawe ani's? The stock FS2 ani still looks better to me than any I?ve seen so far.
-
A helluva lot. Everything is stored in pcx format, unless you use PCX2DDS, so that's 60 frames of data sitting in memory for just a 4-second 15-fps anim. Next you have all the ships' textures, and their models, as well as any background inages (Which exist in memory as their full size)
It very quickly adds up, and moving data between the normal RAM and the RAM on the video card means slowdowns.
-
Hmm...
Well..I would be just as happy if someone just did a slightly better version of the normal FS2 blue shockvawe....
Can't have them all I guess...
-
There's the yellow and orange shockwave in the mediaVP. I'm not sure if you'd term it better, though. ;)
-
I've always been more partial to the spherical shockwave myself, meaning it's a circle instead of the planar ring thing we keep bringing back. I think Inf. release 1 had a good spherical shockwave, though I can't remember exactly if that was indeed where I saw it.
-
Originally posted by TrashMan
How much memory can 3 shockwave ani's take?
A 60 frame, hi-quality version of the original in TGA format is (512x512x4x60) == 60meg. And that's just for one. DDS can save a good bit of memory but the quality is less so you'd probably have to use a larger image so (1024x1024x60) == 60meg. Not saving anything there. You can cut down the number of frames but it still adds up. Most video cards are only going to have 128meg of RAM onboard so with two of those animations loaded you've used all available memory. We've still got to load all model data into video memory for rendering and textures for background nebula, planets, base maps, glow maps, specmaps, weapon effects, missiles, all explosion anis, warp maps, etc. Basically, it's a whole lot.
I personally think this is a good idea and would look cool in-game but the price is pretty high to get it.
-
Could you achieve a slight increase in variety at a low cost in memory just by varying the palettes or or by having the base shockwave animation be white and then using lighting effects to reach a desired color? Or maybe it would be possible to have the actual shockwave ani only be for a quarter of the explosion graphic and have it duplicated to the other 3 quarters?
Apoligies if this is crazy or useless.
-
Originally posted by phatosealpha
Could you achieve a slight increase in variety at a low cost in memory just by varying the palettes or or by having the base shockwave animation be white and then using lighting effects to reach a desired color?
That's really good thinking actually. Being able to define the shockwave colour would certainly meet my needs (e.g. a reddy-orange shockwave for Shivan ships exploding, a blue one for Terrans, etc.).
-
Originally posted by taylor
A 60 frame, hi-quality version of the original in TGA format is (512x512x4x60) == 60meg. And that's just for one. DDS can save a good bit of memory but the quality is less so you'd probably have to use a larger image so (1024x1024x60) == 60meg. Not saving anything there. You can cut down the number of frames but it still adds up. Most video cards are only going to have 128meg of RAM onboard so with two of those animations loaded you've used all available memory. We've still got to load all model data into video memory for rendering and textures for background nebula, planets, base maps, glow maps, specmaps, weapon effects, missiles, all explosion anis, warp maps, etc. Basically, it's a whole lot.
I personally think this is a good idea and would look cool in-game but the price is pretty high to get it.
WTF??? 60MB????
since when does 1 512x512 tga take up 1 mb.
Last time I checked it was around 200-300kb...
-
Originally posted by phatosealpha
Could you achieve a slight increase in variety at a low cost in memory just by varying the palettes or or by having the base shockwave animation be white and then using lighting effects to reach a desired color? Or maybe it would be possible to have the actual shockwave ani only be for a quarter of the explosion graphic and have it duplicated to the other 3 quarters?
Apoligies if this is crazy or useless.
PURE GENIUS!!!!:D :yes:
-
It all depends on whether or not the graphics card supports modifying a graphic on the fly like that. As far as I know, you'd have to apply a color mask to it before you sent the image to the card, which takes us right back to the graphics memory available to hold the explosion.
-
Although I doubt the result will be as good as completly pre-rendered shockwave, it's a very good idea.
But I think it won't save a much memory as you think. AFIAK full grayscale is still 8-Bit.
-
Doesn't the lighting system essentially do that?
Hmm. Do glowmaps have any effect on place where the texture is 100% transparent? Might be able to jury rig something up with a standard shockwave and a very small, solid color glowmap that gets scaled or something.
Though, I'm probably suggesting things that the engine can't do or something.
Edit: Oh, I wasn't really considering the size of the base map itself. Not really much you can do about that, I figure. The reason for all white was primarily because I figure white things take on the color of whatever light they're in, but say a blue shockwave in red light would appear black. So, I was thinking more of getting 4 shockwaves of the same appearance but different color for the memory use of one.
-
The advantage is, in theory, that only one image is loaded into GPU memory and thus you only have one large animation file as opposed to several. I don't think that's how it works, but that's the idea I seem to be hearing.
-
Originally posted by TrashMan
since when does 1 512x512 tga take up 1 mb.
Last time I checked it was around 200-300kb...
RLE compressed it may take up 200-300K but it can't be used that way. It has to be uncompressed first. Memory usage is computed like this: width * height * bpp. A TGA with an alpha channel is 32-bits which is 4-bytes. A height and width of 512 means that you need 512*512*4 = 1048576 bytes (1 meg) of memory. The same formula is used to calculate memory usage for all image formats. The only exception is DDS since it can be sent to the video card still compressed. An uncompressed 32-bit 512x512 TGA should be about 1meg on disk.
-
Actually, the quarter shockwave idea would probably work pretty well, you could map the texture onto four different polygons - you'd even only have to draw one frame per frame, you could just rotate the polygons at different angles.
Lighting, specmapping, glowmapping, etc wouldn't really need to be applied either. And you'd only need to have one palette while drawing those four frames, and maybe you could batch all the explosions on screen to increase speed? I've just about hit the limit of my admittedly-sparse graphics knowledge...
-
Cool...so it can be done?..right?
-
Originally posted by TrashMan
Hmm...
Well..I would be just as happy if someone just did a slightly better version of the normal FS2 blue shockvawe....
Can't have them all I guess...
Umm... FS2-shockwave was more greenish. If you mean FS1 however (which indeed was blue), you can be helped - go to F2S, go to "modificatiions", and look for "Refined Explosion - By Mav ". :D
-
Originally posted by WMCoolmon
Actually, the quarter shockwave idea would probably work pretty well, you could map the texture onto four different polygons - you'd even only have to draw one frame per frame, you could just rotate the polygons at different angles.
Lighting, specmapping, glowmapping, etc wouldn't really need to be applied either. And you'd only need to have one palette while drawing those four frames, and maybe you could batch all the explosions on screen to increase speed? I've just about hit the limit of my admittedly-sparse graphics knowledge...
If the code dosn't allow it, you can simulate it with the frames.
In the first frames the shockwave quarter is on the bottom of the image and it moves up slowly. It should look like the speed is increasing in-game.
-
Originally posted by Mav
Umm... FS2-shockwave was more greenish. If you mean FS1 however (which indeed was blue), you can be helped - go to F2S, go to "modificatiions", and look for "Refined Explosion - By Mav ". :D
Downalod from where exactly? I couldn't find that shockvawe.
-
http://www.sectorgame.com/f2s/files/mods.php
Currently it's right at the top of that list, so it shouldn't take long to find it.
-
Originally posted by StratComm
It all depends on whether or not the graphics card supports modifying a graphic on the fly like that. As far as I know, you'd have to apply a color mask to it before you sent the image to the card, which takes us right back to the graphics memory available to hold the explosion.
FS already does this with weapon glows.
-
Originally posted by TrashMan
Cool...so it can be done?..right?
I have no clue. :p
What you'd need to do is to change whatever-the-way explosion shockwaves are shown (could be by mapping a polygon, or a 2D image, I think it's the former). Rather than display them at the normal size, you'd display four versions, each rotated 90 degrees from the first. It'd be very similar to displaying four shockwaves at the same time, but my 3D knowledge ends about the time you get past positioning stuff and telling FS2 to "model_render". Bobb or taylor would have to field this one.
-
If it is being mapped to a plane, then you could make a 4-quad plane and map the animation specially to all of the corners. I think (since the shockwave doesn't clip) that it's being treated differently, but the 4-corners method is how I get better resolution out of anything I make with radial symmetry.
-
Originally posted by Mav
http://www.sectorgame.com/f2s/files/mods.php
Currently it's right at the top of that list, so it shouldn't take long to find it.
A 40 frame shockwave will look extremely stuttery for big explosions.
-
Originally posted by Mav
http://www.sectorgame.com/f2s/files/mods.php
Currently it's right at the top of that list, so it shouldn't take long to find it.
there are a number of mods listed on that site with me as the creator to wich I beleive I am not. specificly:
Quarantine pack - unless someone repacaged some of my stuff, and used the name of another mini-mod
Weapons - I think hunter made these
GTVB Morta - I've never made a vasudan bomber
and the Polaris was made by Dark (though I did add pof data and converted it to FS2 many years ago, I seek no mention from this)
I've been in trouble due to things like this before, and I do not wish to relive that situation.
-
I'll let Hunter know and see if he can change them if your that concerned, but I'm sure no-one thinks your trying to steal their glory, God knows you've got enough not to need to nick anyone elses ;)
-
you know it was actualy hunter's stie that got me in trouble the first time.
it was a long time ago, when I was still learning, I was converting the Polaris from FS1 to FS2 and adding all sorts of nifty POF data. I had asked Dark for permission to distribute it, then all of the sudden DENYED! I got acused of stealing a background pack and I had a nasty news post posted about me on RA (Dark/wingnut/other's old site). turns out the thing had some sort of macro virus that had imbedded it'self into the doc file I used in the first mod I ever distributed, nasty emails were sent back and fourth, eventualy the situation got resolved, I got permission to distribute the converted model, and order was once again restored to the cosmos.
-
Originally posted by DaBrain
A 40 frame shockwave will look extremely stuttery for big explosions.
Possibly right, but it worked quite fine for me so far.
And it really isn't that much more than an antialiased vesion of the FS1 shockwave (though still a bit more); simply because I got to play a bit FS1 again after years and realized that I liked that shockwave, even in its original low resolution.:cool:
-
Okay, I was toying around with some of the functions involved in adding this, here's what I got as a result: :D
http://fs2source.warpcore.org/tempscreenshot/screen158.jpg
http://fs2source.warpcore.org/tempscreenshot/screen159.jpg
http://fs2source.warpcore.org/tempscreenshot/screen160.jpg
http://fs2source.warpcore.org/tempscreenshot/screen160.jpg
http://fs2source.warpcore.org/tempscreenshot/screen161.jpg
http://fs2source.warpcore.org/tempscreenshot/screen162.jpg
http://fs2source.warpcore.org/tempscreenshot/screen163.jpg
http://fs2source.warpcore.org/tempscreenshot/screen164.jpg
http://fs2source.warpcore.org/tempscreenshot/screen165.jpg
http://fs2source.warpcore.org/tempscreenshot/screen166.jpg
http://fs2source.warpcore.org/tempscreenshot/screen167.jpg
http://fs2source.warpcore.org/tempscreenshot/screen168.jpg
http://fs2source.warpcore.org/tempscreenshot/screen169.jpg
http://fs2source.warpcore.org/tempscreenshot/screen170.jpg
http://fs2source.warpcore.org/tempscreenshot/screen171.jpg
-
...ugly, isn't it?
-
If I got it right, it's just ugly because the EXP is not the right animation for this effect. But I won't say more. ;)