Open 6AKU66 opened 1 year ago
Most obvious way for optimization for beamlaser and lightningcannon is apply damage only once in 2-3 ticks.
Lightning cannon already applies its damage in a single tick and then leaves a graphical effect for N frames that does not do any damage or collision checks, just that BAR specifically configures it to instead spawn N lightnings instead with a lifetime of 1 frame. This doesn't necessarily mean it can be solved gameside because the lingering lightning is essentially static (ha) and thus somewhat ugly (compare with ZK which so far still uses the ugly lightning, cloakassault
for a unit name example).
For beamlaser the "damage and raytrace each tick" behaviour is important because mechanics may depend on it:
mahlazer
, not the same as BAR armmanni
) making smooth trenches via cratering probably also counts. Having to replicate cratering in Lua sounds terrible.@sprunk Lightning cannon rays itself not staying though. https://youtu.be/OfLrNsLFJC8
set beamTTL=3 or however much you need
Ok, it's working. The only problem that it's looking too slo-mo'ish because lightning ray don't changing shape. https://youtu.be/1L3tdh_wEXo
Yes, that's what I meant when I said it's static and ugly. I don't think this can be fixed gameside just via weapon def tags.
And this is BeamLaser type of weapon (beamTTL=3). https://youtu.be/r_pnpdUQFgc
Beamlaser and lightningcannon type of weapon is pretty heavy. Most obvious way for optimization for beamlaser and lightningcannon is apply damage only once in 2-3 ticks. While visually it's gonna be updated every tick.
This is how it's looks if i try do this via gamefiles. https://www.youtube.com/watch?v=eKO0IO8J8zw (Hit every 1 tick) https://www.youtube.com/watch?v=vhzk0N9XxKU (Hit every 3 tick) For (Hit every 3 tick) i applied this setting for armbanth unit: beamburst = true, beamdecay = 100, beamtime = 0.07, burst = 300, burstrate = 0.0999,
P.S I don't know if this possible to solve via gameside or it's need to be solved via engine.