From f37108304e3c1c15cc08029da5cdf32b3f428205 Mon Sep 17 00:00:00 2001 From: Alex Date: Sat, 2 Sep 2023 18:56:12 +0000 Subject: [PATCH] Update file turretgenerator.lua --- data/scripts/lib/turretgenerator.lua | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/data/scripts/lib/turretgenerator.lua b/data/scripts/lib/turretgenerator.lua index e0d5bab..d3d14fe 100644 --- a/data/scripts/lib/turretgenerator.lua +++ b/data/scripts/lib/turretgenerator.lua @@ -189,6 +189,16 @@ function TurretGenerator.generateHeavyCannonTurret(rand, dps, tech, material, ra outerAdjective = "Cumulative "%_T end + if result.size >= 4 then + weapon.speed = weapon.speed * 2 + weapon.reach = weapon.reach * 1.2 + end + + if result.size >= 5 then + weapon.speed = weapon.speed * 2 + weapon.reach = weapon.reach * 1.5 + end + -- attach weapons to turret TurretGenerator.attachWeapons(rand, result, weapon, numWeapons) @@ -208,14 +218,10 @@ function TurretGenerator.generateHeavyCannonTurret(rand, dps, tech, material, ra if result.size >= 4 then name = "Mass Driver /* weapon name*/"%_T - weapon.speed = weapon.speed * 2 - weapon.reach = weapon.reach * 1.2 end if result.size >= 5 then name = "Mass Warper /* weapon name*/"%_T - weapon.speed = weapon.speed * 2 - weapon.reach = weapon.reach * 1.5 end result.title = Format("%1%%2%%3%%4%%5%%6%%7% /* [outer-adjective][barrel][coax][dmg-adjective][multishot][name][serial] */"%_T, outerAdjective, barrel, coax, dmgAdjective, multishot, name, serial)