Search found 3745 matches

by DaveMcW
Mon May 05, 2025 1:25 am
Forum: Gameplay Help
Topic: Upcycler statistical bias
Replies: 4
Views: 429

Re: Upcycler statistical bias

Don't forget that even an unbiased output will exhibit a random walk: on any given run, the imbalance is expected to grow as the square root of the number of samples.

For a specific example, if you recycle 1 million processing units, each with a 50% chance to generate an advanced circuit, you ...
by DaveMcW
Thu May 01, 2025 3:35 am
Forum: Modding help
Topic: How to add Custom Field to prototypes?
Replies: 4
Views: 210

Re: How to add Custom Field to prototypes?

The way most mods do it is create a storage.custom_fields table in control.lua that maps entities to custom fields.

You then need to update the table whenever an entity is built or destroyed.
by DaveMcW
Wed Apr 30, 2025 3:54 am
Forum: Modding help
Topic: [Solved][2.0.43] How can I set the icon for a recipe?
Replies: 5
Views: 246

Re: [2.0.43] How can I set the icon for a recipe?

How about a different "name"?
by DaveMcW
Tue Apr 29, 2025 9:11 am
Forum: Modding help
Topic: [Solved][2.0.43] How can I set the icon for a recipe?
Replies: 5
Views: 246

Re: [2.0.43] How can I set the icon for a recipe?

Try giving the recipe and item a different localised_name.
by DaveMcW
Sat Apr 26, 2025 11:47 pm
Forum: Mechanical Throughput Magic (circuit-free)
Topic: Legendary Stone 4/s
Replies: 0
Views: 299

Legendary Stone 4/s

This design produces legendary stone from mined calcite. 4 legendary stone per second.

0eNrtXEuP2zYQ/iuBznIhUiQlLdBTr731GCwMWaZ3hepVPbbdLvzfS8prW7Epa4Z0kGQbIMhaNjWfOOQMvxly9OZtikE2bV713sObl2d11XkPn9+8Ln+q0kJ/V6Wl9B68rq8r6fneX0Na5P2r+qaQT7Lapu2rt/e9vNrKf7wHsn/0PVn1eZ/Lg6Dx4nVdDeVGtqqBfxTYD ...
by DaveMcW
Sat Apr 26, 2025 12:06 am
Forum: Modding help
Topic: How to efficiently schedule a future event for a future tick?
Replies: 1
Views: 153

Re: How to efficiently schedule a future event for a future tick?

events.on_tick is very cheap, don't worry about calling it every tick.

Of course you should try to minimize the work you do every tick. Reading a single table index is a great way to do it.
by DaveMcW
Thu Apr 17, 2025 3:13 am
Forum: Modding help
Topic: Need help on coding problem
Replies: 3
Views: 202

Re: Need help on coding problem

You are looking at line 42 in the wrong file.

Fix the file at the top of the error message, prototypes/compatibility/bobs_modules.lua
by DaveMcW
Fri Apr 11, 2025 1:37 pm
Forum: Modding help
Topic: How to generate surface from planet but with custom map-gen
Replies: 2
Views: 214

Re: How to generate surface from planet but with custom map-gen

Can you do it in data.lua?

data.raw['planet']['aquilo'].map_gen_settings.autoplace_controls.aquilo_crude_oil.frequency = 10
data.raw['planet']['aquilo'].map_gen_settings.autoplace_controls.lithium_brine.frequency = 10
data.raw['planet']['aquilo'].map_gen_settings.autoplace_controls.fluorine_vent ...
by DaveMcW
Sat Mar 22, 2025 1:41 pm
Forum: Modding help
Topic: Specifying the biter's attack target
Replies: 4
Views: 314

Re: Specifying the biter's attack target

You need to set that in data.lua.

Code: Select all

data.raw['entity']['nuclear-reactor'].allow_run_time_change_of_is_military_target = true
by DaveMcW
Thu Mar 20, 2025 4:06 pm
Forum: Modding help
Topic: Specifying the biter's attack target
Replies: 4
Views: 314

Re: Specifying the biter's attack target

Code: Select all

/c entity = game.player.selected
entity.is_military_target = true
https://lua-api.factorio.com/latest/cla ... ary_target
by DaveMcW
Tue Mar 04, 2025 2:37 am
Forum: Ideas and Requests For Mods
Topic: [Request] Disable decals from loading
Replies: 1
Views: 199

Re: [Request] Disable decals from loading

Ctrl + Alt + Click on Settings.

Click The rest.

Click both sprite-altas checkboxes.

This makes startup slightly slower the first time, then much faster every other time.
by DaveMcW
Fri Feb 28, 2025 7:24 pm
Forum: Modding interface requests
Topic: Stateless visualisations for PlantPrototype
Replies: 0
Views: 140

Stateless visualisations for PlantPrototype

I am trying to make a plant type of "Flaming ashland tree". This requires the fire stateless_visualisation_variations to change position as the tree grows.

Please scale the stateless visualisations based on a plant's tick_grown.
by DaveMcW
Tue Jan 28, 2025 2:06 am
Forum: Modding help
Topic: "Noob" prototype "type checking" question
Replies: 13
Views: 924

Re: "Noob" prototype "type checking" question

The Factorio engine does not support object-oriented programming.

You can't extend an entity. And you can't use "instance-of" with user-defined entities (because user-defined classes are impossible).

Lua does allow you to use object-oriented patterns, but it only works in your own mod and can't ...
by DaveMcW
Tue Jan 21, 2025 2:59 am
Forum: Modding discussion
Topic: Some "will it mod" questions
Replies: 2
Views: 474

Re: Some "will it mod" questions

1. No engine support, but you can write a mod to help you automate it.
2. No engine support.
3. Mods can connect wires across surfaces.
4. Mods can connect wires across surfaces.
5. No engine support, but you can write a mod to help you automate it.
6. No engine support.
7. Mods can connect wires ...
by DaveMcW
Wed Jan 01, 2025 6:49 pm
Forum: General discussion
Topic: Accumulator / Solar panel ratio
Replies: 171
Views: 696321

Re: Accumulator / Solar panel ratio

Yes, the 25200 tick day was added in Factorio 2.0.
by DaveMcW
Sun Dec 29, 2024 10:35 am
Forum: Modding help
Topic: Making a composite entity act like a normal entity
Replies: 7
Views: 804

Re: Making a composite entity act like a normal entity

The event for cut and copy is on_player_cursor_stack_changed.
by DaveMcW
Thu Dec 26, 2024 2:25 am
Forum: Mechanical Throughput Magic (circuit-free)
Topic: Legendary electronic circuits 28/s
Replies: 3
Views: 1937

Legendary electronic circuits 28/s

This design upgrades normal quality circuits into legendary circuits.

Input is 28 green circuits and 2.8 red circuits per second.
Output is 28 legendary green circuits and 2.8 legendary red circuits per second.

It is optimized for Processing Unit Productivity 13. At lower tech levels it has ...
by DaveMcW
Thu Dec 26, 2024 1:10 am
Forum: Questions, reviews and ratings
Topic: maximum zoom out (0.3?) Is more possible?
Replies: 6
Views: 1088

Re: maximum zoom out (0.3?) Is more possible?

One trick is to resize the game window into a square. Zoom is limited by your longest screen dimension.
by DaveMcW
Wed Dec 25, 2024 9:36 pm
Forum: Modding help
Topic: Making a composite entity act like a normal entity
Replies: 7
Views: 804

Re: Making a composite entity act like a normal entity

You need a third entity whose only purpose is to appear in blueprints.

Go to advanced search