Author Topic: Surface shields.  (Read 12247 times)

0 Members and 1 Guest are viewing this topic.

Offline Goober5000

  • HLP Loremaster
  • Moderator
  • 214
    • Goober5000 Productions
I think the "mysterious bug" is caused by the shield mesh not having enough polies, or something.  I'd rather restrict it to only ships that have the ship flag, as a matter of principle.

What ship did you notice this bug on?

 
All of them, I think. Just fly any mission for a while, and you and AI ships will take hull damage every now and then without the shield being down. It happens seemingly randomly but fairly frequently. This shouldn't happen. The implicit surface shield fixes this problem.

I personally consider this a really big issue, so if you want the implicit surface shield to not be there, I would appreciate it being figured out for real. The implicit surface shield is just a hackish workaround. When I coded this, I felt that the potential compatibility issue was acceptably minor given the severity of the problem it solves.

 

Offline Goober5000

  • HLP Loremaster
  • Moderator
  • 214
    • Goober5000 Productions
Um... I've never ever had this problem. :wtf: You sure it's not something with your codebase or your computer?

 

Offline Bobboau

  • Just a MODern kinda guy
    Just MODerately cool
    And MODest too
  • 213
every now and then the sheild colision detection will miss a hit, and the underlying hull colision check will catch it, it happens more commonly with realy realy fast weapons, or realy tight meshes.
you could just not add a hit effect if there is a sheild mesh,

though, actualy, do you think you could allow for a seperate sheild system that goes along the hull so you can have bubble sheilds _and_ surface sheilds? (this being a seperate resivior, or the main one)
Bobboau, bringing you products that work... in theory
learn to use PCS
creator of the ProXimus Procedural Texture and Effect Generator
My latest build of PCS2, get it while it's hot!
PCS 2.0.3


DEUTERONOMY 22:11
Thou shalt not wear a garment of diverse sorts, [as] of woollen and linen together

 

Offline Goober5000

  • HLP Loremaster
  • Moderator
  • 214
    • Goober5000 Productions
Well, there are plenty of fast weapons in the FS2 universe (e.g. Maxim).  If it's prevalent as you say, then it would break balance.  So that settles it... no surface shields unless the flag is added.

 

Offline Lynx

  • 211
Please find a way to implement that. WCS really needs that feature.

A question: Would surface shields only cover the main body or turrets as well? There should be a way to exclude turrets from being shielded.
Give a man fire and he'll be warm for a day, but set fire to him and he'll be warm for the rest of his life.

 
Quote
Originally posted by Bobboau
every now and then the sheild colision detection will miss a hit, and the underlying hull colision check will catch it, it happens more commonly with realy realy fast weapons, or realy tight meshes.
 you could just not add a hit effect if there is a sheild mesh,
Um, I've seen it happen with the Subach HL-7 and its ilk, and probably even Terran Turret and the like. I've also seen it happen with probably every ship. It's happened in retail FS2, stock fs2_open since day one, etc. The only time I've ever seen it not happen is after I added surface shields.

Here's something you might want to try to demonstrate the bug. I haven't tried this myself, but in theory, it'll work. Change the table so that some ship you fly has some absurdly strong shield that nobody will ever manage to penetrate (e.g. $Shields: 100000 or something). Then fly a mission (in a version without the surface shield code I just committed). Nobody ever even scratches your shield, but you'll probably still take hull damage occasionally, and not from collisions or beams or anything else that normally goes through shields. That's the bug. I still contend that this really shouldn't happen.

Quote
though, actualy, do you think you could allow for a seperate sheild system that goes along the hull so you can have bubble sheilds _and_ surface sheilds? (this being a seperate resivior, or the main one)
The implicit surface shield that's there now is exactly that -- another layer of shielding under the shield mesh. Unless you want a separate HP count for surface shields?

Quote
Originally posted by Goober5000
Well, there are plenty of fast weapons in the FS2 universe (e.g. Maxim).  If it's prevalent as you say, then it would break balance.  So that settles it... no surface shields unless the flag is added.
:hopping:

It's a bug, Goober. Nobody expects it to happen, you didn't even know about it, and I'll be amazed if anyone relies on it, balance-wise.

Quote
Originally posted by Lynx
Please find a way to implement that. WCS really needs that feature.
Which feature?

Quote
A question: Would surface shields only cover the main body or turrets as well? There should be a way to exclude turrets from being shielded.
Covers turrets too. Excluding them sounds really hard.

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
id like a protection factor, the amount of damage the shield would absorb. that way i could have ships with partially effective shilds which only dampen enemy fire, but doesnt stop it copletely. i could use it on my  pirate vessels, tbp could use it on ships like the whitestar and so on.
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline Lynx

  • 211
Quote
Originally posted by _argv[-1]
Which feature?
 


Uuuh, surface shields? That thing the whole thread is about?
Give a man fire and he'll be warm for a day, but set fire to him and he'll be warm for the rest of his life.

 

Offline WMCoolmon

  • Purveyor of space crack
  • Moderator
  • 213
Blech.

Adding surface shields, automatically, if a ship has a shield mesh is limiting modding opportunities - you can't fly under a shield and shoot a ship. No one's actually done this, AFAIK, but it will be impossible with surface shields.

If it's really a problem, I hate to say it, but 'command line flag'. It hasn't seemed like a bug to me, I figured it might have even been on purpose to simulate damage to the ship from sheer kinetic energy. The view DOES shake around when you get hit, you'd figure that over time things would rattle around a bit.

From what people are saying, a separate $Surface shield strength field sounds like a good idea. Bobboau's idea of an emergency shield, for example - this could be used by the SWConv to simulate backup Mon Cal shield generators.

One final thing, surface shields could also be a problem now that hangar bays are getting more popular...especially now that Goober hates us all. Any capship with shields would also have them in the hangar bay.
-C

 

Offline Goober5000

  • HLP Loremaster
  • Moderator
  • 214
    • Goober5000 Productions
Quote
Originally posted by _argv[-1]
It's a bug, Goober. Nobody expects it to happen, you didn't even know about it, and I'll be amazed if anyone relies on it, balance-wise.
Okay, I didn't know about it.  If it happens, fine, it happens.  But if it occurs as often as you say, then it will make a significant difference in how any given battle turns out.  Mission designers will expect a ship to take X amount of damage in Y amount of time.  Surface shields will change this; hence they will break balance.

And breaking balance is a no-no.  Need I remind you of the last time you broke the balance?

EDIT: And what WMC said, too.  But it should stay as a ship flag, not a command-line flag.

 
Why don't you guys design a subsystem call function, looking for a subsystem flag in ship.tbl (which can only be found on ships, regardless of size or class) and follow this with creating a on-hit function.

For example:

On-hit initiated,
If projectile contacting shield does not have subsystem flag
{
  Initiate a shield effect.  <-- your flags effect this.
  Continue on weapon effect function.
}
Else If contact on hull is desicovered without associating subsystem flag
{
  Cordinate angle of hull contact.
  Obtain mesh cordinates which are paralell to angle of hull contact.
  Initiate a shield effect on mesh cordinates <-- your flags effect this
  Redirect weapon effect function on mesh cordinates.
  Continue on weapon effect function
}
Else
{
  Ignore all action.
  Continue on weapon effect function.
}

Also, this could be a merical in the feature.  Here's why I believe this to be so.

You got an object which is allowed to go through the shields. Currently, this object is intersecting the shield mesh. Now, the shields are hit by something that isn't allowed.  What happens to the program when it can't do anything about the object intersecting the shield mesh? Well, if there is only one function handling this, then I think you would call that a memory leak, which quickly turns into a logic error, which is followed by a very unhappy user.  

Of corse, my knowledge of C++ is by far to small to be seen in the same room as you guys, so let me take my leave and hope for the best.  Good luck folks.  :lol:
« Last Edit: January 19, 2005, 11:57:45 pm by 1975 »
The big cool ship...

 

Offline Bobboau

  • Just a MODern kinda guy
    Just MODerately cool
    And MODest too
  • 213
sheilds failing every now and then doesn't seem too buggy, in fact I've always liked it, it made it seem more real as you wouldn't expect a sheild to be 100% effective all the time.
Bobboau, bringing you products that work... in theory
learn to use PCS
creator of the ProXimus Procedural Texture and Effect Generator
My latest build of PCS2, get it while it's hot!
PCS 2.0.3


DEUTERONOMY 22:11
Thou shalt not wear a garment of diverse sorts, [as] of woollen and linen together

 
Quote
Originally posted by Bobboau
sheilds failing every now and then doesn't seem too buggy, in fact I've always liked it, it made it seem more real as you wouldn't expect a sheild to be 100% effective all the time.


I agree with you only on the condition that shield failure is a desirable thing.  However, I would much rather code it as a flag with a % modifier then a convient bug.  There are some instances of which I would not want the shields to fail, and a convient bug would prove to be unconvient at this time.
The big cool ship...

 
Quote
Originally posted by xenthorious


I agree with you only on the condition that shield failure is a desirable thing.  However, I would much rather code it as a flag with a % modifier then a convient bug.  There are some instances of which I would not want the shields to fail, and a convient bug would prove to be unconvient at this time.


Also, in support to any Star Wars Projects, ship flight speeds and projectile speeds will be very fast.  From what I have read, this bug is far more frequent on fast projectiles then it is on slow ones. This could be a problem because it means any game made by a Star Wars Project will experience a very buggy design.  I feel leaving this flaw as is, would cause an unfair advantage favoring projects, such as, TBP and WCS.  No one should be left behind.
The big cool ship...

 

Offline Goober5000

  • HLP Loremaster
  • Moderator
  • 214
    • Goober5000 Productions
And I'm worried that fixing this flaw will throw off balance in old campaigns that were designed to rely on it.  Not just for the player ships, but for enemy ships as well.

 

Offline Lynx

  • 211
Quote
Originally posted by WMCoolmon

One final thing, surface shields could also be a problem now that hangar bays are getting more popular...especially now that Goober hates us all. Any capship with shields would also have them in the hangar bay.



I think there should be a way for submodels to make them uncovered by shields even if the ship has surface shields. I don't know about the other mods, but I'll make the hangarbays subobjects to take advantage of Bobb's detail box thingy.
Give a man fire and he'll be warm for a day, but set fire to him and he'll be warm for the rest of his life.

 

Offline Flaser

  • 210
  • man/fish warsie
2 Simple ideas:

Will it throw off balance? Let's test then debate.
If it does? So what. Make it optional - for projects a'la SWC - problem solved.
If it doesn't screw up anything else I don't see why another "sleeping" feature can't be added to the CVS.

My 2 cents.
"I was going to become a speed dealer. If one stupid fairytale turns out to be total nonsense, what does the young man do? If you answered, “Wake up and face reality,” you don’t remember what it was like being a young man. You just go to the next entry in the catalogue of lies you can use to destroy your life." - John Dolan

 

Offline Goober5000

  • HLP Loremaster
  • Moderator
  • 214
    • Goober5000 Productions
1) It throws off balance.

2) It screws up the feature where you can fly underneath shields and shoot at ships.

So it should remain optional.

 
Quote
Originally posted by Goober5000
And I'm worried that fixing this flaw will throw off balance in old campaigns that were designed to rely on it.  Not just for the player ships, but for enemy ships as well.


Assume you wanted to keep the flaw for the sake of simulating an environment of which supports the design of an old model.  How can you achieve this while it is parallel toward resolving a bug subsequencially, and without monochromatic objectives?

Well, let us first review the current flaw.  Infrequent moments (more frequently with increased projectile speed); the shields fail to preserve protection to an object (ship).

Assuming this is resolved, how could it be regenerated into an optional flag to preserve backwards compatibility?

shieldEffectiveness = Number of times shield has been effective.
shieldFailureCondition = Generated unknown value within known range using rand().
shieldFailure = rand( shieldEffectiveness % shieldFailureCondition) == 1 ? True : False;

Or in English, setup a conditional and optional flag allowing the generation of shield failures at random moments of impact from the projectile.

Also, you could later create a feature in the program which uses the shields as a partial absorption condition, absorbing 80% (or any percentage desired) of all damage caused by a projectile

Then use both flags combined to allow spontaneous shield absorption without making a ship completely protected from impact by a projectile.
The big cool ship...