HelicopterRevival


Adds a fully animated attack helicopter to the game. Ideal for getting from A to B quickly, exploring the map, building islands and nuking biters from the sky. Originally forked from Kumpu with fixes for Factorio 0.18.2+, but adding some enhancements of my own as well.

Content
a month ago
0.18 - 2.0
80.2K
Transportation

b [Fixed] Error loading mods : ammo category with the name 'anti-material-rifle-ammo' does not exist

2 years ago

Error message : https://i.imgur.com/2zxu3UU.png

Modslist : https://pastebin.com/LfGmuhJW

Let me know what else I can provide to help troubleshoot

2 years ago
(updated 2 years ago)

That's interesting...

I'm getting missing sound when loading sound library...

What version of K2 do you have?

2 years ago

K2 version : 1.2.25

2 years ago
(updated 2 years ago)

Hm...
Has to be something with other mods... I just tested with 1.2.25 yesterday, and aside of the sound problem I spoke of yesterday, it worked fine...

2 years ago

ACTUALLY--I think I got it... One of the mods overrides / removes that specific ammo type...

That's gonna be fun finding which one is the culprit...

2 years ago
(updated 2 years ago)

A new version is going up today... Hopefully this fixes some issues?

But I couldn't replicate your issue... When I installed the mods listed, I got this:
https://i.imgur.com/sPN9J0S.png

Edit: ... or maybe not?
No clue what's going on with uploading mod today... Will try tomorrow...

2 years ago

There's an option, default enabled, in Krastorio2 labeled "More realistic weapons". Inside the data, this is designated as "kr-more-realistic-weapon". That ammo category, as well as "pistol-ammo" and "rifle-ammo", are only inserted if that setting is enabled. The insertion of that category is locked behind an if krastorio.general.getSafeSettingValue("kr-more-realistic-weapon") then conditional in Krastorio2/prototypes/categories/ammo-categories.lua.

2 years ago

There's an option, default enabled, in Krastorio2 labeled "More realistic weapons". Inside the data, this is designated as "kr-more-realistic-weapon". That ammo category, as well as "pistol-ammo" and "rifle-ammo", are only inserted if that setting is enabled. The insertion of that category is locked behind an if krastorio.general.getSafeSettingValue("kr-more-realistic-weapon") then conditional in Krastorio2/prototypes/categories/ammo-categories.lua.

Ah, thanks for that!
I have a different approach for this in my devel version: Just don't load the anti-material (gun/ammo) if the ammo category isn't present... I never realized there's an option to actually change weapon / ammo type completely.

2 years ago

Ya, the typical approach for that type of compatibility seems to be conditioning loading a def on that def actually existing. Checking the setting that the def is behind works, I guess, but it depends heavily on Krastorio2 not changing the linkage between that setting and the def in the future, of course.

Anyway, my short-term fix was just to turn that setting on. I'd disabled it initially because it seemed like a bother and that it'd be more likely to cause compatibility issues, but tbh it's actually a pretty good change, and I've yet to run into compatibility issues with it.

New response