Need help with modding

Place to get help with not working mods / modding interface.
Post Reply
speedy45
Long Handed Inserter
Long Handed Inserter
Posts: 76
Joined: Fri Aug 08, 2014 11:48 am
Contact:

Need help with modding

Post by speedy45 »

I need help with modding Factorio. So here is the details for factorio:

Factorio 10.12
Scenerio 10.1

The mod I would like to create to mod the storage tank for the oils to incease the storage tanks of the oils. Also I am need to the modding of Factorio as well. Since I the storage thanks max amount is 2500. So I would like to incease this so I don't have to craft like 20 of them. So ny questiion is how to I create this mod, so lt me know?

User avatar
FreeER
Smart Inserter
Smart Inserter
Posts: 1266
Joined: Mon Feb 18, 2013 4:26 am
Contact:

Re: Need help with modding

Post by FreeER »

Well if you look in the data/base/prototypes/entity/entity.lua file you'll see that the storage tank has a type of "storage-tank" and a name of "storage-tank", you'll also see the number 250 (suspiciously close to the 2500 number you mentioned) as the base_area in the fluid_box subtable. To modify the prototypes of another mod (and what's in data/base is just a mod) you use data.raw[type][name].table.property (you'd leave off .table if the property was not within a subtable), so in your mod (a folder/zip with an info.json and data.lua file) you'd place a line like this in the data.lua

Code: Select all

data.raw["storage-tank"]["storage-tank"].fluid_box.base_area = 1000
If you plan to do more modding and haven't read through the tutorial on the wiki (link's in my sig) I'd recommend that, and at least glancing through the Programming in Lua book if you're not familiar with Lua (there's a link in the tutorial, or you can use Google).
<I'm really not active any more so these may not be up to date>
~FreeER=Factorio Modding
- Factorio Wiki
- My Factorio Modding Guide
- Wiki Modding Guide
Feel free to pm me :)
Or drop into #factorio on irc.esper.net

speedy45
Long Handed Inserter
Long Handed Inserter
Posts: 76
Joined: Fri Aug 08, 2014 11:48 am
Contact:

Re: Need help with modding

Post by speedy45 »

thanks for the help,

Post Reply

Return to “Modding help”