Artillery Switch


Adds a switch for turning artillery wagon’s auto fire on/off.

Utilities
5 years ago
0.17
14

i Cool mod!

5 years ago

Hey, this is a great idea! I've definitely wished there was some way to turn off artillery wagons. Took me a few minutes to realize you made a GUI button for it, and that the GUI state changes based on what train you are in. For a minute I thought you had to send a signal to the train station to disable the artillery, which would actually be a cool feature to add.

Since this is another sneaky-train-replacement mod, there are some features you can pull from my mod, Multiple Unit Train Control (source is on GitHub). Specifically:
- Blueprint and pipette handling, so that selecting a disabled wagon puts the normal, enabled version in the blueprint or the cursor. (Vehicle Wagons 2 is using my BP code too)
- Putting the player back in the wagon after replacement. It's easier than I expected, but doesn't fire any events. Neither does ejecting them by destroying the wagon, which messes with both FARL's and your GUIs.
- Event notifications. It might not matter for this mod, but if there are other mods that keep track of all the artillery wagons in the game, you would need to trigger the script_raised_destroy or script_raised_built events every time you make a replacement, in order to be compatible with those mods.

(I just noticed how you use create_build_effect_smoke=false and put that in my mod too!)

5 years ago

Thanks for the suggestions, i'll keep them in mind for the next update.

New response