Search found 625 matches

by Xorimuth
Fri Apr 30, 2021 9:18 pm
Forum: Modding help
Topic: Get entity connections?
Replies: 8
Views: 2399

Re: Get entity connections?

https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.neighbours https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.circuit_connected_entities https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.circuit_connection_definitions You'll need that last one for connecting to comb...
by Xorimuth
Fri Apr 30, 2021 9:04 pm
Forum: Minor issues
Topic: [1.1.32] Main GUIs do not recenter after removing relative GUI
Replies: 2
Views: 1423

[1.1.32] Main GUIs do not recenter after removing relative GUI

When a relative GUI is added, the main GUI recenters, but it does not go back when the relative GUI is destroyed (or hidden). See video: https://cdn.discordapp.com/attachments/306402592265732098/837795318610788383/relative_gui_demo.mp4 Related, if the relative GUI size is extended downwards, the GUI...
by Xorimuth
Wed Apr 28, 2021 10:39 am
Forum: Already exists
Topic: LuaGuiElement{type="camera",entity=<follow this>}
Replies: 6
Views: 2728

Re: LuaGuiElement{type="camera",entity=<follow this>}

Using flib.gui-beta, I can just do

Code: Select all

{type = "camera", position = spidertron.position, surface_index = spidertron.surface.index, elem_mods = {entity = spidertron}},
:D
by Xorimuth
Wed Apr 28, 2021 9:42 am
Forum: Already exists
Topic: LuaGuiElement{type="camera",entity=<follow this>}
Replies: 6
Views: 2728

Re: LuaGuiElement{type="camera",entity=<follow this>}

Already exists: https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.entity You can write the entity to follow after creating the element Oh wow, thanks! I see for 'entity-preview' it says "The entity has to be set after the GUI element is created.", so maybe there's a tec...
by Xorimuth
Tue Apr 27, 2021 11:15 am
Forum: Already exists
Topic: LuaGuiElement{type="camera",entity=<follow this>}
Replies: 6
Views: 2728

Re: LuaGuiElement{type="camera",entity=<follow this>}

+1. Also for type = "minimap", which is how base game train GUI works.
by Xorimuth
Tue Apr 27, 2021 1:46 am
Forum: General discussion
Topic: Fish per Minute
Replies: 22
Views: 10752

Re: Fish per Minute

Launching 1000 space science pack returns 100 fish due to stack size limitations. If you can design a contraption to launch only 100 space science packs and return 100 fish, scale it up and see how many Fish per Minute one can do. Unfortunately it is impossible to automatically insert more than 12 ...
by Xorimuth
Mon Apr 26, 2021 11:54 pm
Forum: General discussion
Topic: Fish per Minute
Replies: 22
Views: 10752

Re: Fish per Minute

Launching 1000 space science pack returns 100 fish due to stack size limitations. If you can design a contraption to launch only 100 space science packs and return 100 fish, scale it up and see how many Fish per Minute one can do. Unfortunately it is impossible to automatically insert more than 12 ...
by Xorimuth
Sun Apr 25, 2021 11:07 pm
Forum: Minor issues
Topic: [1.1.32] Non-minable entities still emit "Cannot reach" when trying to mine them out of range
Replies: 1
Views: 953

[1.1.32] Non-minable entities still emit "Cannot reach" when trying to mine them out of range

I'm running into this whilst making a mod and it is a bit strange and annoying. Even when the entity is not mineable (set through prototype or control), if you try to right click on it while at a distance it says "Cannot reach" even though it wouldn't do anything if you were close to it. E...
by Xorimuth
Sun Apr 25, 2021 10:25 pm
Forum: Documentation Improvement Requests
Topic: Documentation Improvement Requests
Replies: 316
Views: 83671

Re: Small documentation improvement requests

I'd appreciate some explanation of HighlightBoxEntity please. https://wiki.factorio.com/Prototype/HighlightBoxEntity Overall, when would you use this? The following are the questions that I had as I read through it and tried it out, but from experimenting it seems that it is only used to display the...
by Xorimuth
Sun Apr 25, 2021 9:40 pm
Forum: Documentation Improvement Requests
Topic: Documentation Improvement Requests
Replies: 316
Views: 83671

Re: Small documentation improvement requests

https://lua-api.factorio.com/latest/Lua ... Entity.die it seems that 'force' should be 'optional'.

-> Fixed and added example for the next release
by Xorimuth
Sun Apr 25, 2021 7:25 pm
Forum: Not a bug
Topic: [1.1.32] fast-transfer ignores LuaPlayer.selected = nil
Replies: 7
Views: 1569

Re: [1.1.32] fast-transfer ignores LuaPlayer.selected = nil

eradicator wrote:
Sun Apr 25, 2021 10:15 am
From my testing, it seems to work how you want it when you use `defines.events.on_selected_entity_changed` in a mod. Using it in the command input doesn't seem to do anything (maybe I'm doing this bit wrong?). I can reproduce your issues when I use `on_tick` though.
by Xorimuth
Sun Apr 25, 2021 6:18 pm
Forum: Modding interface requests
Topic: Expose active bot count
Replies: 3
Views: 1020

Re: Expose active bot count

Entities have a 'logistic_network' property that returns a LuaLogisticNetwork for whatever network they're in. For player characters and spidertrons (and probably other vehicles with an equipment grid with roboports, though I only verified player characters and spidertrons) that's their personal ne...
by Xorimuth
Sat Apr 24, 2021 2:14 pm
Forum: Questions, reviews and ratings
Topic: Moralize me, please.
Replies: 6
Views: 1639

Re: Moralize me, please.

PS: 'Moralize' doesn't mean what you think it does: it refers to 'morals' (ie right/wrong), it isn't the opposite of 'Demoralize' (which would be something like 'encourage').
by Xorimuth
Sat Apr 24, 2021 2:11 pm
Forum: Questions, reviews and ratings
Topic: Moralize me, please.
Replies: 6
Views: 1639

Re: Moralize me, please.

Any large mod with more than a few thousand downloads is likely to be updated to a new factorio version very quickly, or if it isn't but it has a permissive licence (like MIT or GPL), then someone else will probably do it instead. Any of the big packs like Bobs, Angels, Py, Space Exploration, Krasto...
by Xorimuth
Sat Apr 24, 2021 10:14 am
Forum: Implemented in 2.0
Topic: Deconstruct landfill
Replies: 24
Views: 11513

Re: Deconstruct landfill

There's also https://alt-f4.blog/ALTF4-5/#a-small-ra ... l-pocarski, and associated discussion on reddit.
by Xorimuth
Fri Apr 23, 2021 8:34 pm
Forum: Documentation Improvement Requests
Topic: Documentation Improvement Requests
Replies: 316
Views: 83671

Re: Small documentation improvement requests

Entity#remove_decoratives what does "automatic" mean? Presumably it depends on the subentity? I'm particularly interested in type "car". -> Correct, documented. Cars aren't considered buildings (= no removal).
by Xorimuth
Thu Apr 22, 2021 1:58 am
Forum: Modding interface requests
Topic: Expose active bot count
Replies: 3
Views: 1020

Expose active bot count

Currently trains with wagons that have equipment grids are given the wait condition "Robots inactive". I'm creating some spidertron wait conditions and I'd like to be able to use whatever is behind this, but I can't find it exposed anywhere. I don't know if it should be in LuaPlayer, LuaCo...
by Xorimuth
Thu Apr 22, 2021 12:55 am
Forum: Pending
Topic: [kovarex] [1.1.32] "Load game" search doesn't update after deleting a save
Replies: 4
Views: 1878

[kovarex] [1.1.32] "Load game" search doesn't update after deleting a save

To reproduce: - Go to the load game window - Search "autosave" - Delete one of the autosaves - Click on the search text entry - Delete the search text entry contents - Observe that the save list still only shows autosaves (BUG) - Delete another save - Observe that the list has now correctl...
by Xorimuth
Tue Apr 20, 2021 3:02 pm
Forum: Technical Help
Topic: Craft item disappeared
Replies: 4
Views: 1459

Re: Craft item disappeared

Ok, how about this?

Code: Select all

/c game.player.force.recipes["spidertron-remote"].enabled = true
by Xorimuth
Tue Apr 20, 2021 1:36 am
Forum: Implemented mod requests
Topic: New FilteredContainer prototype
Replies: 3
Views: 1841

New FilteredContainer prototype

I'd really like to be able to create a `type = container` prototype that allows filters, like character and vehicle inventories. An optional prototype property in https://wiki.factorio.com/Prototype/Container perhaps? For performance reasons this would presumably have to be a separate prototype e.g....

Go to advanced search