Artillery wagon max speed

This is the place to request new mods or give ideas about what could be done.
Post Reply
jokru
Burner Inserter
Burner Inserter
Posts: 11
Joined: Sun May 13, 2018 10:34 pm
Contact:

Artillery wagon max speed

Post by jokru »

Currently the artillery wagons max speed seems to be 372,6 km/h (that with nuclear fuel), if I have a modded train that could go up to 756 km/h and attach a single artillery wagon the speed drops to 372,6 km/h.
Vanilla wagons also have this "limitation"
This may be an issue of balance, but I only use it for clearing up forests etc. (no enemies).

So could it be possible to make an artilley wagon with no (or a significantly higher) speed limit?
Maybe a mod that edits the vanilla one? Or maybe one that adds another one, just with a higher speed limit?

User avatar
bobingabout
Smart Inserter
Smart Inserter
Posts: 6941
Joined: Fri May 09, 2014 1:01 pm
Contact:

Re: Artillery wagon max speed

Post by bobingabout »

Yeah, you could modify the max speed on the cargo, fluid or artillery wagon just the same way you edit it on the locomotive.
My mod adds 4 new locomotives, and 4 of each type of wagon to match (but only 2 new artillery wagons)
Creator of Bob's mods. Expanding your gameplay since version 0.9.8.
I also have a Patreon.

jokru
Burner Inserter
Burner Inserter
Posts: 11
Joined: Sun May 13, 2018 10:34 pm
Contact:

Re: Artillery wagon max speed

Post by jokru »

bobingabout wrote:Yeah, you could modify the max speed on the cargo, fluid or artillery wagon just the same way you edit it on the locomotive.
My mod adds 4 new locomotives, and 4 of each type of wagon to match (but only 2 new artillery wagons)
Okay well uhhhh how would I go about modifying it? I can't just edit the base game files right? So I need a mod of sorts...? I'ven't the slightest clue about lua (yet anyway)

User avatar
bobingabout
Smart Inserter
Smart Inserter
Posts: 6941
Joined: Fri May 09, 2014 1:01 pm
Contact:

Re: Artillery wagon max speed

Post by bobingabout »

You'd need to make a mod.

a mod needs 2 things. Firstly though, you need to make a folder in your mod directory with the following format. name_#.#.#
name would be the name of your mod, capitals and spaces etc are important to note ,because the code is case sensative.
#.#.# would be 3 numbers seperated by dots as your mod's version number. 0.16.0 is what I'd use for a mod for 0.16, but other people like to start at 0.1.0 or even 0.0.1.

Then you need an info.json file... for your first time, I'd recommend you just copy one from someone elses mod, then modify it to fit your needs.
pay close attention to make sure the name and version number match what you used in your file name.
Then you'll need at least one of the data.lua files, for your case I would recommend data-updates.lua. (The 3rd 1 is data-final-fixes.lua) Just create a blank text file and rename it to data-updates.lua. Make sure you can edit file extensions on your system though, because data-updates.lua.txt isn't going to work.

then open the file in your favourite text editor (I use Microsoft wordpad, because I'm hardcore) and enter... assuming I have all the names right.

Code: Select all

data.raw["cargo-wagon"]["cargo-wagon"].max_speed = 4
data.raw["fluid-wagon"]["fluid-wagon"].max_speed = 4
data.raw["artillery-wagon"]["artillery-wagon"].max_speed = 4
congratulations, you've made your first mod.

note: I THINK (can't see here) that the default locomotive speed is 1.5 and wagon speed is 2, so setting it to 4 doubles the speed limit. if you want more you can always just enter higher numbers.
Creator of Bob's mods. Expanding your gameplay since version 0.9.8.
I also have a Patreon.

jokru
Burner Inserter
Burner Inserter
Posts: 11
Joined: Sun May 13, 2018 10:34 pm
Contact:

Re: Artillery wagon max speed

Post by jokru »

bobingabout wrote:
Mon Sep 03, 2018 9:11 am
You'd need to make a mod.

a mod needs 2 things. Firstly though, you need to make a folder in your mod directory with the following format. name_#.#.#
name would be the name of your mod, capitals and spaces etc are important to note ,because the code is case sensative.
#.#.# would be 3 numbers seperated by dots as your mod's version number. 0.16.0 is what I'd use for a mod for 0.16, but other people like to start at 0.1.0 or even 0.0.1.

Then you need an info.json file... for your first time, I'd recommend you just copy one from someone elses mod, then modify it to fit your needs.
pay close attention to make sure the name and version number match what you used in your file name.
Then you'll need at least one of the data.lua files, for your case I would recommend data-updates.lua. (The 3rd 1 is data-final-fixes.lua) Just create a blank text file and rename it to data-updates.lua. Make sure you can edit file extensions on your system though, because data-updates.lua.txt isn't going to work.

then open the file in your favourite text editor (I use Microsoft wordpad, because I'm hardcore) and enter... assuming I have all the names right.

Code: Select all

data.raw["cargo-wagon"]["cargo-wagon"].max_speed = 4
data.raw["fluid-wagon"]["fluid-wagon"].max_speed = 4
data.raw["artillery-wagon"]["artillery-wagon"].max_speed = 4
congratulations, you've made your first mod.

note: I THINK (can't see here) that the default locomotive speed is 1.5 and wagon speed is 2, so setting it to 4 doubles the speed limit. if you want more you can always just enter higher numbers.
Thank you a ton! How complicated would optional dependencies be? I don't know if I'll ever publish this, but if I do that would be useful.

User avatar
bobingabout
Smart Inserter
Smart Inserter
Posts: 6941
Joined: Fri May 09, 2014 1:01 pm
Contact:

Re: Artillery wagon max speed

Post by bobingabout »

jokru wrote:
Wed Sep 19, 2018 3:38 pm
How complicated would optional dependencies be?
Here is an extract from an info.json file of mine

Code: Select all

  "dependencies": ["base >= 0.16.0", "boblibrary >= 0.16.0", "? bobplates >= 0.16.0"]
The ? on the front of bobplates means it's optional. It's that simple.

optional dependencies basically mean that the listed mod loads before yours.
Creator of Bob's mods. Expanding your gameplay since version 0.9.8.
I also have a Patreon.

Post Reply

Return to “Ideas and Requests For Mods”

Who is online

Users browsing this forum: No registered users