1
0
mirror of https://github.com/veden/Rampant.git synced 2025-03-17 20:58:35 +02:00

FACTO-135: Changed inferno faction to projectile and remove friendly

fire and increased damage and decreased fire life time
This commit is contained in:
Aaron Veden 2022-05-08 02:37:18 -07:00
parent 1d9497f9b4
commit 908500d700
No known key found for this signature in database
GPG Key ID: FF5990B1C6DD3F84
5 changed files with 117 additions and 24 deletions

View File

@ -5,6 +5,7 @@ Version: 3.1.0
- Migration and siege groups now try to avoid chunks with existing enemy structures
Tweaks:
- Runtime number generator just uses the map seed now
- Changed inferno faction to a projectile with fire aoe
Bugfixes:
- Fixed the period of the xor number generator being cut in half
- Fixed desync when hives would generate buildings using the landmine event (workaround before created_effect existed)

View File

@ -871,7 +871,7 @@ if settings.startup["rampant--infernoEnemy"].value then
units = {
{
type = "spitter",
attackAttributes = {"stream", "acid"},
attackAttributes = {"spitFire", "acid"},
name = "spitter",
majorResistances = {"acid", "fire"},
minorWeaknesses = {"poison"},
@ -898,7 +898,7 @@ if settings.startup["rampant--infernoEnemy"].value then
majorResistances = {"acid", "fire"},
minorWeaknesses = {"poison"},
acceptRate = {1, 10, 0.8, 0.6},
attackAttributes = {"stream", "acid"},
attackAttributes = {"spitFire", "acid"},
attributes = {},
drops = {"orangeArtifact"}
},

View File

@ -58,6 +58,7 @@ local makeSticker = stickerUtils.makeSticker
local makeAtomicBlast = bombUtils.makeAtomicBlast
local makeLaser = beamUtils.makeLaser
local createAttackBall = acidBall.createAttackBall
local createSpitFire = acidBall.createSpitFire
local createRangedAttack = biterUtils.createRangedAttack
local createMeleeAttack = biterUtils.createMeleeAttack
local makeAcidSplashFire = fireUtils.makeAcidSplashFire
@ -312,18 +313,14 @@ local bombAttackNumeric = {
}
local streamAttackNumeric = {
-- ["mutliplerIncrease"] = {1, 1, 1, 1, 1, 2, 2, 2, 2, 2},
-- ["stickerMovementModifier"] = { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 },
-- ["fireDamagePerTick"] = { 0.025, 0.050, 0.075, 0.1, 0.125, 0.15, 0.175, 0.2, 0.225, 0.25 },
-- ["fireDamagePerTick"] = { 0.0125, 0.025, 0.0375, 0.05, 0.0625, 0.075, 0.0875, 0.1, 0.1125, 0.125 },
["stickerDamagePerTick"] = { 0.20, 0.25, 0.30, 0.35, 0.40, 0.45, 0.50, 0.55, 0.60, 0.65 },
["stickerDuration"] = { 400, 410, 420, 430, 440, 450, 440, 470, 480, 490 },
["particleTimeout"] = { 3, 3, 4, 4, 5, 5, 6, 6, 7, 7 },
["fireSpreadRadius"] = { 0.75, 0.75, 0.77, 0.77, 0.79, 0.79, 0.83, 0.83, 0.85, 0.85 },
["damageMaxMultipler"] = { 3, 3, 4, 4, 5, 5, 6, 6, 7, 7 },
["damageMaxMultipler"] = { 2, 2, 2, 3, 3, 3, 4, 4, 4, 5 },
["fireSpreadCooldown"] = { 30, 30, 29, 29, 28, 28, 27, 27, 25, 25 },
["fireDamagePerTick"] = { 0.00625, 0.0125, 0.01875, 0.025, 0.03125, 0.0375, 0.04375, 0.05, 0.05625, 0.0625 },
["damage"] = { 3, 3, 4, 4, 5, 5, 5, 5, 5, 6 }
["fireDamagePerTick"] = { 1, 1, 1, 2, 2, 2, 3, 3, 3, 4 },
["damage"] = { 4, 7.5, 11.25, 15, 22.5, 27.5, 32.5, 37.5, 42.5, 47.5 }
}
local beamAttackNumeric = {
@ -1151,6 +1148,18 @@ local function buildAttack(faction, template)
attack.tint,
attack.tint2)) or nil)
end
elseif (attack == "spitFire") then
template.attackType = "projectile"
-- template.attackDirectionOnly = true
template.addon[#template.addon+1] = streamAttackNumeric
template.attackGenerator = function (attack)
return createRangedAttack(attack,
createSpitFire(attack),
(template.attackAnimation and template.attackAnimation(attack.scale,
attack.tint,
attack.tint2)) or nil)
end
elseif (attack == "touch") then
template.attackType = "projectile"
-- template.attackDirectionOnly = true

View File

@ -31,6 +31,8 @@ local makeStream = streamUtils.makeStream
local makeSticker = stickerUtils.makeSticker
local makeProjectile = projectileUtils.makeProjectile
local makeAcidSplashFire = fireUtils.makeAcidSplashFire
local makeFire = fireUtils.makeFire
local makeSpreadEffect = fireUtils.makeSpreadEffect
-- dumb acid projectiles
local AttackBall = {}
@ -120,17 +122,7 @@ function AttackBall.createAttackBall(attributes)
}
local name
-- local template
if (attributes.attackType == "stream") then
-- template = {
-- name = attributes.name,
-- tint = attributes.tint,
-- particleVertialAcceleration = attributes.particleVertialAcceleration,
-- particleHoizontalSpeed = attributes.particleHoizontalSpeed,
-- particleHoizontalSpeedDeviation = attributes.particleHoizontalSpeedDeviation,
-- actions = templateActions,
-- scale = attributes.scale
-- }
attributes.actions = templateActions
name = makeStream(attributes)
else
@ -140,6 +132,97 @@ function AttackBall.createAttackBall(attributes)
return name
end
function AttackBall.createSpitFire(attributes)
local spawnEntityName = makeSpreadEffect({
name = attributes.name,
tint2 = attributes.tint2,
fireDamagePerTick = attributes.fireDamagePerTick,
fireDamagePerTickType = attributes.fireDamagePerTickType,
})
local stickerName = makeSticker({
name = attributes.name,
spawnEntityName = spawnEntityName,
stickerDuration = attributes.stickerDuration,
stickerDamagePerTick = attributes.stickerDamagePerTick,
stickerDamagePerTickType = attributes.stickerDamagePerTickType,
stickerMovementModifier = attributes.stickerMovementModifier,
tint2 = attributes.tint2,
fireSpreadRadius = attributes.fireSpreadRadius
})
local fireName = makeFire({
name = attributes.name,
tint2 = attributes.tint2 or {r=0, g=0.9, b=0, a=0.5},
spawnEntityName = spawnEntityName,
fireDamagePerTick = attributes.fireDamagePerTick,
fireDamagePerTickType = attributes.fireDamagePerTickType,
damageMaxMultipler = attributes.damageMaxMultipler,
multiplerIncrease = attributes.multiplerIncrease,
multiplerDecrease = attributes.multiplerDecrease,
stickerName = stickerName
})
return makeProjectile(attributes,
{
{
type = "area",
radius = attributes.radius or 2.5,
force = "not-same",
action_delivery =
{
type = "instant",
target_effects =
{
{
type = "create-sticker",
sticker = stickerName,
check_buildability = true
},
{
type = "create-entity",
entity_name = "water-splash",
tile_collision_mask = { "ground-tile" }
},
{
type = "damage",
damage = { amount = attributes.damage, type = attributes.damageType or "fire" }
}
}
}
},
{
type = "cluster",
cluster_count = 2,
distance = 2 + (0.1 * attributes.effectiveLevel),
distance_deviation = 1.5,
action_delivery = {
type = "instant",
target_effects = {
{
type="create-fire",
entity_name = fireName,
check_buildability = true,
initial_ground_flame_count = 2,
show_in_tooltip = true
}
}
}
},
{
type = "direct",
action_delivery = {
type = "instant",
target_effects = {
type= "create-fire",
entity_name = fireName,
check_buildability = true,
show_in_tooltip = true
}
}
}
}
)
end
function AttackBall.generateVanilla()
AttackBall.createAttackBall({name="acid-ball", scale=0.5, directionOnly=true, attackType="projectile", tint2={r=0, g=1, b=0.3, a=0.5}, damage=4, damagePerTick=0.1, stickerName="acid-sticker-small", radius=1.2, effectiveLevel=1})
AttackBall.createAttackBall({name="acid-ball-1", scale=0.65, directionOnly=true, attackType="projectile", tint2={r=0, g=1, b=0.3, a=0.5}, damage=7.5, damagePerTick=0.2, stickerName="acid-sticker-medium", radius=1.3, effectiveLevel=3})

View File

@ -138,8 +138,8 @@ function fireUtils.makeFire(attributes)
spawn_entity = spawnEntityName,
spread_delay = 300,
spread_delay_deviation = 180,
spread_delay = 30,
spread_delay_deviation = 10,
maximum_spread_count = 100,
flame_alpha = 0.35,
@ -151,8 +151,8 @@ function fireUtils.makeFire(attributes)
fade_in_duration = 30,
fade_out_duration = 30,
initial_lifetime = 120,
lifetime_increase_by = 150,
initial_lifetime = 20,
lifetime_increase_by = 2,
lifetime_increase_cooldown = 1,
maximum_lifetime = 1800,
delay_between_initial_flames = 10,
@ -163,7 +163,7 @@ function fireUtils.makeFire(attributes)
{
type = "area",
radius = attributes.radius or 2.5,
-- force = "enemy",
force = "not-same",
ignore_collision_condition = true,
-- filter_enabled = true,
action_delivery =