Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.9.1a is out! (05/10/19); Updated the Forum Rules and Guidelines (02/29/20); Blog post: GIF Roundup (04/11/20)

Author Topic: Missile files; What is set where?  (Read 3083 times)

Ithiloneth

  • Ensign
  • *
  • Posts: 11
    • View Profile
Missile files; What is set where?
« on: June 07, 2016, 01:55:54 AM »

A minor problem, but I can't seem to find a solution. Should you want the specific files let me know and I'll share them, for reference the weapon in question is the Micro Missile Array from the Diable Avionics mod http://fractalsoftworks.com/forum/index.php?topic=10046.0.

Trying to get a certain missile to behave as follows:
Launch at very high velocity; thus clearing the ship in a flashy manuver while making firing beneficial if aimed straight at the target and risky if not.
Continue on at a speed x, with acceleration x, turnAcc x and turnRate x. At this stage the missile has one amount of fuel - is that the "flight time" property in weapon_data.csv?
Upon closing within distance X from the target the values change to be speed y, with acceleration y, turnAcc y and turnRate y. At this stage the missile has separate, but smaller amount of fuel.

I know some of these properties work for other missiles but can't seem to get them to work for me.

Problems I'm having:
The missiles don't move away in a straight line, but move in a wave pattern, I've tracked this down to the "turnAcc", "turnRate" and "acc" parameter's relative values?
No matter what value I change the speed of the missile after it is launched (the launch speed sets perfectly fine with "launch_speed") seems to be set at a certain value. I've even deleted "proj speed" to no effect. I'm sure I'm on the right weapon/missile as some other changes I make work.
Only thing I know about a second engine mode is that I'd use a second engineSlot entry in the missile_name.proj, right? But how?

I've tried a few values which I think should have an effect that don't...
weapon_data.csv
  • "proj speed"
  • "flight time"

missile_name.proj
  • "acc"
  • "maxSpeed"

Grateful for any help you can give me!

Edit: Balance is not an issue, not at this stage. So don't worry about fine tuning!
Logged

Tartiflette

  • Admiral
  • *****
  • Posts: 2928
  • Toss a coin to your Modder, O' valley of plenty
    • View Profile
Re: Missile files; What is set where?
« Reply #1 on: June 07, 2016, 02:56:20 AM »

   That behavior is a bit more complicated than what is natively supported by the vanilla missiles, but it can probably be roughly emulated using MIRV missiles. Those missiles will still wave around though, as all vanilla missiles do. To change the speed after launch, add some deceleration value to the missile's engine.

   If you want exactly that behavior though, you'll need a custom AI. You can probably start from one of the missile AIs posted in the Code Dump. Here is mine, that has already some options for custom behavior, you can also take a look at the Coasting Missiles from Scy that has a fuel calculation instead of a flight timer.

Logged
 

Ithiloneth

  • Ensign
  • *
  • Posts: 11
    • View Profile
Re: Missile files; What is set where?
« Reply #2 on: June 07, 2016, 03:56:36 AM »

Edit: Just noticed - aren't you the author of the mod?! Thank you for a great mod! Really enjoying it and I'm currently cruising around in my own little hack of the Gulf class, Hegemoney's enemy #1 I am! The ship that transforms is just brilliant, if the game had a larger team I'd want waay more of those, but I assume that would be a lot of extra work  :(.

Such a timely and wonderful reply! Thank you!  ;D

For the sake of getting something up and running (getting a proper new AI set up for the missiles might be a bit above and beyond my current skill set and will likely take me a week  :o) could you suggest what properties I'd need to tweak for the following behavior?

High speed launch (already implemented).
A high, but lower than launch, speed for homing.
Values for turning that might mitigate the wobbliness while giving the missiles good tracking even at high speeds.
Some parameter to control the time to live for the missiles; "flight time" seems to do nothing... I should mention that the missile_name.proj has a "maxFlightTime" which doesn't seem to do anything either, even if both parameters are set to matched values.

My problem has been that I can't even find the right property to set, and thus I have been unable to fiddle around to find a suitable (at least somewhat balanced) combination.

The vision is that of a reloading missile pod which fires in very small but potentially frequent bursts at long range; allowing for swarm or incision type firing at strategic targets without constraining the ship to position in a certain way. The bottle neck, for balancing a little  :P, being the amount of missiles reloaded per minute. All of this requires range, speed and precision, all three currently an issue in its own right.

I've had a shameful amount of fun pausing, targeting a fighter, un-pausing and letting loose a barrage (currently 3 missiles) then pausing to repeat for each fighter in a wing. Very effective (and satisfying, those things can be damned annoying) if they don't carry PD armaments... :D
« Last Edit: June 07, 2016, 04:22:12 AM by Ithiloneth »
Logged

Tartiflette

  • Admiral
  • *****
  • Posts: 2928
  • Toss a coin to your Modder, O' valley of plenty
    • View Profile
Re: Missile files; What is set where?
« Reply #3 on: June 07, 2016, 04:25:28 AM »

   I'd say try to start from the Hurricane MIRV and make it "split" in only one projectile.

   Try to keep the turn acceleration high (at least 2-3 times the max turn rate) so that the missile doesn't overshoot it's intended azimuth too much, that should limit the waving.

   Also all vanilla missiles are tail chasers, they do not aim for an interception point but only follow their target, making their aim rather poor at long range.

   And finally as I mentioned, if you want the missile to decelerate after launch, it need a deceleration value in the proj specs.

   After that you're on your own, testing stuff is part of the job description...  8)

(also, I'm only the coder guy on Diable, the author is FlashFrozen)
Logged
 

Ithiloneth

  • Ensign
  • *
  • Posts: 11
    • View Profile
Re: Missile files; What is set where?
« Reply #4 on: June 07, 2016, 04:37:32 AM »

This is great stuff, the problem is I don't know what the actual properties' names are. Or in which file they should be/is? I'll try pasting the MIRV missile profile into the Micro Missile one, in .proj and weapon_data.csv both. Thank you.

Update: yeah that is waay above my head. I can't find the homing speed nor flight time variable and patching that MIRV thing over is much more complex.  I just need them to go faster and further, no idea why that should be so complicated.

Update2: Looked at the code dump. Cried. I think I'm giving up on missiles, at least in the capacity I had imagined using them.
« Last Edit: June 07, 2016, 05:10:20 AM by Ithiloneth »
Logged

Tartiflette

  • Admiral
  • *****
  • Posts: 2928
  • Toss a coin to your Modder, O' valley of plenty
    • View Profile
Re: Missile files; What is set where?
« Reply #5 on: June 07, 2016, 05:12:19 AM »

   You only have three files to check: The weapons_data.csv, with all the general information of the weapon and (mostly) the attributes that can be modified by hullmods, the actual weapon file, and the projectile file. Every field should be self explanatory "proj speed" "launch speed" "flight time" "turnRate" "turnAcc" I mean it's just reading a that point. It may take a while to understand the internal logic (because indeed there is one) but nothing is hidden.
« Last Edit: June 07, 2016, 05:19:06 AM by Tartiflette »
Logged
 

Ithiloneth

  • Ensign
  • *
  • Posts: 11
    • View Profile
Re: Missile files; What is set where?
« Reply #6 on: June 07, 2016, 05:21:12 AM »

Changing those, I've tried a multitude combinations for hours, does not change the duration nor speed of the missiles in question. Which is why I've come here. The wiki was most helpful in explaining the details but even with those guidelines I've failed. But only on those parts; getting damage, turn rate, turn acceleration, launch speed and so on to work went swimmingly; just set the corresponding value.

So that's why I'm here - changing the value does nothing and I've not enough knowledge to understand why not.

For the sake for good testing, and I've done this once already, I am no in the process of reverting the mod back to normal and then attempting to change only the max speed and duration variables.

I noticed no changes in missile speed nor duration with higher, nor absurd values.
I modified the "proj speed" & "flight time" in weapons_data.csv
the "maxFlightTime" in diableavionics_micromissile.proj
and no relevant variable was found in diableavionics_microarray.wpn

Missiles were fired at long range, target locked and their homing engaged as normal. They also kept the same speed, 300, as normal (new value was 3000), and self imploded at around where they usually would, at the 12 (as both are before I mess with them) second mark (new value was 300, in both files). It should be mentioned I've run tests with these values all 0 or simply deleted where possible; nothing good came of that.
« Last Edit: June 07, 2016, 05:42:01 AM by Ithiloneth »
Logged

Tartiflette

  • Admiral
  • *****
  • Posts: 2928
  • Toss a coin to your Modder, O' valley of plenty
    • View Profile
Re: Missile files; What is set where?
« Reply #7 on: June 07, 2016, 05:51:31 AM »

   Yeah, if you are actually modifying the Micro Missiles instead of creating a new weapon based on them with a new name, you are bound to have some troubles: they have a custom AI that is overriding several attributes.

   As a general rule you should always start from a vanilla weapon. Diable, Scy, Templars, Blackrock, Tiandong... Most mods now are HEAVILY scripted, and you can't know for sure what is doing what in them until you thoroughly picked them apart to see what makes them tick... Vanilla weapon on the other hand are mostly straightforward.
Logged
 

Ithiloneth

  • Ensign
  • *
  • Posts: 11
    • View Profile
Re: Missile files; What is set where?
« Reply #8 on: June 07, 2016, 05:54:26 AM »

Aha, that explains quite a few things... Thank you!

Update: I have something going now, since the resources in your mod are available cross mod once the game is up and running things went quite smoothly.  ;D
« Last Edit: June 07, 2016, 07:02:46 AM by Ithiloneth »
Logged