Author Topic: Beam Secondaries and Auto-Aiming  (Read 1794 times)

0 Members and 1 Guest are viewing this topic.

Beam Secondaries and Auto-Aiming
First question:  Why does the $Autoaim FOV field not work for beam weapons?  What would it take to make that field work for beam weapons?

Second question:  What would it take to be able to use beam weapons interchangeably with other missiles in secondary banks?

A couple of smaller questions while I'm here:  Is it possible to make secondary weapons consume gun energy?  Is it possible to display (or create) a timer for primary weapons (thinking of heavier duty beam weapons)?

Any help or pointing in the right direction would be much appreciated, thanks.

My original post w/discussion:

http://www.hard-light.net/forums/index.php?topic=91648.0

 

Offline AdmiralRalwood

  • 211
  • The Cthulhu programmer himself!
    • Skype
    • Steam
    • Twitter
Re: Beam Secondaries and Auto-Aiming
First question:  Why does the $Autoaim FOV field not work for beam weapons?
The autoaim code is probably only executed for non-beam weapons.

What would it take to make that field work for beam weapons?
Well, I haven't actually looked at the autoaim code recently, but assuming it could be applied to the pre-aiming for making beams work as primary weapons, probably not that much effort. Otherwise, it could involve tweaks to every stage of the beam aiming process.

Second question:  What would it take to be able to use beam weapons interchangeably with other missiles in secondary banks?
Oh, beams don't work as secondary weapons right now? I wonder how much effort would be involved in changing that...

A couple of smaller questions while I'm here:  Is it possible to make secondary weapons consume gun energy?
Not without code changes, but it shouldn't be that hard to copy the code for that from firing primaries to firing secondaries (although perhaps a better option would be to unify the two code paths somehow... then again, that would be a lot more involved).

Is it possible to display (or create) a timer for primary weapons (thinking of heavier duty beam weapons)?
Not that I know of; someone with more experience in the HUD code might be able to tell you how much work it would be to add such a thing (or, if it's already possible, how to do it).
Ph'nglui mglw'nafh Codethulhu GitHub wgah'nagl fhtagn.

schrödinbug (noun) - a bug that manifests itself in running software after a programmer notices that the code should never have worked in the first place.

When you gaze long into BMPMAN, BMPMAN also gazes into you.

"I am one of the best FREDders on Earth" -General Battuta

<Aesaar> literary criticism is vladimir putin

<MageKing17> "There's probably a reason the code is the way it is" is a very dangerous line of thought. :P
<MageKing17> Because the "reason" often turns out to be "nobody noticed it was wrong".
(the very next day)
<MageKing17> this ****ing code did it to me again
<MageKing17> "That doesn't really make sense to me, but I'll assume it was being done for a reason."
<MageKing17> **** ME
<MageKing17> THE REASON IS PEOPLE ARE STUPID
<MageKing17> ESPECIALLY ME

<MageKing17> God damn, I do not understand how this is breaking.
<MageKing17> Everything points to "this should work fine", and yet it's clearly not working.
<MjnMixael> 2 hours later... "God damn, how did this ever work at all?!"
(...)
<MageKing17> so
<MageKing17> more than two hours
<MageKing17> but once again we have reached the inevitable conclusion
<MageKing17> How did this code ever work in the first place!?

<@The_E> Welcome to OpenGL, where standards compliance is optional, and error reporting inconsistent

<MageKing17> It was all working perfectly until I actually tried it on an actual mission.

<IronWorks> I am useful for FSO stuff again. This is a red-letter day!
* z64555 erases "Thursday" and rewrites it in red ink

<MageKing17> TIL the entire homing code is held up by shoestrings and duct tape, basically.

 

Offline Dragon

  • Citation needed
  • 212
  • The sky is the limit.
Re: Beam Secondaries and Auto-Aiming
A timer for bigger primary weapons would be handy in general. Say, BP's Archer comes (or used to come) close to that point. A pre-FS1 mod (forgot the name) had a plasma cannon that could use that, too.