Hard Light Productions Forums

Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: Jetmech Jr. on December 16, 2005, 05:02:07 pm

Title: Shields taking Collision damage
Post by: Jetmech Jr. on December 16, 2005, 05:02:07 pm
Can this be added? Is it doable?
Title: Re: Shields taking Collision damage
Post by: WMCoolmon on December 16, 2005, 06:09:00 pm
It looks like line 308 of collidedebrisship and line 1836 of collideshipship would have to be changed. However, it looks like in some cases collision damage _Should_ be applied to shields.
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 08:13:43 am
Speaking of shields...do they absorbe shockwave damage?
And what does the smart-shield feature in the Luncher do?
Title: Re: Shields taking Collision damage
Post by: knn on December 17, 2005, 08:26:42 am
Speaking of shields...do they absorbe shockwave damage?
And what does the smart-shield feature in the Luncher do?

1. Yes
2. FS Wiki:
Quote
Shield recharge is distributed to the most damaged shield quadrant instead of being distributed equally across the entire shield and be wasted when a quadrant is full.
Title: Re: Shields taking Collision damage
Post by: MetalDestroyer on December 17, 2005, 09:40:55 am
Speaking of shields...do they absorbe shockwave damage?
And what does the smart-shield feature in the Luncher do?

1. Yes
2. FS Wiki:
Quote
Shield recharge is distributed to the most damaged shield quadrant instead of being distributed equally across the entire shield and be wasted when a quadrant is full.

Damn it, I thought the smart shield features give a virtually shield system to models which don't have a shield mesh.
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 09:46:51 am
Quote
Damn it, I thought the smart shield features give a virtually shield system to models which don't have a shield mesh.

I think their was something like that in development...or at least their was a request for this because WC capships are all shielded that way.
Title: Re: Shields taking Collision damage
Post by: Starman01 on December 17, 2005, 09:50:03 am
You mean Bob's surface shield thing, but I'm not sure it is already in CVS (and working) yet.
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 09:54:19 am
Yes that one...I still hope that its working one day. WC ships without the shield FX looks strange to me ^_^
Title: Re: Shields taking Collision damage
Post by: Wanderer on December 17, 2005, 09:56:31 am
Surface shields should be enabled with ships.tbl flags. It has been as an available flag for a some time but i do not know if it works though...

And smart shields should IIRC now be controlled via ai_profiles.tbl. That is by creating a new ai profile and then selecting it for the missionsin FRED...
Title: Re: Shields taking Collision damage
Post by: MetalDestroyer on December 17, 2005, 10:11:15 am
I expect this feature is into CVS. Because I've have to give a shield mesh to Imperial Star Destroyer, and when I'm in-game I've some weird white effect.
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 10:24:13 am
@MetalDST
The feature is for ships without a shieldmesh.
What you have is the way shieldmeshes are done for fighters....using an extre shieldmesh.
Strangely we mostly got crashed with shieldmeshed when their was to much fire...aka big battles.
Maybe that have changed...our last experiments with that where done  a long long time ago ^_^
Most problematic with the FX of capship shields is that the effect is hugh...depending on the traingulation size of the mesh I guess and that corners made quite some problems as you got the shield fx going around that corner looked realy odd.

I have just tried it and while I clearly hear the shieldhit sound and the enemy ship looses shieldstrength their isn't any visible effect.
Title: Re: Shields taking Collision damage
Post by: Wanderer on December 17, 2005, 10:25:39 am
Shield color defaults into 255, 255, 255.. Isn't that pure white? If you have not defined shield color then you should be getting white effects.
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 10:28:35 am
Jup RGB255 is pure white. If you search for a color for the shields just open a graphic tool that shows the RGB values to the color you would like for your shields.
The basic FS effect was something like a white cloud.
Title: Re: Shields taking Collision damage
Post by: MetalDestroyer on December 17, 2005, 10:32:17 am
Shield color defaults into 255, 255, 255.. Isn't that pure white? If you have not defined shield color then you should be getting white effects.

Hum, i didn't notice if the value was 255 255 255. I got to check.
Title: Re: Shields taking Collision damage
Post by: MetalDestroyer on December 17, 2005, 10:34:27 am
@MetalDST
The feature is for ships without a shieldmesh.
What you have is the way shieldmeshes are done for fighters....using an extre shieldmesh.
Strangely we mostly got crashed with shieldmeshed when their was to much fire...aka big battles.
Maybe that have changed...our last experiments with that where done  a long long time ago ^_^
Most problematic with the FX of capship shields is that the effect is hugh...depending on the traingulation size of the mesh I guess and that corners made quite some problems as you got the shield fx going around that corner looked realy odd.

I have just tried it and while I clearly hear the shieldhit sound and the enemy ship looses shieldstrength their isn't any visible effect.


I didn't try the Smart shield features when my ISD receive a shield mesh. What do you mean by extra shield mesh for fighters ? hu_hu
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 10:43:02 am
I thought you where refering to the "surface-shield" flak and not the smartshield thing.

If you have a shield mesh for your ship the shield-effect is done like its done for fighters. Fighters also have a shield mesh.
What the "surface-shield" flag should do is using the ships hull as a shieldmesh....at least as I understand it.
Title: Re: Shields taking Collision damage
Post by: MetalDestroyer on December 17, 2005, 10:53:44 am
Hummm, there is a lot of confusion, we need helps :(
Title: Re: Shields taking Collision damage
Post by: Wanderer on December 17, 2005, 11:16:04 am
Surface Shields are a table flag in ships.tbl that cause ships to use their hulls as their shield mesh. In practice this enables shield for ships that do not have a shield mesh defined in their model file (.pof). Fighters and other ships that have shield mesh defined in their model file do not require this table option. This is enabled per model basis.

Smart Shields make shield reloading (after they have been damaged) to function in a more reasonable way than in the retail FS2 by 'focusing' recharging to those shield quadrants that have taken the most damage instead of reloading all quadrants at the same rate. This can only be enabled as a 'global' option.
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 12:10:38 pm
What would be of interest for me is does the surface shield work for someone?
As said I tested it and I only got the shieldhit sound but no visible effect.
Title: Re: Shields taking Collision damage
Post by: Starman01 on December 17, 2005, 01:02:34 pm
My last stand is, that they were working somehow, but Bobboau thought about a way of displaying the shield-impact effect, because the bolt still hit the hull and the small debris effect was displayed
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 01:10:51 pm
I only got the hitanimation of the special weapon...if that is what you mean.
Mh maybe we should ask Bob about it....Bob where are you ?
Title: Re: Shields taking Collision damage
Post by: Cobra on December 17, 2005, 01:58:32 pm
You mean Bob's surface shield thing, but I'm not sure it is already in CVS (and working) yet.

Lucif3r shi3lds ftw! :D
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 17, 2005, 03:12:46 pm
Quote
Lucif3r shi3lds ftw
Isn't it the other way around ftw-> wtf = what the f.... ?
Still what do you want to say with it...does the code work for you, do you want it to work for you or whatever?
Title: Re: Shields taking Collision damage
Post by: knn on December 18, 2005, 06:56:45 am
Quote
Lucif3r shi3lds ftw
Isn't it the other way around ftw-> wtf = what the f.... ?
Still what do you want to say with it...does the code work for you, do you want it to work for you or whatever?

http://en.wikipedia.org/wiki/Ftw
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 18, 2005, 07:07:00 am
Another example why I think these internet language is more confusing then good ^_^
Title: Re: Shields taking Collision damage
Post by: WMCoolmon on December 18, 2005, 02:39:39 pm
What would be of interest for me is does the surface shield work for someone?
As said I tested it and I only got the shieldhit sound but no visible effect.

That (and damaging the shields instead of the hull) is exactly what should happen. Bobb was going to use the decal code to render shield effects, but AFAIK he never got around to it, and the decal code isn't really working atm.

The biggest issue I see with shields taking collision damage is that I think the reason that collision damage isn't dealt to damage is because ships never collide with them. The collision checks for ships are only done for the hull, not the shields, so the collision point is located on the hull. Of course that theory may be complete BS, I don't fully understand that part of the code :p But regardless, the code would have to be modified to handle colliding with shield quadrants that were still there.
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 18, 2005, 04:01:24 pm
Quote
That (and damaging the shields instead of the hull) is exactly what should happen. Bobb was going to use the decal code to render shield effects, but AFAIK he never got around to it, and the decal code isn't really working atm.
To bad it would have been good to have this working. Still their are more importend tasks to be done.
Title: Re: Shields taking Collision damage
Post by: WMCoolmon on December 18, 2005, 04:09:44 pm
If you really want the effect you can probably just take the original ship mesh, scale it up slightly, and use it as the shield mesh to get the same efffect. Probably not a good idea  to do that without reducing the polies of the mesh first if the ship is high-poly.
Title: Re: Shields taking Collision damage
Post by: knn on December 18, 2005, 05:23:16 pm
If you really want the effect you can probably just take the original ship mesh, scale it up slightly, and use it as the shield mesh to get the same efffect. Probably not a good idea  to do that without reducing the polies of the mesh first if the ship is high-poly.

I've tried that, but ended up with beams going right through the front shield and hitting the aft shield. With one ship (a shielded Deimos), the beam went completely through the ship, doing no damage at all.
Title: Re: Shields taking Collision damage
Post by: gevatter Lars on December 18, 2005, 06:32:55 pm
Since we don't have any beams in Wing Commander that wouldn't be the problem. Still we had problems with shieldmeshes as for big battles the program crashed after some time. Since then we haven't done any research into shieldmeshes for the caps again...has anyone experiance with battles with about 20 caps all shielded and add some fighters to it....no beams and no bubble shields. The shield should have the shape of the ship.