Full code:
Code: Select all
data:extend({
{
type = "car",
name = "bomber",
icon = "__bomber__/graphics/bomber.png",
flags = {"pushable", "placeable-neutral", "player-creation"},
minable = {mining_time = 1, result = "bomber"},
max_health = 2000,
corpse = "medium-remnants",
dying_explosion = "medium-explosion",
energy_per_hit_point = 0.5,
resistances =
{
{
type = "fire",
percent = 50
}
},-- haven't figured out a good resistance set yet...]]
collision_box = {{-0.7, -1}, {0.7, 1}},
selection_box = {{-0.7,-1.2},{0.7,1.2}},
effectivity = 0.75,
acceleration_per_energy = 0.48,
breaking_speed = 0.09,
braking_power = "400kW",
burner =
{
effectivity = 0.5,
fuel_inventory_size = 2,
smoke =
{
{
name = "smoke",
deviation = {0.25, 0.25},
frequency = 350,
position = {0, 1.5},
slow_down_factor = 0.9,
starting_frame = 3,
starting_frame_deviation = 5,
starting_frame_speed = 0,
starting_frame_speed_deviation = 5
}
}
},
consumption = "6W", -- 1% of the car
friction = 0.01,
light =
{
{
type = "oriented",
minimum_darkness = 0.3,
picture =
{
filename = "__core__/graphics/light-cone.png",
priority = "medium",
width = 400,
height = 400
},
shift = {-0.6, -14},
size = 2,
intensity = 0.6
},
{
type = "oriented",
minimum_darkness = 0.3,
picture =
{
filename = "__core__/graphics/light-cone.png",
priority = "medium",
width = 400,
height = 400
},
shift = {0.6, -14},
size = 2,
intensity = 0.6
}
}, -- no lights
animation =
{
layers =
{
{
filename = "__bomber__/graphics/entity/bomber-sheet.png",
width = 211,
height = 211,
frame_count = 2,
width_in_frames = 9,
height_in_frames = 1,
shift={0.5, 0},
axially_symmetrical = false,
direction_count = 9
}
}
},
weight = 250,
rotation_speed = 0.01,
inventory_size = 80
}
})
From: https://wiki.factorio.com/index.php?tit ... g_Tutorial "Chapter 8"