Bob's Warfare


Make things for warfare.

Content
10 months ago
0.13 - 1.1
263K
Combat

b Broken under 0.18.16

4 years ago
(updated 4 years ago)

Mod fails to load as the result of the tank sprite changes in 0.18.16. Here's a patch that fixes it at the expense of breaking backwards compatibility:

--- a/prototypes/entity/drone.lua
+++ b/prototypes/entity/drone.lua
@@ -80,11 +80,11 @@ function tankdroneanimation(scale, tint1, tint2)
         {
           priority = "low",
           width = 104,
-          height = 84,
+          height = 83,
           frame_count = 2,
           tint = tint2,
           direction_count = 64,
-          shift = util.by_pixel(scale * -5, scale * -21),
+          shift = util.by_pixel(0, scale * -21.5),
           max_advance = 1,
           line_length = 2,
           stripes = util.multiplystripes(2,
@@ -109,12 +109,12 @@ function tankdroneanimation(scale, tint1, tint2)
           hr_version =
           {
             priority = "low",
-            width = 207,
+            width = 208,
             height = 166,
             frame_count = 2,
             tint = tint2,
             direction_count = 64,
-            shift = util.by_pixel(scale * -4.75, scale * -21),
+            shift = util.by_pixel(0, scale * -21.5),
             max_advance = 1,
             line_length = 2,
             stripes = util.multiplystripes(2,
diff --git a/prototypes/entity/tank.lua b/prototypes/entity/tank.lua
index cbbc0b3..7d9762c 100644
--- a/prototypes/entity/tank.lua
+++ b/prototypes/entity/tank.lua
@@ -193,11 +193,11 @@ data:extend(
         {
           priority = "low",
           width = 104,
-          height = 84,
+          height = 83,
           frame_count = 2,
           apply_runtime_tint = true,
           direction_count = 64,
-          shift = util.by_pixel(-5, -21),
+          shift = util.by_pixel(0, -21.5),
           max_advance = 1,
           line_length = 2,
           stripes = util.multiplystripes(2,
@@ -221,12 +221,12 @@ data:extend(
           hr_version =
           {
             priority = "low",
-            width = 207,
+            width = 208,
             height = 166,
             frame_count = 2,
             apply_runtime_tint = true,
             direction_count = 64,
-            shift = util.by_pixel(-4.75, -21),
+            shift = util.by_pixel(0, -21.5),
             max_advance = 1,
             line_length = 2,
             stripes = util.multiplystripes(2,
@@ -637,11 +637,11 @@ data:extend(
         {
           priority = "low",
           width = 104,
-          height = 84,
+          height = 83,
           frame_count = 2,
           apply_runtime_tint = true,
           direction_count = 64,
-          shift = util.by_pixel(-5, -21),
+          shift = util.by_pixel(0, -21.5),
           max_advance = 1,
           line_length = 2,
           stripes = util.multiplystripes(2,
@@ -665,12 +665,12 @@ data:extend(
           hr_version =
           {
             priority = "low",
-            width = 207,
+            width = 208,
             height = 166,
             frame_count = 2,
             apply_runtime_tint = true,
             direction_count = 64,
-            shift = util.by_pixel(-4.75, -21),
+            shift = util.by_pixel(0, -21.5),
             max_advance = 1,
             line_length = 2,
             stripes = util.multiplystripes(2,
4 years ago

Already fixed.
note: I don't use git, I did it all manually anyway.
But it's also an issue in the tank's file too, not just the drone file.

4 years ago

Why am I getting the error?
"No pictures to put in atlas"
when I turn on the mod
all mods are currently with factorio version 0.18.16

4 years ago

You'd probably have to be a bit more specific than just that, but IIRC, sounds like a RAM related issue...

New response