Author Topic: "Use Multple Guns" - continued from Mantis 1594  (Read 2688 times)

0 Members and 1 Guest are viewing this topic.

Offline Galemp

  • Actual father of Samus
  • 212
  • Current projects: GVCa Tanen, Vasudan Imperium
    • Steam
    • User page on the FreeSpace Wiki
"Use Multple Guns" - continued from Mantis 1594
This conversation was getting a little too long for Mantis and has evolved from a bugfix to a feature request.

Quote
Galemp
Turrets mounted on player ships always fire one firepoint at a time, even when defined with the "Use Multiple Guns" flag in the ships.tbl entry.
Additionally, the turret initial rotation animation settings do not function on the player ship.

Quote
Taylor
Can you provide some data for me to test with?

I'm pretty sure that I've got the animation thing fixed, but just from the code I don't see any reason that the firepoints wouldn't work as expected. 

 
Quote
Galemp
 Well, it ought to work on the Medusa. I have a model with a jumbo-sized version of the Medusa turret that I can post if you think it's too small and close together to tell whether or not it's firing both cannons. Adding the "Use Multiple Guns" flag to the turret weapon (Prom R IIRC) will let you test it, and it already has turret initial rotation code built into the MVP TBM. 
 
 I uploaded a test POF for you. The gun barrels are supposed to start out pointing straight forward, and fire both cannon simultaneously. It's formatted for default FS2 weapons so go ahead and plop it in there (I don't have the hang of .tbms yet.) 

 
Quote
taylor
 Everything works for me. The ship didn't fire properly with "use multiple guns" at first, but then I realized that only one primary bank had a weapon in it, so that was just a tbl issue.

I'll commit the changes later today. 

 
Quote
Galemp
 Wait, you need to specify two weapons if the turret has two firepoints? Will they fire in tandem, as if they were player-controlled forward-facing firepoints? There is precious little documentation and no examples of a successful use of this feature on the Wiki. 

 
Quote
taylor
 Yeah, "use multiple guns" governs shooting multiple weapons per turret. It doesn't have anything to do with just firepoints. If you have one weapon specified and multiple firepoints then it will only alternate between firepoints. If you've got multiple weapons specified (up to the number of firepoints) then it will fire all of them with "use multiple guns", sort of like how it works with normal fighters. It doesn't fire all of them at exactly the same time, but it's pretty close. 


So now I want both barrels to fire the same weapon at the same time, just like the Deimos does in the supernova cutscene. How do we do this? Maybe a 'Link Multpile Guns' flag is necessary?

On a related note, can we set the Initial animation code type to be active in the techroom?
« Last Edit: April 01, 2008, 10:06:10 am by Galemp »
"Anyone can do any amount of work, provided it isn't the work he's supposed to be doing at that moment." -- Robert Benchley

Members I've personally met: RedStreblo, Goober5000, Sandwich, Splinter, Su-tehp, Hippo, CP5670, Terran Emperor, Karajorma, Dekker, McCall, Admiral Wolf, mxlm, RedSniper, Stealth, Black Wolf...

 

Offline Wanderer

  • Wiki Warrior
  • 211
  • Mostly harmless
Re: "Use Multple Guns" - continued from Mantis 1594
How about just...
Code: [Select]
$Swarm: 2
+SwarmWait: 0.050
Do not meddle in the affairs of coders for they are soggy and hard to light

 

Offline Galemp

  • Actual father of Samus
  • 212
  • Current projects: GVCa Tanen, Vasudan Imperium
    • Steam
    • User page on the FreeSpace Wiki
Re: "Use Multple Guns" - continued from Mantis 1594
Do we know for certain that that's the delay, always?
"Anyone can do any amount of work, provided it isn't the work he's supposed to be doing at that moment." -- Robert Benchley

Members I've personally met: RedStreblo, Goober5000, Sandwich, Splinter, Su-tehp, Hippo, CP5670, Terran Emperor, Karajorma, Dekker, McCall, Admiral Wolf, mxlm, RedSniper, Stealth, Black Wolf...

 

Offline Wanderer

  • Wiki Warrior
  • 211
  • Mostly harmless
Re: "Use Multple Guns" - continued from Mantis 1594
Well the 0.05 was just an example - it could be lower. But unlike with standard turrets where firing delay is ( standard firewait listed in weapons table * difficulty level specific scaling value from ai_profiles table + random delay from ai_profiles table ), where the random delay - from 0.1 s to 0.9 s - causes the 'salvoes' to be 'out of sync'. With swarm option none of these delays are used when determining the firing moment of the next missile in the current salvo. So delay between firings between shots in a salvo stays constant.
Do not meddle in the affairs of coders for they are soggy and hard to light

 

Offline Galemp

  • Actual father of Samus
  • 212
  • Current projects: GVCa Tanen, Vasudan Imperium
    • Steam
    • User page on the FreeSpace Wiki
Re: "Use Multple Guns" - continued from Mantis 1594
So we could make it a swarm with a delay of 0?

..hey, wait. Isn't Swarm a weapons entry, not a turret entry?
"Anyone can do any amount of work, provided it isn't the work he's supposed to be doing at that moment." -- Robert Benchley

Members I've personally met: RedStreblo, Goober5000, Sandwich, Splinter, Su-tehp, Hippo, CP5670, Terran Emperor, Karajorma, Dekker, McCall, Admiral Wolf, mxlm, RedSniper, Stealth, Black Wolf...

 

Offline Wanderer

  • Wiki Warrior
  • 211
  • Mostly harmless
Re: "Use Multple Guns" - continued from Mantis 1594
Yeah... that's the downside..
Do not meddle in the affairs of coders for they are soggy and hard to light

 

Offline Galemp

  • Actual father of Samus
  • 212
  • Current projects: GVCa Tanen, Vasudan Imperium
    • Steam
    • User page on the FreeSpace Wiki
Re: "Use Multple Guns" - continued from Mantis 1594
ghaaa. So we do need this.
"Anyone can do any amount of work, provided it isn't the work he's supposed to be doing at that moment." -- Robert Benchley

Members I've personally met: RedStreblo, Goober5000, Sandwich, Splinter, Su-tehp, Hippo, CP5670, Terran Emperor, Karajorma, Dekker, McCall, Admiral Wolf, mxlm, RedSniper, Stealth, Black Wolf...

 

Offline Backslash

  • 29
  • Bring Our Might To Bear
Re: "Use Multple Guns" - continued from Mantis 1594
Yeah.  The current behavior is like the player ship's "cycle" flag... I guess we want a new flag that links the firepoints.

I've actually been trying to implement this for the past week (for beams in particular), but I'm not getting anywhere yet. :ick:  I'm hoping someone more familiar with this area of the code can help.

 

Offline taylor

  • Super SCP/Linux Guru
  • Moderator
  • 212
    • http://www.icculus.org/~taylor
Re: "Use Multple Guns" - continued from Mantis 1594
I'll take a look at it, since I've been working in all of that code for the past day or so anyway.  I guess a "link firepoints" flag is what's wanted, which would then fire from all firepoints at the same time, correct?

 

Offline Galemp

  • Actual father of Samus
  • 212
  • Current projects: GVCa Tanen, Vasudan Imperium
    • Steam
    • User page on the FreeSpace Wiki
Re: "Use Multple Guns" - continued from Mantis 1594
Yep. One weapon specified in the table, all firepoints firing simultaneously, just like weapon hardpoints on a fighter's gun bank.

Would this be best as a weapon flag (like Cycle) or as a turret flag (like Use Multiple Guns)?
"Anyone can do any amount of work, provided it isn't the work he's supposed to be doing at that moment." -- Robert Benchley

Members I've personally met: RedStreblo, Goober5000, Sandwich, Splinter, Su-tehp, Hippo, CP5670, Terran Emperor, Karajorma, Dekker, McCall, Admiral Wolf, mxlm, RedSniper, Stealth, Black Wolf...

  

Offline taylor

  • Super SCP/Linux Guru
  • Moderator
  • 212
    • http://www.icculus.org/~taylor
Re: "Use Multple Guns" - continued from Mantis 1594
I think it would work best as a turret flag, for the purposes of flexibility if nothing else.