[0.17] Painless landfill
- eradicator
- Smart Inserter
- Posts: 5211
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: [0.17] Painless landfill
And you could pre-craft whichever of the two recipes is cheaper and then un-/install the mod :twisted:.
Apart from that, yea, might be a good idea. But who knows if the author of $any-particular-mod doesn't have different goals.
(And i didn't even try to remember if or not "landfill" was seperate in some earlier version :D. I just ask the engine / my text editor what it is *now*. It does use the exact same graphics file in any case.)
Apart from that, yea, might be a good idea. But who knows if the author of $any-particular-mod doesn't have different goals.
(And i didn't even try to remember if or not "landfill" was seperate in some earlier version :D. I just ask the engine / my text editor what it is *now*. It does use the exact same graphics file in any case.)
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Re: [0.17] Painless landfill
I'm saying that the Platforms and it's recipes could be removed. Just have [Platforms mod] make landfill minable just like platforms, that's it except maybe also reskin landfill. But there would be no platform recipe or platforms at all in the mod, landfill just gets that capability.
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
-
- Smart Inserter
- Posts: 1161
- Joined: Sat Mar 17, 2018 1:20 pm
- Contact:
Re: [0.17] Painless landfill
From the discussion it is now clear to me that the ability of being able to undo comes at a heavy price... having to use a landfill tile that is non-standard and therefore if you uninstall the mod you end up with a broken map or have to go through a number of difficult hoops to prevent it.
So perhaps I should reformulated the request as something simpler:
Is it feasible to make a mod that does nothing more than use regular blueprints (no landfill in them) and just adds landfill in whatever places your blueprint is trying to place objects but encounters water?
In other words, if I have landfill and necessary materials on hand us personal bots, when I place a blueprint it just gets built (all the hoops handled behind the scenes).
So perhaps I should reformulated the request as something simpler:
Is it feasible to make a mod that does nothing more than use regular blueprints (no landfill in them) and just adds landfill in whatever places your blueprint is trying to place objects but encounters water?
In other words, if I have landfill and necessary materials on hand us personal bots, when I place a blueprint it just gets built (all the hoops handled behind the scenes).
Re: [0.17] Painless landfill
Being able to undo could fairly simply be added to Platforms mod, which I actually also posted as a suggestion on that board. So it doesn't have to be pricy.
There's another mod that just adds that button but it adds the button permanently even when not holding a blueprint and it lacks the other features so I wouldn't recommend it over BlueprintExtensions, which is a must have. But BP-E was broken a while back so then I used the worse mod as a temporary replacement.
But a vanilla bug is that you can't place ghosts on landfill ghosts so you have to place twice, again when the landfill has been placed. Same for both mods, not their fault. I haven't reported it yet though.
Since it has already been made, yes it is feasible. It adds a button that is visible while placing a blueprint that adds landfill under all entities in the blueprint (or temporary cut-copy-paste blueprint) and also the ability to flip blueprints etc.zOldBulldog wrote: Thu May 16, 2019 6:01 pm Is it feasible to make a mod that does nothing more than use regular blueprints (no landfill in them) and just adds landfill in whatever places your blueprint is trying to place objects but encounters water?
In other words, if I have landfill and necessary materials on hand us personal bots, when I place a blueprint it just gets built (all the hoops handled behind the scenes).
There's another mod that just adds that button but it adds the button permanently even when not holding a blueprint and it lacks the other features so I wouldn't recommend it over BlueprintExtensions, which is a must have. But BP-E was broken a while back so then I used the worse mod as a temporary replacement.
But a vanilla bug is that you can't place ghosts on landfill ghosts so you have to place twice, again when the landfill has been placed. Same for both mods, not their fault. I haven't reported it yet though.
Last edited by Qon on Thu May 16, 2019 6:33 pm, edited 1 time in total.
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
-
- Smart Inserter
- Posts: 1161
- Joined: Sat Mar 17, 2018 1:20 pm
- Contact:
Re: [0.17] Painless landfill
Ty, I was under the (apparently wrong impression) that BP-E updated the blueprint itself to include the landfill (which I didn't quite like) so I ignored it.Qon wrote: Thu May 16, 2019 6:29 pm Being able to undo could fairly simply be added to Platforms mod, which I actually also posted as a suggestion on that board. So it doesn't have to be pricy.
Since it has already been made, yes it is feasible. It adds a button that is visible while placing a blueprint that adds landfill under all entities in the blueprint (or temporary cut-copy-paste blueprint) and also the ability to flip blueprints etc.zOldBulldog wrote: Thu May 16, 2019 6:01 pm Is it feasible to make a mod that does nothing more than use regular blueprints (no landfill in them) and just adds landfill in whatever places your blueprint is trying to place objects but encounters water?
In other words, if I have landfill and necessary materials on hand us personal bots, when I place a blueprint it just gets built (all the hoops handled behind the scenes).
There's another mod that just adds that button but it adds the button permanently even when not holding a blueprint and it lacks the other features so I wouldn't recommend it over BlueprintExtensions, which is a must have. But BP-E was broken a while back so then I used the worse mod as a temporary replacement.
You have to press the button first though and you might have to double-click (a vanilla bug maybe?) to get entities placed on top of landfill ghosts to actually stick. But it's pretty much perfect and that's just a really minor inconvenience.
But if the button lets you add the landfill "as you place the blueprint" I'll definitely give it a try.
Re: [0.17] Painless landfill
It does add it to the blueprint. But making a copy is fairly trivial (add to library and take from there) and if the blueprint is in the library I don't think the blueprint is updated, just the temporary copy in your hand. And removing the landfill tiles is just rightclick the blueprint and then rightclick the landfill in the entity list to filter them away.
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
- eradicator
- Smart Inserter
- Posts: 5211
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: [0.17] Painless landfill
To be able to do that the base game would have to raise an event when placing a blueprint *fails*. Which it doesn't, so it's not moddable.zOldBulldog wrote: Thu May 16, 2019 6:33 pm But if the button lets you add the landfill "as you place the blueprint" I'll definitely give it a try.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Re: [0.17] Painless landfill
Mod change requestzOldBulldog wrote: Thu May 16, 2019 6:01 pm From the discussion it is now clear to me that the ability of being able to undo comes at a heavy price... having to use a landfill tile that is non-standard and therefore if you uninstall the mod you end up with a broken map or have to go through a number of difficult hoops to prevent it.
and response:
So get Platforms because soon they will be undoable landfill with no drawback.micromario wrote: I didn't know about the changes to landfill in .17
This sounds like a great idea, actually I can't think of any reason not to make this change.
Let me see what I can do
![Very Happy :D](./images/smilies/icon_e_biggrin.gif)
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
-
- Smart Inserter
- Posts: 1161
- Joined: Sat Mar 17, 2018 1:20 pm
- Contact:
Re: [0.17] Painless landfill
Indeed. Very nice. Sounds like the perfect solution.Qon wrote: Thu May 16, 2019 9:32 pmMod change requestzOldBulldog wrote: Thu May 16, 2019 6:01 pm From the discussion it is now clear to me that the ability of being able to undo comes at a heavy price... having to use a landfill tile that is non-standard and therefore if you uninstall the mod you end up with a broken map or have to go through a number of difficult hoops to prevent it.
and response:So get Platforms because soon they will be undoable landfill with no drawback.micromario wrote: I didn't know about the changes to landfill in .17
This sounds like a great idea, actually I can't think of any reason not to make this change.
Let me see what I can do![]()
Re: [0.17] Painless landfill
Of course it's perfect, it was my idea!
![Cool 8-)](./images/smilies/icon_cool.gif)
I mean.... thanks, and thanks to micromario for the excellent idea to make minable platforms in the first place and now keeping it up to date with the latest tech!
![Wink ;)](./images/smilies/icon_e_wink.gif)
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Re: [0.17] Painless landfill
micromario decided to release the update as a separate mod: Breakable LandfillQon wrote: Thu May 16, 2019 9:32 pm So get Platforms because soon they will be undoable landfill with no drawback.![]()
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
- micromario
- Fast Inserter
- Posts: 115
- Joined: Thu Apr 05, 2018 11:53 am
- Contact:
Re: [0.17] Painless landfill
Reading through this thread, I'm going to start working on an update to automatically landfill blueprints if you are holding shift, and then un-landfill them after the key is released
Re: [0.17] Painless landfill
Sounds great, if you succeed! Hope it goes well.micromario wrote: Fri May 17, 2019 9:38 pm Reading through this thread, I'm going to start working on an update to automatically landfill blueprints if you are holding shift, and then un-landfill them after the key is released
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
- eradicator
- Smart Inserter
- Posts: 5211
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: [0.17] Painless landfill
how do you intend to detect "holding shift", i'm not aware the engine supports anything other than "pressed down once"?micromario wrote: Fri May 17, 2019 9:38 pm automatically landfill blueprints if you are holding shift
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
- micromario
- Fast Inserter
- Posts: 115
- Joined: Thu Apr 05, 2018 11:53 am
- Contact:
Re: [0.17] Painless landfill
You're right, can't be done. A shameeradicator wrote: Sat May 18, 2019 7:12 amhow do you intend to detect "holding shift", i'm not aware the engine supports anything other than "pressed down once"?micromario wrote: Fri May 17, 2019 9:38 pm automatically landfill blueprints if you are holding shift
Re: [0.17] Painless landfill
Do you need to? on_put_item gives you a blueprint placement event (might not happen when not forced but then it doesn't matter really in this case). So instead of adding it when you press shift, do it when you place the item. And you don't even have to modify the actual blueprint. You can modify a copy that you swap in and then back out on placement instead. Check out how BlueprintAlignment mod does it. You can't undo (not added to the undo stack) when a blueprint is aligned. But I think BlueprintAlignment could avoid that issue by not calling build_blueprint and instead swap in a modified blueprint in hand (it swaps in a dummy object to avoid regular placement completely and builds it by itself instead, which is bad with the way build_blueprint currently works). So you could make it work toomicromario wrote: Mon May 20, 2019 9:13 pmYou're right, can't be done. A shameeradicator wrote: Sat May 18, 2019 7:12 amhow do you intend to detect "holding shift", i'm not aware the engine supports anything other than "pressed down once"?micromario wrote: Fri May 17, 2019 9:38 pm automatically landfill blueprints if you are holding shift
![Smile :)](./images/smilies/icon_e_smile.gif)
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
- micromario
- Fast Inserter
- Posts: 115
- Joined: Thu Apr 05, 2018 11:53 am
- Contact:
Re: [0.17] Painless landfill
Wow, had no idea that callback worked on blueprints. I feel so powerful nowQon wrote: Mon May 20, 2019 9:38 pmDo you need to? on_put_item gives you a blueprint placement event (might not happen when not forced but then it doesn't matter really in this case). So instead of adding it when you press shift, do it when you place the item. And you don't even have to modify the actual blueprint. You can modify a copy that you swap in and then back out on placement instead. Check out how BlueprintAlignment mod does it. You can't undo (not added to the undo stack) when a blueprint is aligned. But I think BlueprintAlignment could avoid that issue by not calling build_blueprint and instead swap in a modified blueprint in hand (it swaps in a dummy object to avoid regular placement completely and builds it by itself instead, which is bad with the way build_blueprint currently works). So you could make it work toomicromario wrote: Mon May 20, 2019 9:13 pmYou're right, can't be done. A shameeradicator wrote: Sat May 18, 2019 7:12 amhow do you intend to detect "holding shift", i'm not aware the engine supports anything other than "pressed down once"?micromario wrote: Fri May 17, 2019 9:38 pm automatically landfill blueprints if you are holding shift![]()
- micromario
- Fast Inserter
- Posts: 115
- Joined: Thu Apr 05, 2018 11:53 am
- Contact:
Re: [0.17] Painless landfill
on_put_item
shift_build :: boolean: Item was placed using shift building.
shift_build :: boolean: Item was placed using shift building.
- eradicator
- Smart Inserter
- Posts: 5211
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: [0.17] Painless landfill
I thought i observed the other day that this doen't fire at all if none of the blueprint content can be placed (i.e. all is over water). Maybe i'm remembering that wrong?micromario wrote: Tue May 21, 2019 3:29 am on_put_item
shift_build :: boolean: Item was placed using shift building.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Re: [0.17] Painless landfill
That is probably right :/eradicator wrote: Tue May 21, 2019 7:00 amI thought i observed the other day that this doen't fire at all if none of the blueprint content can be placed (i.e. all is over water). Maybe i'm remembering that wrong?micromario wrote: Tue May 21, 2019 3:29 am on_put_item
shift_build :: boolean: Item was placed using shift building.
For me, it is kind of rare that no part at all is on the ground so it's not a huge problem. But for those cases, I would use the "Fill under entities with Landfill" button from BlueprintExtensions. I already have over 100 mods so why not a few more?
Maybe someone can make a mod interface request/bug report so that we can get on_put_item even when it fails to place all things?
My mods: Capsule Ammo | HandyHands - Automatic handcrafting | ChunkyChunks - Configurable Gridlines
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser
Some other creations: Combinassembly Language GitHub w instructions and link to run it in your browser | 0~drain Laser