taleden / EDSY

EDSY is a web-based ship outfitting simulator tool for the game Elite Dangerous
22 stars 7 forks source link

Variable names meaning? #14

Closed Jacco-V closed 8 months ago

Jacco-V commented 1 year ago

I was working through the code pertaining to heat management, and came across 3 names that I do not know what they represent. I hope somebody can clarify them for me:

It would be most helpful if someone could clarify these to me!

taleden commented 1 year ago

sfpc is "sustained firings per cycle", meaning the number of individual shots that can be fired before taking a break to reload; for energy weapons that don't reload, this should always be equal to bstsize ("burst size") -- they're treated as reloading after every burst, but taking 0 seconds to do so. "shots per cycle" might have been a more intuitive abbreviation, except that in all of these dps/rof related calculations, s already doubles as either "seconds" or "sustained".

sspc is "sustained seconds per cycle", meaning the total time between firing the first shot in a clip, emptying it, reloading, and being ready to fire the first shot in the next clip. For energy weapons this should always be the inverse of "sustained rate of fire".

In all of those routines, "sustained" just means factoring in reload time over an extended engagement, as opposed to "burst" which excludes reload time to give the highest possible rate of damage output in the initial burst before the first reload.

wepchg_sustain_cur means "percentage of sustained DPS that can also be accommodated by the WEP capacitor's current recharge rate, factoring in its pip allocation" (which works on a slight exponential curve of 1.1, seen a few lines above). wepchg_sustain_max ignores pip allocation and shows maximum possible capacitor-sustainable-DPS, as if WEP had 4 pips, no matter what the user has set currently. Both of them compare wepchg, which is the WEP capacitor's maximum recharge rate, vs seps which is "sustained energy per second": the average WEP capacitor draw from firing all weapons continuously, including reload breaks.

Please comment again or email if you have any further questions!

Jacco-V commented 1 year ago

Thanks, that's a very comprehensive answer!

Jacco-V commented 12 months ago

I have an additional question pertaining heat management.

Right now, two weapon heat "values under maximum thrust with all weapons firing" stats are calculated: one with a "full" and a one with a "nearly empty" weapons capacitor.

However, both these values require on at least one pip to set to weapons. If no pips are allocated to the weapons capacitor, the stat is shown as 'N/A'. This is because the thmload_hardpoint_wepfull variable 0, which caused by the getEffectiveWeaponThermalLoad() relying on a non-zero weapons pip value to give a non-zero result.

For a near empty weapons capacitor, this is of course fine. However, for a full weapons capacitor, I would still expect a thermal load to be calculated. So that leads to my question, how would I calculate the thermal load for the hardpoints, when they drain a full weapons capacitor to empty, without the weapons capacitor recharging?

taleden commented 10 months ago

I think what you're seeing is that those are "ballpark limits under indefinitely sustained fire" but EDSY does not currently attempt to do any actual simulation of weapons fire (i.e. tracking the ship heat and WEP cap level at each time point of each individual weapon shot, factoring in each weapon's one-clip rate of fire, reload intervals, ammo levels, etc) because that'd be a complicated simulation to write, and a computationally taxing one to be constantly running every time any related ship stat changes slightly.

So instead EDSY just pretends each weapon operates by itself and calculates how much heat it'd generate with a full WEP cap, and how much it'd generate with just enough WEP cap to fire that single weapon one time. It then sums those thermal loads across all weapons and reports that as theoretical limits: were EDSY to do a full and proper simulation (or you test your build in-game), you should see the actual sustained ship heat level land somewhere between the two values EDSY is ballparking.

With 0 pips to WEP, there is no such thing as a sustained ship heat level because the WEP will immediately not be full and never become full again, and when it runs out all weapons fire will stop and that thermal load will disappear entirely. So the theoretical limits become "overheating because WEP drains steadily and each weapon shot adds more heat than the last" at the high end, and "zero because you can't shoot any more" at the low end, which isn't very meaningful. :)

taleden commented 8 months ago

I'm going to close this for now, but please reach out (email, reddit, here) with any further questions.