so, this is my first time at modding on factorio and in lua.
was i wanted was just a simple turret that close the gab betwen the big arty and the small turrets
i mostly tried to do it myself and with a bit of stitching of already in game used code.
i got some error which luckely i could fix but i have no idea how to fix that
Code: Select all
data:extend{
{
type = "ammo-turret",
name = "shockwave-cannon",
icon = "__base__/graphics/icons/gun-turret.png",
icon_size = 32,
flags = {"placeable-player", "player-creation"},
minable = {mining_time = 0.5, result = "assult-turret"},
max_health = 800,
corpse = "medium-remnants",
collision_box = {{-0.7, -0.7 }, {0.7, 0.7}},
selection_box = {{-1, -1 }, {1, 1}},
rotation_speed = 0.055,
preparing_speed = 0.38,
folding_speed = 0,
dying_explosion = "medium-explosion",
inventory_size = 2,
automated_ammo_count = 10,
attacking_speed = 0.1,
alert_when_attacking = true,
open_sound = { filename = "", volume = 0.85 },
close_sound = { filename = "", volume = 0.75 },
folded_animation =
{
layers =
{
}
},
preparing_animation =
{
layers =
{
shockwave_cannon_sheet{},
}
},
prepared_animation =
{
layers =
{
shockwave_cannon_sheet{},
}
},
attacking_animation =
{
layers =
{
shockwave_cannon_sheet{},
}
},
folding_animation =
{
layers =
{
}
},
base_picture =
{
layers =
{
{
filename = "",
priority = "high",
width = 90,
height = 75,
axially_symmetrical = false,
direction_count = 1,
frame_count = 1,
shift = {0, -0.046875},
},
{
filename = "",
flags = { "mask" },
line_length = 1,
width = 100,
height = 100,
axially_symmetrical = false,
direction_count = 1,
frame_count = 1,
shift = {0, -0.234375},
apply_runtime_tint = true
}
}
},
vehicle_impact_sound = { filename = "__base__/sound/car-metal-impact.ogg", volume = 0.65 },
{ line 108
type = "projectile",
ammo_category = "cannon-shell"
cooldown = 100, line 111
projectile_creation_distance = 2.0,
projectile_center = {0.0, 0.5},
damage_modifier = 1.5,
min_range = 30.0,
range = 100,
turn_range = 1,
shell_particle =
{
name = "shell-particle",
direction_deviation = 0.1,
speed = 0.1,
speed_deviation = 0.03,
center = {0, 0},
creation_distance = -1.925,
starting_frame_speed = 0.2,
starting_frame_speed_deviation = 0.1
},
sound =
{
{
filename = "",
volume = 0.75
}
}
},
call_for_help_radius = 40
}}
of corse i tried to look up the error in google but no solution.
thank you in advance